amos-tool 1.5.3 → 1.6.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.
- package/docs/Logger.html +1 -1
- package/docs/global.html +3 -3
- package/docs/index.html +1 -1
- package/index.d.ts +2 -2
- package/lib/dom/fileSaveAs.js +6 -6
- package/lib/utils.js +2 -0
- package/package.json +2 -2
package/docs/Logger.html
CHANGED
|
@@ -336,7 +336,7 @@ isDebug: true
|
|
|
336
336
|
<br class="clear">
|
|
337
337
|
|
|
338
338
|
<footer>
|
|
339
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.6</a> on
|
|
339
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.6</a> on Wed Apr 26 2023 17:47:26 GMT+0800 (GMT+08:00) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
340
340
|
</footer>
|
|
341
341
|
|
|
342
342
|
<script>prettyPrint();</script>
|
package/docs/global.html
CHANGED
|
@@ -8892,7 +8892,7 @@ Object 对象,typeof === object && toString === '[object Object]'</p>
|
|
|
8892
8892
|
|
|
8893
8893
|
|
|
8894
8894
|
|
|
8895
|
-
<td class="description last"></td>
|
|
8895
|
+
<td class="description last"><p>如果 obj 是 null or undefined 则直接 返回 false</p></td>
|
|
8896
8896
|
</tr>
|
|
8897
8897
|
|
|
8898
8898
|
|
|
@@ -10030,7 +10030,7 @@ isNil(NaN)
|
|
|
10030
10030
|
|
|
10031
10031
|
|
|
10032
10032
|
|
|
10033
|
-
<td class="description last"></td>
|
|
10033
|
+
<td class="description last"><p>如果 obj 是 null or undefined 则直接 返回 false</p></td>
|
|
10034
10034
|
</tr>
|
|
10035
10035
|
|
|
10036
10036
|
|
|
@@ -16595,7 +16595,7 @@ schedule <code>callback</code> to execute after <code>delay</code> ms.</p></td>
|
|
|
16595
16595
|
<br class="clear">
|
|
16596
16596
|
|
|
16597
16597
|
<footer>
|
|
16598
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.6</a> on
|
|
16598
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.6</a> on Wed Apr 26 2023 17:47:26 GMT+0800 (GMT+08:00) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
16599
16599
|
</footer>
|
|
16600
16600
|
|
|
16601
16601
|
<script>prettyPrint();</script>
|
package/docs/index.html
CHANGED
|
@@ -785,7 +785,7 @@ convert2BMP(canvas, width, height)</p>
|
|
|
785
785
|
<br class="clear">
|
|
786
786
|
|
|
787
787
|
<footer>
|
|
788
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.6</a> on
|
|
788
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.6</a> on Wed Apr 26 2023 17:47:26 GMT+0800 (GMT+08:00) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
789
789
|
</footer>
|
|
790
790
|
|
|
791
791
|
<script>prettyPrint();</script>
|
package/index.d.ts
CHANGED
|
@@ -1059,14 +1059,14 @@ declare namespace utils {
|
|
|
1059
1059
|
* 判断key是否在object内
|
|
1060
1060
|
* (采用 in 判断,继承属性均会判断)
|
|
1061
1061
|
* @param keys
|
|
1062
|
-
* @param obj
|
|
1062
|
+
* @param obj 如果 obj 是 null or undefined, 或者 非 object,则直接 返回 false
|
|
1063
1063
|
*/
|
|
1064
1064
|
export function isKeyInObject(keys: string | string[], obj: any): boolean;
|
|
1065
1065
|
/**
|
|
1066
1066
|
* 判断key是否在object内
|
|
1067
1067
|
* (采用 hasOwnProperty 判断,继承属性不会判断)
|
|
1068
1068
|
* @param keys
|
|
1069
|
-
* @param obj
|
|
1069
|
+
* @param obj 如果 obj 是 null or undefined, 或者 非 object,则直接 返回 false
|
|
1070
1070
|
*/
|
|
1071
1071
|
export function isOwnKeyInObject(keys: string | string[], obj: any): boolean;
|
|
1072
1072
|
/**
|
package/lib/dom/fileSaveAs.js
CHANGED
|
@@ -32,7 +32,7 @@ var _saveAs = function(e) {
|
|
|
32
32
|
};
|
|
33
33
|
if (v.readyState = v.INIT, r) return l = n().createObjectURL(t), void setTimeout((function() {
|
|
34
34
|
var e, t;
|
|
35
|
-
o.href = l, o.download = f, e = o, t = new MouseEvent("click"), e.dispatchEvent(t),
|
|
35
|
+
o.href = l, o.download = f, e = o, t = new MouseEvent("click"), e.dispatchEvent(t),
|
|
36
36
|
w(), d(l), v.readyState = v.DONE;
|
|
37
37
|
}));
|
|
38
38
|
!function() {
|
|
@@ -40,7 +40,7 @@ var _saveAs = function(e) {
|
|
|
40
40
|
var o = new FileReader;
|
|
41
41
|
return o.onloadend = function() {
|
|
42
42
|
var t = i ? o.result : o.result.replace(/^data:[^;]*;/, "data:attachment/file;");
|
|
43
|
-
e.open(t, "_blank") || (e.location.href = t), t = void 0, v.readyState = v.DONE,
|
|
43
|
+
e.open(t, "_blank") || (e.location.href = t), t = void 0, v.readyState = v.DONE,
|
|
44
44
|
w();
|
|
45
45
|
}, o.readAsDataURL(t), void (v.readyState = v.INIT);
|
|
46
46
|
}
|
|
@@ -50,12 +50,12 @@ var _saveAs = function(e) {
|
|
|
50
50
|
}, u = f.prototype;
|
|
51
51
|
return "undefined" != typeof navigator && navigator.msSaveOrOpenBlob ? function(e, t, n) {
|
|
52
52
|
return t = t || e.name || "download", n || (e = s(e)), navigator.msSaveOrOpenBlob(e, t);
|
|
53
|
-
} : (u.abort = function() {}, u.readyState = u.INIT = 0, u.WRITING = 1, u.DONE = 2,
|
|
54
|
-
u.error = u.onwritestart = u.onprogress = u.onwrite = u.onabort = u.onerror = u.onwriteend = null,
|
|
53
|
+
} : (u.abort = function() {}, u.readyState = u.INIT = 0, u.WRITING = 1, u.DONE = 2,
|
|
54
|
+
u.error = u.onwritestart = u.onprogress = u.onwrite = u.onabort = u.onerror = u.onwriteend = null,
|
|
55
55
|
function(e, t, n) {
|
|
56
56
|
return new f(e, t || e.name || "download", n);
|
|
57
57
|
});
|
|
58
58
|
}
|
|
59
|
-
}, view = "undefined" != typeof self && self || "undefined" != typeof window && window ||
|
|
59
|
+
}, view = "undefined" != typeof self && self || "undefined" != typeof window && window || this.content;
|
|
60
60
|
|
|
61
|
-
module.exports = _saveAs(view);
|
|
61
|
+
module.exports = _saveAs(view);
|
package/lib/utils.js
CHANGED
|
@@ -117,12 +117,14 @@ var stringIsJson = function(e) {
|
|
|
117
117
|
return _isJSON(e);
|
|
118
118
|
}
|
|
119
119
|
}, isKeyInObject = function(e, t) {
|
|
120
|
+
if (isNil(t) || !isObject(t)) return !1;
|
|
120
121
|
isString(e) && (e = [ e ]);
|
|
121
122
|
var n = 0;
|
|
122
123
|
return e.forEach((function(e) {
|
|
123
124
|
e in t && n++;
|
|
124
125
|
})), e.length === n;
|
|
125
126
|
}, isOwnKeyInObject = function(e, t) {
|
|
127
|
+
if (isNil(t) || !isObject(t)) return !1;
|
|
126
128
|
isString(e) && (e = [ e ]);
|
|
127
129
|
var n = 0;
|
|
128
130
|
return e.forEach((function(e) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "amos-tool",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "amos ui tool",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"directories": {
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"testUUID": "mocha tests/uuid.test",
|
|
12
12
|
"testFilter": "mocha tests/tablefilter.test",
|
|
13
13
|
"docs": "node_modules/.bin/jsdoc -c jsdoc-ori.json --readme README.md",
|
|
14
|
-
"build": "ac-build babel-es5",
|
|
14
|
+
"build": "ac-build babel-es5 && gulp move",
|
|
15
15
|
"build2": "rollup -c",
|
|
16
16
|
"doc": "ac-doc docall",
|
|
17
17
|
"pub": "npm run doc && npm run build && npm publish"
|