util-helpers 4.20.7 → 4.20.8
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.
- package/dist/util-helpers.js +26 -20
- package/dist/util-helpers.js.map +1 -1
- package/dist/util-helpers.min.js +1 -1
- package/dist/util-helpers.min.js.map +1 -1
- package/esm/VERSION.js +1 -1
- package/esm/index.js +1 -1
- package/esm/utils/native.js +3 -2
- package/esm/utils/setup.js +3 -0
- package/lib/VERSION.js +1 -1
- package/lib/index.js +1 -1
- package/lib/utils/native.js +3 -2
- package/lib/utils/setup.js +3 -0
- package/package.json +2 -2
- package/types/utils/setup.d.ts +1 -0
package/esm/VERSION.js
CHANGED
package/esm/index.js
CHANGED
package/esm/utils/native.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { constant, noop } from 'ut2';
|
|
2
|
+
import { URLExisted } from './setup.js';
|
|
2
3
|
|
|
3
4
|
var objectKeys = Object.keys;
|
|
4
|
-
var createObjectURL =
|
|
5
|
-
var revokeObjectURL =
|
|
5
|
+
var createObjectURL = URLExisted ? URL.createObjectURL : constant('');
|
|
6
|
+
var revokeObjectURL = URLExisted ? URL.revokeObjectURL : noop;
|
|
6
7
|
|
|
7
8
|
export { createObjectURL, objectKeys, revokeObjectURL };
|
package/lib/VERSION.js
CHANGED
package/lib/index.js
CHANGED
|
@@ -65,7 +65,7 @@ var findTreeSelect = require('./findTreeSelect.js');
|
|
|
65
65
|
var config = require('./utils/config.js');
|
|
66
66
|
var VERSION = require('./VERSION.js');
|
|
67
67
|
|
|
68
|
-
exports.version = "4.20.
|
|
68
|
+
exports.version = "4.20.8";
|
|
69
69
|
|
|
70
70
|
exports.isMobile = isMobile;
|
|
71
71
|
exports.isTelephone = isTelephone;
|
package/lib/utils/native.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var ut2 = require('ut2');
|
|
4
|
+
var setup = require('./setup.js');
|
|
4
5
|
|
|
5
6
|
exports.objectKeys = Object.keys;
|
|
6
|
-
exports.createObjectURL =
|
|
7
|
-
exports.revokeObjectURL =
|
|
7
|
+
exports.createObjectURL = setup.URLExisted ? URL.createObjectURL : ut2.constant('');
|
|
8
|
+
exports.revokeObjectURL = setup.URLExisted ? URL.revokeObjectURL : ut2.noop;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "util-helpers",
|
|
3
|
-
"version": "4.20.
|
|
3
|
+
"version": "4.20.8",
|
|
4
4
|
"description": "一个基于业务场景的工具方法库",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "esm/index.js",
|
|
@@ -91,6 +91,6 @@
|
|
|
91
91
|
},
|
|
92
92
|
"dependencies": {
|
|
93
93
|
"tslib": "^2.6.2",
|
|
94
|
-
"ut2": "^1.
|
|
94
|
+
"ut2": "^1.5.2"
|
|
95
95
|
}
|
|
96
96
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const URLExisted: boolean;
|