@daysnap/utils 0.0.21 → 0.0.22

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/es/base64ToBlob.js +3 -8
  2. package/es/blobToBase64.js +0 -3
  3. package/es/compareVersion.js +18 -25
  4. package/es/compressImage.js +4 -6
  5. package/es/createHexColorByHash.js +2 -9
  6. package/es/downloadFile.js +0 -2
  7. package/es/filterEmoji.js +0 -1
  8. package/es/filterName.js +0 -4
  9. package/es/formatAmount.js +0 -3
  10. package/es/formatDate.js +2 -8
  11. package/es/getBlobByUrl.js +2 -4
  12. package/es/getImageInfo.js +0 -2
  13. package/es/getVideoInfo.js +0 -2
  14. package/es/isEmpty.js +0 -1
  15. package/es/isMobile.js +0 -1
  16. package/es/omit.js +0 -3
  17. package/es/parseError.js +0 -5
  18. package/es/parsePath.js +0 -1
  19. package/es/reserve.js +0 -1
  20. package/es/storage/factory.js +14 -22
  21. package/lib/base64ToBlob.js +3 -10
  22. package/lib/blobToBase64.js +0 -4
  23. package/lib/compareVersion.js +18 -27
  24. package/lib/compressImage.js +4 -7
  25. package/lib/createHexColorByHash.js +2 -11
  26. package/lib/downloadFile.js +0 -3
  27. package/lib/each.js +0 -1
  28. package/lib/filterBankCardNo.js +0 -1
  29. package/lib/filterEmoji.js +0 -2
  30. package/lib/filterIdCard.js +0 -1
  31. package/lib/filterName.js +0 -5
  32. package/lib/filterPhone.js +0 -1
  33. package/lib/formatAmount.js +0 -4
  34. package/lib/formatDate.js +2 -9
  35. package/lib/getBlobByUrl.js +2 -5
  36. package/lib/getImageInfo.js +0 -3
  37. package/lib/getVideoInfo.js +0 -3
  38. package/lib/index.js +0 -75
  39. package/lib/isAndroid.js +0 -1
  40. package/lib/isEmail.js +0 -1
  41. package/lib/isEmpty.js +0 -3
  42. package/lib/isFunction.js +0 -1
  43. package/lib/isIOS.js +0 -1
  44. package/lib/isIdCard.js +0 -1
  45. package/lib/isMobile.js +0 -2
  46. package/lib/isNull.js +0 -1
  47. package/lib/isObject.js +0 -1
  48. package/lib/isPhone.js +0 -1
  49. package/lib/isPromise.js +0 -1
  50. package/lib/isRegExp.js +0 -1
  51. package/lib/isString.js +0 -1
  52. package/lib/isUndefined.js +0 -1
  53. package/lib/omit.js +0 -3
  54. package/lib/parseError.js +0 -8
  55. package/lib/parsePath.js +0 -2
  56. package/lib/pick.js +0 -1
  57. package/lib/replaceCrlf.js +0 -1
  58. package/lib/reserve.js +0 -2
  59. package/lib/storage/factory.js +14 -25
  60. package/lib/storage/index.js +0 -2
  61. package/package.json +1 -1
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.colorGenByHash = void 0;
7
-
8
7
  /**
9
8
  * 根据字符串hash值生成颜色值
10
9
  */
