sculp-js 1.18.0 → 1.18.2

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 (61) hide show
  1. package/dist/cjs/array.js +3 -1
  2. package/dist/cjs/async.js +3 -1
  3. package/dist/cjs/base64.js +3 -1
  4. package/dist/cjs/clipboard.js +3 -1
  5. package/dist/cjs/cloneDeep.js +3 -1
  6. package/dist/cjs/cookie.js +3 -1
  7. package/dist/cjs/date.js +3 -1
  8. package/dist/cjs/dom.js +3 -1
  9. package/dist/cjs/download.js +3 -1
  10. package/dist/cjs/file.js +3 -1
  11. package/dist/cjs/func.js +3 -1
  12. package/dist/cjs/index.js +6 -4
  13. package/dist/cjs/isEqual.js +3 -1
  14. package/dist/cjs/math.js +3 -1
  15. package/dist/cjs/number.js +3 -1
  16. package/dist/cjs/object.js +5 -3
  17. package/dist/cjs/path.js +3 -1
  18. package/dist/cjs/qs.js +3 -1
  19. package/dist/cjs/random.js +3 -1
  20. package/dist/cjs/string.js +3 -1
  21. package/dist/cjs/tooltip.js +3 -1
  22. package/dist/cjs/tree.js +3 -1
  23. package/dist/cjs/type.js +2 -2
  24. package/dist/cjs/unicodeToolkit.js +82 -37
  25. package/dist/cjs/unique.js +3 -1
  26. package/dist/cjs/url.js +3 -1
  27. package/dist/cjs/validator.js +3 -1
  28. package/dist/cjs/variable.js +3 -1
  29. package/dist/cjs/watermark.js +3 -1
  30. package/dist/esm/array.js +1 -1
  31. package/dist/esm/async.js +1 -1
  32. package/dist/esm/base64.js +1 -1
  33. package/dist/esm/clipboard.js +1 -1
  34. package/dist/esm/cloneDeep.js +1 -1
  35. package/dist/esm/cookie.js +1 -1
  36. package/dist/esm/date.js +1 -1
  37. package/dist/esm/dom.js +2 -2
  38. package/dist/esm/download.js +2 -2
  39. package/dist/esm/file.js +1 -1
  40. package/dist/esm/func.js +1 -1
  41. package/dist/esm/index.js +4 -4
  42. package/dist/esm/isEqual.js +1 -1
  43. package/dist/esm/math.js +1 -1
  44. package/dist/esm/number.js +1 -1
  45. package/dist/esm/object.js +2 -2
  46. package/dist/esm/path.js +1 -1
  47. package/dist/esm/qs.js +1 -1
  48. package/dist/esm/random.js +1 -1
  49. package/dist/esm/string.js +1 -1
  50. package/dist/esm/tooltip.js +1 -1
  51. package/dist/esm/tree.js +1 -1
  52. package/dist/esm/type.js +1 -1
  53. package/dist/esm/unicodeToolkit.js +80 -37
  54. package/dist/esm/unique.js +1 -1
  55. package/dist/esm/url.js +1 -1
  56. package/dist/esm/validator.js +1 -1
  57. package/dist/esm/variable.js +1 -1
  58. package/dist/esm/watermark.js +1 -1
  59. package/dist/types/unicodeToolkit.d.ts +38 -11
  60. package/dist/umd/index.min.js +2 -2
  61. package/package.json +10 -9
package/dist/cjs/array.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 遍历数组,返回 false 中断遍历(支持continue和break操作)
11
13
  *
package/dist/cjs/async.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 等待一段时间
11
13
  * @param {number} timeout 等待时间,单位毫秒
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var func = require('./func.js');
10
12
  var type = require('./type.js');
11
13
 
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var dom = require('./dom.js');
10
12
  var type = require('./type.js');
11
13
 
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 深拷贝堪称完全体 即:任何类型的数据都会被深拷贝
11
13
  *
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
 