@@ -13,19 +12,16 @@ var colorGenByHash = function colorGenByHash(str) {
13
12
  var lsS = [0.35, 0.5, 0.65];
14
13
  var seed = 131;
15
14
  var seed2 = 137;
16
- var hash = 0; // eslint-disable-next-line no-param-reassign
17
-
15
+ var hash = 0;
16
+ // eslint-disable-next-line no-param-reassign
18
17
  str += 'x';
19
18
  var MAX_SAFE_INTEGER = parseInt((9007199254740991 / seed2).toString(), 10);
20
-
21
19
  for (var i = 0; i < str.length; i++) {
22
20
  if (hash > MAX_SAFE_INTEGER) {
23
21
  hash = parseInt((hash / seed2).toString(), 10);
24
22
  }
25
-
26
23
  hash = hash * seed + str.charCodeAt(i);
27
24
  }
28
-
29
25
  var H;
30
26
  H = hash % 359;
31
27
  hash = parseInt((hash / 360).toString(), 10);
@@ -40,12 +36,10 @@ var colorGenByHash = function colorGenByHash(str) {
40
36
  // eslint-disable-next-line no-param-reassign
41
37
  color++;
42
38
  }
43
-
44
39
  if (color > 1) {
45
40
  // eslint-disable-next-line no-param-reassign
46
41
  color--;
47
42
  }
48
-
49
43
  if (color < 1 / 6) {
50
44
  // eslint-disable-next-line no-param-reassign
51
45
  color = p + (q - p) * 6 * color;
@@ -59,7 +53,6 @@ var colorGenByHash = function colorGenByHash(str) {
59
53
  // eslint-disable-next-line no-param-reassign
60
54
  color = p;
61
55
  }
62
-
63
56
  return Math.round(color * 255);
64
57
  });
65
58
  var hex = '#';
@@ -67,10 +60,8 @@ var colorGenByHash = function colorGenByHash(str) {
67
60
  if (value < 16) {
68
61
  hex += 0;
69
62
  }
70
-
71
63
  hex += value.toString(16);
72
64
  });
73
65
  return hex;
74
66
  };
75
-
76
67
  exports.colorGenByHash = colorGenByHash;
@@ -4,17 +4,14 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.downloadFile = downloadFile;
7
-
8
7
  /**
9
8
  * 通过 a 标签下载文件
10
9
  */
11
10
  function downloadFile(data, options) {
12
11
  var a = document.createElement('a');
13
12
  a.href = typeof data === 'string' ? data : URL.createObjectURL(data);
14
-
15
13
  if (options !== null && options !== void 0 && options.fileName) {
16
14
  a.download = options.fileName;
17
15
  }
18
-
19
16
  a.click();
20
17
  }
package/lib/each.js CHANGED
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.each = each;
7
-
8
7
  function each(data, callback) {
9
8
  if (Array.isArray(data)) {
10
9
  // eslint-disable-next-line no-plusplus
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.filterBankCardNo = filterBankCardNo;
7
-
8
7
  /**
9
8
  * 过滤银行卡号
10
9
  */
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.filterEmoji = filterEmoji;
7
-
8
7
  /**
9
8
  * 过滤emoji
10
9
  */
@@ -12,7 +11,6 @@ function filterEmoji(val) {
12
11
  if (!val) {
13
12
  return '';
14
13
  }
15
-
16
14
  var ranges = ["\uD83C[\uDF00-\uDFFF]", "\uD83D[\uDC00-\uDE4F]", "\uD83D[\uDE80-\uDEFF]", "[\uD800-\uDBFF]", "[\uDC00-\uDFFF]", "[^ -~\xA0-\xBE\u2E80-\uA4CF\uF900-\uFAFF\uFE30-\uFE4F\uFF00-\uFFEF\x80-\x9F\u2000-\u201F\u2026\u2022\u20AC\r\n]"];
17
15
  return val.replace(new RegExp(ranges.join('|'), 'g'), '');
18
16
  }
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.filterIdCard = filterIdCard;
7
-
8
7
  /**
9
8
  * 身份证号码加 *
10
9
  */
package/lib/filterName.js CHANGED
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.filterName = filterName;
7
-
8
7
  /**
9
8
  * 过滤姓名
10
9
  */
@@ -12,16 +11,12 @@ function filterName(val) {
12
11
  if (!val) {
13
12
  return '';
14
13
  }
15
-
16
14
  var len = val.length;
17
-
18
15
  if (len === 1) {
19
16
  return val;
20
17
  }
21
-
22
18
  if (len === 2) {
23
19
  return "".concat(val.substring(0, 1), "*");
24
20
  }
25
-
26
21
  return "".concat(val.substring(0, 1)).concat(new Array(len - 1).join('*')).concat(val.substr(-1));
27
22
  }
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.filterPhone = filterPhone;
7
-
8
7
  /**
9
8
  * 手机号加 *
10
9
  * filterPhone('13177778888') => 131****8888
@@ -4,14 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.formatAmount = formatAmount;
7
-
8
7
  /**
9
8
  * 格式化金额,默认元
10
9
  */
11
10
  function formatAmount(s) {
12
11
  var radix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 1;
13
12
  var money = parseFloat(s);
14
-
15
13
  if (money) {
16
14
  // eslint-disable-next-line no-param-reassign
17
15
  s = "".concat((money / radix).toFixed(2));
@@ -23,10 +21,8 @@ function formatAmount(s) {
23
21
  });
24
22
  return "".concat(t.split('').reverse().join(''), ".").concat(r);
25
23
  }
26
-
27
24
  if (+s === 0) {
28
25
  return '0.00';
29
26
  }
30
-
31
27
  return '---';
32
28
  }
package/lib/formatDate.js CHANGED
@@ -4,21 +4,17 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.formatDate = formatDate;
7
-
8
7
  var _isString = require("./isString");
9
-
10
8
  /**
11
9
  * 格式化日期
12
10
  */
13
11
  function formatDate(val) {
14
12
  var fmt = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'yyyy-MM-dd hh:mm:ss';
15
13
  var v = val;
16
-
17
14
  if ((0, _isString.isString)(v)) {
18
15
  // fix iOS new Date() 不支持 2020-01-01 格式,需转换为 2020/01/01
19
16
  v = v.replace(/-/g, '/');
20
17
  }
21
-
22
18
  var date = new Date(v);
23
19
  var o = {
24
20
  'M+': date.getMonth() + 1,
@@ -29,19 +25,16 @@ function formatDate(val) {
29
25
  'q+': Math.floor((date.getMonth() + 3) / 3),
30
26
  S: date.getMilliseconds()
31
27
  };
32
-
33
28
  if (/(y+)/.test(fmt)) {
34
29
  // eslint-disable-next-line no-param-reassign
35
30
  fmt = fmt.replace(RegExp.$1, "".concat(date.getFullYear()).substr(4 - RegExp.$1.length));
36
- } // eslint-disable-next-line no-restricted-syntax
37
-
38
-
31
+ }
32
+ // eslint-disable-next-line no-restricted-syntax
39
33
  for (var k in o) {
40
34
  if (new RegExp("(".concat(k, ")")).test(fmt)) {
41
35
  // eslint-disable-next-line no-param-reassign
42
36
  fmt = fmt.replace(RegExp.$1, RegExp.$1.length === 1 ? o[k] : "00".concat(o[k]).substr("".concat(o[k]).length));
43
37
  }
44
38
  }
45
-
46
39
  return fmt;
47
40
  }
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.getBlobByUrl = getBlobByUrl;
7
-
8
7
  /**
9
8
  * 根据在线 url 返回 blob
10
9
  */
@@ -14,12 +13,10 @@ function getBlobByUrl(url) {
14
13
  xhr.open('GET', url, true);
15
14
  xhr.setRequestHeader('Access-Control-Allow-Origin', '*');
16
15
  xhr.responseType = 'blob';
17
-
18
16
  xhr.onload = function () {
19
17
  var status = xhr.status,
20
- response = xhr.response,
21
- statusText = xhr.statusText;
22
-
18
+ response = xhr.response,
19
+ statusText = xhr.statusText;
23
20
  if (status >= 200 && status < 300) {
24
21
  resolve(response);
25
22
  } else {
@@ -4,18 +4,15 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.getImageInfo = getImageInfo;
7
-
8
7
  /**
9
8
  * 获取图片信息
10
9
  */
11
10
  function getImageInfo(src) {
12
11
  return new Promise(function (resolve, reject) {
13
12
  var image = new Image();
14
-
15
13
  image.onload = function () {
16
14
  resolve(image);
17
15
  };
18
-
19
16
  image.onerror = reject;
20
17
  image.src = src;
21
18
  });
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.getVideoInfo = getVideoInfo;
7
-
8
7
  /**
9
8
  * 获取 video 信息
10
9
  */
@@ -14,11 +13,9 @@ function getVideoInfo(src) {
14
13
  video.preload = 'metadata';
15
14
  video.muted = true;
16
15
  video.onerror = reject;
17
-
18
16
  video.onloadedmetadata = function () {
19
17
  resolve(video);
20
18
  };
21
-
22
19
  video.src = src;
23
20
  });
24
21
  }
package/lib/index.js CHANGED
@@ -7,9 +7,7 @@ var _exportNames = {
7
7
  version: true
8
8
  };
9
9
  exports.version = void 0;
10
-
11
10
  var _base64ToBlob = require("./base64ToBlob");
12
-
13
11
  Object.keys(_base64ToBlob).forEach(function (key) {
14
12
  if (key === "default" || key === "__esModule") return;
15
13
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -21,9 +19,7 @@ Object.keys(_base64ToBlob).forEach(function (key) {
21
19
  }
22
20
  });
23
21
  });
24
-
25
22
  var _blobToBase = require("./blobToBase64");
26
-
27
23
  Object.keys(_blobToBase).forEach(function (key) {
28
24
  if (key === "default" || key === "__esModule") return;
29
25
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -35,9 +31,7 @@ Object.keys(_blobToBase).forEach(function (key) {
35
31
  }
36
32
  });
37
33
  });
38
-
39
34
  var _compareVersion = require("./compareVersion");
40
-
41
35
  Object.keys(_compareVersion).forEach(function (key) {
42
36
  if (key === "default" || key === "__esModule") return;
43
37
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -49,9 +43,7 @@ Object.keys(_compareVersion).forEach(function (key) {
49
43
  }
50
44
  });
51
45
  });