11
13
  /**
package/dist/cjs/date.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
 
11
13
  const isValidDate = any => type.isDate(any) && !type.isNaN(any.getTime());
package/dist/cjs/dom.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var object = require('./object.js');
10
12
  var string = require('./string.js');
11
13
  var type = require('./type.js');
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
  var url = require('./url.js');
11
13
 
package/dist/cjs/file.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
 
11
13
  /**
package/dist/cjs/func.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 防抖函数
11
13
  * 当函数被连续调用时,该函数并不执行,只有当其全部停止调用超过一定时间后才执行1次。
package/dist/cjs/index.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var array = require('./array.js');
10
12
  var clipboard = require('./clipboard.js');
11
13
  var cookie = require('./cookie.js');
@@ -111,7 +113,7 @@ exports.isString = type.isString;
111
113
  exports.isSymbol = type.isSymbol;
112
114
  exports.isUndefined = type.isUndefined;
113
115
  exports.objectHas = type.objectHas;
114
- exports.typeIs = type.typeIs;
116
+ exports.typeIs = type.default;
115
117
  exports.urlDelParams = url.urlDelParams;
116
118
  exports.urlParse = url.urlParse;
117
119
  exports.urlSetParams = url.urlSetParams;
@@ -133,8 +135,8 @@ exports.randomNumber = random.randomNumber;
133
135
  exports.randomString = random.randomString;
134
136
  exports.randomUuid = random.randomUuid;
135
137
  exports.HEX_POOL = number.HEX_POOL;
136
- exports.formatMoney = number.formatNumber;
137
- exports.formatNumber = number.formatNumber;
138
+ exports.formatMoney = number.formatMoney;
139
+ exports.formatNumber = number.formatMoney;
138
140
  exports.humanFileSize = number.humanFileSize;
139
141
  exports.numberAbbr = number.numberAbbr;
140
142
  exports.numberToHex = number.numberToHex;
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 使用位运算或常量定义常用 Tag,这里保持字符串以匹配 Object.prototype.toString
11
13
  */
package/dist/cjs/math.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 数值安全乘法
11
13
  * @param arg1 数值1
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var func = require('./func.js');
10
12
  var string = require('./string.js');
11
13
  var type = require('./type.js');
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
 
11
13
  /**
@@ -99,8 +101,8 @@ function objectOmit(obj, keys) {
99
101
  }
100
102
  const merge = (map, source, target) => {
101
103
  if (type.isUndefined(target)) return source;
102
- const sourceType = type.typeIs(source);
103
- const targetType = type.typeIs(target);
104
+ const sourceType = type.default(source);
105
+ const targetType = type.default(target);
104
106
  if (sourceType !== targetType) {
105
107
  if (type.isArray(target)) return merge(map, [], target);
106
108
  if (type.isObject(target)) return merge(map, {}, target);
package/dist/cjs/path.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 标准化路径
11
13
  * @param {string} path
package/dist/cjs/qs.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var object = require('./object.js');
10
12
  var type = require('./type.js');
11
13
 
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var string = require('./string.js');
10
12
  var type = require('./type.js');
11
13
 
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
12
  * 将字符串转换为驼峰格式
11
13
  * @param {string} string
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var dom = require('./dom.js');
10
12
  var type = require('./type.js');
11
13
 
package/dist/cjs/tree.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var object = require('./object.js');
10
12
  var type = require('./type.js');
11
13
 
package/dist/cjs/type.js CHANGED
@@ -1,12 +1,12 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
- Object.defineProperty(exports, '__esModule', { value: true });
9
+ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
10
10
 
11
11
  // 常用类型定义
12
12
  const { toString, hasOwnProperty } = Object.prototype;
@@ -1,44 +1,70 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  /**
10
- * 高效 Unicode/HTML/UTF-8 编码解码工具
12
+ * 增强型 Unicode/HTML/UTF-8 编码解码工具
11
13
  */