52
-
53
46
  var _compressImage = require("./compressImage");
54
-
55
47
  Object.keys(_compressImage).forEach(function (key) {
56
48
  if (key === "default" || key === "__esModule") return;
57
49
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -63,9 +55,7 @@ Object.keys(_compressImage).forEach(function (key) {
63
55
  }
64
56
  });
65
57
  });
66
-
67
58
  var _createHexColorByHash = require("./createHexColorByHash");
68
-
69
59
  Object.keys(_createHexColorByHash).forEach(function (key) {
70
60
  if (key === "default" || key === "__esModule") return;
71
61
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -77,9 +67,7 @@ Object.keys(_createHexColorByHash).forEach(function (key) {
77
67
  }
78
68
  });
79
69
  });
80
-
81
70
  var _downloadFile = require("./downloadFile");
82
-
83
71
  Object.keys(_downloadFile).forEach(function (key) {
84
72
  if (key === "default" || key === "__esModule") return;
85
73
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -91,9 +79,7 @@ Object.keys(_downloadFile).forEach(function (key) {
91
79
  }
92
80
  });
93
81
  });
94
-
95
82
  var _filterBankCardNo = require("./filterBankCardNo");
96
-
97
83
  Object.keys(_filterBankCardNo).forEach(function (key) {
98
84
  if (key === "default" || key === "__esModule") return;
99
85
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -105,9 +91,7 @@ Object.keys(_filterBankCardNo).forEach(function (key) {
105
91
  }
106
92
  });
107
93
  });
108
-
109
94
  var _filterEmoji = require("./filterEmoji");