12
14
  class UnicodeToolkit {
13
- static ENTITY_REV_MAP = {
14
- '"': '"',
15
+ // 基础 HTML 实体映射
16
+ static ENTITY_MAP = {
15
17
  '&': '&',
16
18
  '<': '&lt;',
17
19
  '>': '&gt;',
18
- '\u00A0': '&nbsp;',
19
- '©': '&copy;'
20
+ '"': '&quot;',
21
+ "'": '&#39;'
22
+ };
23
+ static NAMED_ENTITIES = {
24
+ '&quot;': '"',
25
+ '&amp;': '&',
26
+ '&lt;': '<',
27
+ '&gt;': '>',
28
+ '&nbsp;': '\u00A0',
29
+ '&copy;': '©',
30
+ '&trade;': '™',
31
+ '&reg;': '®'
20
32
  };
21
33
  /**
22
- * 1. 综合编码方法
23
- * @param mode 'unicode' (转义为 \uXXXX) | 'html' (转义为 &#...;)
34
+ * 编码函数
35
+ * @param {string} str 原始字符串
36
+ * @param {'unicode'|'html'} mode 'unicode' (\uXXXX) | 'html' (&#123;) | 'entities' (命名实体)
37
+ * @param {boolean} encodeAll 是否编码 ASCII 可见字符 (默认 false,仅编码非 ASCII 和特殊字符)
38
+ * @returns {string} 编码后的字符串
39
+ * @example
40
+ * // Unicode 编码 (默认仅编码非 ASCII)
41
+ * UnicodeToolkit.encode('Hi 你好 😀')
42
+ * // => 'Hi \u4F60\u597D \u{1F600}'
43
+ * @example
44
+ * // 全部Unicode 编码
45
+ * UnicodeToolkit.encode('Hi 你好 😀','unicode', true)
46
+ * // => '\u0048\u0069\u0020\u4F60\u597D\u0020\u{1F600}'
47
+ * @example
48
+ * // HTML 实体编码
49
+ * UnicodeToolkit.encode('<script>', 'html',true)
50
+ * // => '&lt;&#115;&#99;&#114;&#105;&#112;&#116;&gt;&amp;'
24
51
  */
25
- static encode(str, mode = 'unicode') {
52
+ static encode(str, mode = 'unicode', encodeAll = false) {
26
53
  const result = [];
27
- // 使用 for...of 正确处理代理对(Emoji)
28
54
  for (const char of str) {
29
55
  const codePoint = char.codePointAt(0);
30
- // ASCII 范围内字符不编码(除了 HTML 必需的特殊字符)
31
- if (codePoint <= 127) {
32
- if (mode === 'html' && this.ENTITY_REV_MAP[char]) {
33
- result.push(this.ENTITY_REV_MAP[char]);
34
- } else {
35
- result.push(char);
36
- }
56
+ // 1. 处理特殊 HTML 基础字符
57
+ if (mode === 'html' && this.ENTITY_MAP[char]) {
58
+ result.push(this.ENTITY_MAP[char]);
37
59
  continue;
38
60
  }
39
- // 处理非 ASCII 字符
61
+ // 2. ASCII 范围 (32-126) 且不强制全编码时,保持原样
62
+ if (!encodeAll && codePoint >= 32 && codePoint <= 126) {
63
+ result.push(char);
64
+ continue;
65
+ }
66
+ // 3. 根据模式转换
40
67
  if (mode === 'unicode') {
41
- // 如果码点超过 0xFFFF,说明是代理对,转义为 \u{XXXXXX} 或拆分为两个 \uXXXX
42
68
  if (codePoint > 0xffff) {
43
69
  result.push(`\\u{${codePoint.toString(16).toUpperCase()}}`);
44
70
  } else {
@@ -51,25 +77,44 @@ class UnicodeToolkit {
51
77
  return result.join('');
52
78
  }
53
79
  /**
54
- * 2. 混合解码 (支持 \uXXXX, \u{XXXX}, HTML 实体)
55
- */
56
- static decode(str) {
57
- return (
58
- str
59
- // 处理 \u{XXXX} 这种 ES6 风格编码
60
- .replace(/\\u\{([0-9a-fA-F]+)\}/g, (_, hex) => String.fromCodePoint(parseInt(hex, 16)))
61
- // 处理标准 \uXXXX
62
- .replace(/\\u([0-9a-fA-F]{4})/g, (_, hex) => String.fromCharCode(parseInt(hex, 16)))
63
- // 处理 HTML 实体
64
- .replace(/&#(x?)([0-9a-fA-F]+);/g, (_, isHex, code) => String.fromCodePoint(parseInt(code, isHex ? 16 : 10)))
65
- .replace(/&[a-z]+;/g, e => Object.entries(this.ENTITY_REV_MAP).find(x => x[1] === e)?.[0] || e)
66
- );
67
- }
68
- /**
69
- * 3. 高性能 UTF-8 转码
80
+ * 综合解码 (支持 \uXXXX, \u{XXXX}, HTML 实体, 十六进制实体)
81
+ * @param {boolean} normalizeSpace 是否将 \u00A0 (&nbsp;) 转换为普通空格 \u0020
82
+ * @returns {string} 解码后的字符串
83
+ *
84
+ * @example
85
+ * // 解码 Unicode Emoji
86
+ * UnicodeToolkit.decode('\u4F60\u597D\u{1F680}')
87
+ * // => '你好🚀'
88
+ * @example
89
+ * // 解码 HTML 实体 (支持十进制、十六进制和命名实体)
90
+ * UnicodeToolkit.decode('Price: &#163;10 &amp; &copy;')
91
+ * // => 'Price: £10 & ©'
92
+ * @example
93
+ * // 空格归一化 (将 &nbsp; 转为标准空格)
94
+ * UnicodeToolkit.decode('A&nbsp;B', true)
95
+ * // => 'A B' (charCodeAt 为 32 而不是 160)
70
96
  */
71
- static toUTF8(str) {
72
- return new TextEncoder().encode(str);
97
+ static decode(str, normalizeSpace = false) {
98
+ if (!str) return '';
99
+ let decoded = str
100
+ // 1. Unicode: \uXXXX 和 \u{XXXX}
101
+ .replace(/\\u(?:\{([0-9a-fA-F]+)\}|([0-9a-fA-F]{4}))/g, (_, hexLong, hexShort) => {
102
+ return String.fromCodePoint(parseInt(hexLong || hexShort, 16));
103
+ })
104
+ // 2. HTML 实体: &#123; 和 &#x7B;
105
+ .replace(/&#(x?)([0-9a-fA-F]+);/g, (_, isHex, code) => {
106
+ return String.fromCodePoint(parseInt(code, isHex ? 16 : 10));
107
+ })
108
+ // 3. 命名实体
109
+ .replace(/&[a-z0-9]+;/gi, entity => {
110
+ return this.NAMED_ENTITIES[entity] || entity;
111
+ });
112
+ // 4. 空格归一化处理
113
+ if (normalizeSpace) {
114
+ // 将 \u00A0 替换为标准半角空格 \u0020
115
+ decoded = decoded.replace(/\u00A0/g, ' ');
116
+ }
117
+ return decoded;
73
118
  }
74
119
  }
75
120
 
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var number = require('./number.js');
10
12
  var random = require('./random.js');
11
13
  var type = require('./type.js');
package/dist/cjs/url.js CHANGED
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
  var path = require('./path.js');
11
13
  var qs = require('./qs.js');
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  // 邮箱
10
12
  const EMAIL_REGEX = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/;
11
13
  /**
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
 
11
13
  /**
@@ -1,11 +1,13 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
6
6
 
7
7
  'use strict';
8
8
 
9
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
10
+
9
11
  var type = require('./type.js');
10
12
 
11
13
  /*
package/dist/esm/array.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */
package/dist/esm/async.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * sculp-js v1.18.0
2
+ * sculp-js v1.18.2
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.18.0
2
+ * sculp-js v1.18.2
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.18.0
2
+ * sculp-js v1.18.2
3
3
  * (c) 2023-present chandq
4
4
  * Released under the MIT License.
5
5
  */