110
-
111
95
  Object.keys(_filterEmoji).forEach(function (key) {
112
96
  if (key === "default" || key === "__esModule") return;
113
97
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -119,9 +103,7 @@ Object.keys(_filterEmoji).forEach(function (key) {
119
103
  }
120
104
  });
121
105
  });
122
-
123
106
  var _filterIdCard = require("./filterIdCard");
124
-
125
107
  Object.keys(_filterIdCard).forEach(function (key) {
126
108
  if (key === "default" || key === "__esModule") return;
127
109
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -133,9 +115,7 @@ Object.keys(_filterIdCard).forEach(function (key) {
133
115
  }
134
116
  });
135
117
  });
136
-
137
118
  var _filterName = require("./filterName");
138
-
139
119
  Object.keys(_filterName).forEach(function (key) {
140
120
  if (key === "default" || key === "__esModule") return;
141
121
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -147,9 +127,7 @@ Object.keys(_filterName).forEach(function (key) {
147
127
  }
148
128
  });
149
129
  });
150
-
151
130
  var _filterPhone = require("./filterPhone");
152
-
153
131
  Object.keys(_filterPhone).forEach(function (key) {
154
132
  if (key === "default" || key === "__esModule") return;
155
133
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -161,9 +139,7 @@ Object.keys(_filterPhone).forEach(function (key) {
161
139
  }
162
140
  });
163
141
  });
164
-
165
142
  var _formatAmount = require("./formatAmount");
166
-
167
143
  Object.keys(_formatAmount).forEach(function (key) {
168
144
  if (key === "default" || key === "__esModule") return;
169
145
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -175,9 +151,7 @@ Object.keys(_formatAmount).forEach(function (key) {
175
151
  }
176
152
  });
177
153
  });
178
-
179
154
  var _formatDate = require("./formatDate");
180
-
181
155
  Object.keys(_formatDate).forEach(function (key) {
182
156
  if (key === "default" || key === "__esModule") return;
183
157
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -189,9 +163,7 @@ Object.keys(_formatDate).forEach(function (key) {
189
163
  }
190
164
  });
191
165
  });
192
-
193
166
  var _getBlobByUrl = require("./getBlobByUrl");
194
-
195
167
  Object.keys(_getBlobByUrl).forEach(function (key) {
196
168
  if (key === "default" || key === "__esModule") return;
197
169
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -203,9 +175,7 @@ Object.keys(_getBlobByUrl).forEach(function (key) {
203
175
  }
204
176
  });
205
177
  });
206
-
207
178
  var _getImageInfo = require("./getImageInfo");
208
-
209
179
  Object.keys(_getImageInfo).forEach(function (key) {
210
180
  if (key === "default" || key === "__esModule") return;
211
181
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -217,9 +187,7 @@ Object.keys(_getImageInfo).forEach(function (key) {
217
187
  }
218
188
  });
219
189
  });
220
-
221
190
  var _getVideoInfo = require("./getVideoInfo");
222
-
223
191
  Object.keys(_getVideoInfo).forEach(function (key) {
224
192
  if (key === "default" || key === "__esModule") return;
225
193
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -231,9 +199,7 @@ Object.keys(_getVideoInfo).forEach(function (key) {
231
199
  }
232
200
  });
233
201
  });
234
-
235
202
  var _isAndroid = require("./isAndroid");
236
-
237
203
  Object.keys(_isAndroid).forEach(function (key) {
238
204
  if (key === "default" || key === "__esModule") return;
239
205
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -245,9 +211,7 @@ Object.keys(_isAndroid).forEach(function (key) {
245
211
  }
246
212
  });
247
213
  });
248
-
249
214
  var _isEmail = require("./isEmail");
250
-
251
215
  Object.keys(_isEmail).forEach(function (key) {
252
216
  if (key === "default" || key === "__esModule") return;
253
217
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -259,9 +223,7 @@ Object.keys(_isEmail).forEach(function (key) {
259
223
  }
260
224
  });
261
225
  });
262
-
263
226
  var _isEmpty = require("./isEmpty");
264
-
265
227
  Object.keys(_isEmpty).forEach(function (key) {
266
228
  if (key === "default" || key === "__esModule") return;
267
229
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -273,9 +235,7 @@ Object.keys(_isEmpty).forEach(function (key) {
273
235
  }
274
236
  });
275
237
  });
276
-
277
238
  var _isFunction = require("./isFunction");
278
-
279
239
  Object.keys(_isFunction).forEach(function (key) {
280
240
  if (key === "default" || key === "__esModule") return;
281
241
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -287,9 +247,7 @@ Object.keys(_isFunction).forEach(function (key) {
287
247
  }
288
248
  });
289
249
  });
290
-
291
250
  var _isIOS = require("./isIOS");
292
-
293
251
  Object.keys(_isIOS).forEach(function (key) {
294
252
  if (key === "default" || key === "__esModule") return;
295
253
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -301,9 +259,7 @@ Object.keys(_isIOS).forEach(function (key) {
301
259
  }
302
260
  });
303
261
  });
304
-
305
262
  var _isIdCard = require("./isIdCard");
306
-
307
263
  Object.keys(_isIdCard).forEach(function (key) {
308
264
  if (key === "default" || key === "__esModule") return;
309
265
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -315,9 +271,7 @@ Object.keys(_isIdCard).forEach(function (key) {
315
271
  }
316
272
  });
317
273
  });
318
-
319
274
  var _isMobile = require("./isMobile");
320
-
321
275
  Object.keys(_isMobile).forEach(function (key) {
322
276
  if (key === "default" || key === "__esModule") return;
323
277
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -329,9 +283,7 @@ Object.keys(_isMobile).forEach(function (key) {
329
283
  }
330
284
  });
331
285
  });
332
-
333
286
  var _isNull = require("./isNull");
334
-
335
287
  Object.keys(_isNull).forEach(function (key) {
336
288
  if (key === "default" || key === "__esModule") return;
337
289
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -343,9 +295,7 @@ Object.keys(_isNull).forEach(function (key) {
343
295
  }
344
296
  });
345
297
  });
346
-
347
298
  var _isObject = require("./isObject");
348
-
349
299
  Object.keys(_isObject).forEach(function (key) {
350
300
  if (key === "default" || key === "__esModule") return;
351
301
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -357,9 +307,7 @@ Object.keys(_isObject).forEach(function (key) {
357
307
  }
358
308
  });
359
309
  });
360
-
361
310
  var _isPhone = require("./isPhone");
362
-
363
311
  Object.keys(_isPhone).forEach(function (key) {
364
312
  if (key === "default" || key === "__esModule") return;
365
313
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -371,9 +319,7 @@ Object.keys(_isPhone).forEach(function (key) {
371
319
  }
372
320
  });
373
321
  });
374
-
375
322
  var _isPromise = require("./isPromise");
376
-
377
323
  Object.keys(_isPromise).forEach(function (key) {
378
324
  if (key === "default" || key === "__esModule") return;
379
325
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -385,9 +331,7 @@ Object.keys(_isPromise).forEach(function (key) {
385
331
  }
386
332
  });
387
333
  });
388
-
389
334
  var _isRegExp = require("./isRegExp");
390
-
391
335
  Object.keys(_isRegExp).forEach(function (key) {
392
336
  if (key === "default" || key === "__esModule") return;
393
337
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -399,9 +343,7 @@ Object.keys(_isRegExp).forEach(function (key) {
399
343
  }
400
344
  });
401
345
  });
402
-
403
346
  var _isString = require("./isString");
404
-
405
347
  Object.keys(_isString).forEach(function (key) {
406
348
  if (key === "default" || key === "__esModule") return;
407
349
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -413,9 +355,7 @@ Object.keys(_isString).forEach(function (key) {
413
355
  }
414
356
  });
415
357
  });
416
-
417
358
  var _isUndefined = require("./isUndefined");
418
-
419
359
  Object.keys(_isUndefined).forEach(function (key) {
420
360
  if (key === "default" || key === "__esModule") return;
421
361
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -427,9 +367,7 @@ Object.keys(_isUndefined).forEach(function (key) {
427
367
  }
428
368
  });
429
369
  });
430
-
431
370
  var _omit = require("./omit");
432
-
433
371
  Object.keys(_omit).forEach(function (key) {
434
372
  if (key === "default" || key === "__esModule") return;
435
373
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -441,9 +379,7 @@ Object.keys(_omit).forEach(function (key) {
441
379
  }
442
380
  });
443
381
  });
444
-
445
382
  var _parseError = require("./parseError");
446
-
447
383
  Object.keys(_parseError).forEach(function (key) {
448
384
  if (key === "default" || key === "__esModule") return;
449
385
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -455,9 +391,7 @@ Object.keys(_parseError).forEach(function (key) {
455
391
  }
456
392
  });
457
393
  });
458
-
459
394
  var _parsePath = require("./parsePath");
460
-
461
395
  Object.keys(_parsePath).forEach(function (key) {
462
396
  if (key === "default" || key === "__esModule") return;
463
397
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -469,9 +403,7 @@ Object.keys(_parsePath).forEach(function (key) {
469
403
  }
470
404
  });
471
405
  });
472
-
473
406
  var _pick = require("./pick");
474
-
475
407
  Object.keys(_pick).forEach(function (key) {
476
408
  if (key === "default" || key === "__esModule") return;
477
409
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -483,9 +415,7 @@ Object.keys(_pick).forEach(function (key) {
483
415
  }
484
416
  });
485
417
  });
486
-
487
418
  var _replaceCrlf = require("./replaceCrlf");
488
-
489
419
  Object.keys(_replaceCrlf).forEach(function (key) {
490
420
  if (key === "default" || key === "__esModule") return;
491
421
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -497,9 +427,7 @@ Object.keys(_replaceCrlf).forEach(function (key) {
497
427
  }
498
428
  });
499
429
  });
500
-
501
430
  var _reserve = require("./reserve");
502
-
503
431
  Object.keys(_reserve).forEach(function (key) {
504
432
  if (key === "default" || key === "__esModule") return;
505
433
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -511,9 +439,7 @@ Object.keys(_reserve).forEach(function (key) {
511
439
  }
512
440
  });
513
441
  });
514
-
515
442
  var _storage = require("./storage");
516
-
517
443
  Object.keys(_storage).forEach(function (key) {
518
444
  if (key === "default" || key === "__esModule") return;
519
445
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -525,7 +451,6 @@ Object.keys(_storage).forEach(function (key) {
525
451
  }
526
452
  });
527
453
  });
528
-
529
454
  /* 本文件自动生成 './scripts/entry.js' */
530
455
  var version = '0.0.3';
531
456
  exports.version = version;
package/lib/isAndroid.js CHANGED
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.isAndroid = isAndroid;
7
-
8
7
  /**
9
8
  * 校验是否是安卓
10
9
  */
package/lib/isEmail.js CHANGED
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.isEmail = isEmail;
7
-
8
7
  /**
9
8
  * 校验是否是邮箱
10
9
  */
package/lib/isEmpty.js CHANGED
@@ -4,11 +4,8 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.isEmpty = isEmpty;
7
-
8
7
  var _isNull = require("./isNull");
9
-
10
8
  var _isUndefined = require("./isUndefined");
11
-
12
9
  /**
13
10
  * 校验是否为空 ''、undefined、null
14
11
  */
package/lib/isFunction.js CHANGED
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.isFunction = isFunction;
7
-
8
7
  /**
9
8
  * 校验是否是函数
10
9
  */