util-helpers 5.7.2 → 5.7.3
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 +18 -23
- 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/checkResult.js +18 -23
- package/lib/VERSION.js +1 -1
- package/lib/checkResult.js +17 -22
- package/package.json +1 -1
- package/types/checkResult.d.ts +29 -18
package/dist/util-helpers.js
CHANGED
|
@@ -1922,44 +1922,39 @@
|
|
|
1922
1922
|
return len;
|
|
1923
1923
|
}
|
|
1924
1924
|
|
|
1925
|
-
var checkResult = function () {
|
|
1926
|
-
var
|
|
1927
|
-
for (var _i =
|
|
1928
|
-
|
|
1925
|
+
var checkResult = function (fn) {
|
|
1926
|
+
var args = [];
|
|
1927
|
+
for (var _i = 1; _i < arguments.length; _i++) {
|
|
1928
|
+
args[_i - 1] = arguments[_i];
|
|
1929
1929
|
}
|
|
1930
|
-
return __awaiter(void 0,
|
|
1931
|
-
var
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
for (_a = 1; _a < arguments.length; _a++) {
|
|
1935
|
-
args[_a - 1] = arguments[_a];
|
|
1936
|
-
}
|
|
1937
|
-
return __generator(this, function (_e) {
|
|
1938
|
-
switch (_e.label) {
|
|
1930
|
+
return __awaiter(void 0, void 0, void 0, function () {
|
|
1931
|
+
var ret, _a, _b;
|
|
1932
|
+
return __generator(this, function (_d) {
|
|
1933
|
+
switch (_d.label) {
|
|
1939
1934
|
case 0:
|
|
1940
|
-
|
|
1935
|
+
_d.trys.push([0, 7, , 8]);
|
|
1941
1936
|
if (!(fn instanceof Promise)) return [3, 2];
|
|
1942
1937
|
return [4, fn];
|
|
1943
1938
|
case 1:
|
|
1944
|
-
|
|
1939
|
+
_a = _d.sent();
|
|
1945
1940
|
return [3, 6];
|
|
1946
1941
|
case 2:
|
|
1947
1942
|
if (!(typeof fn === 'function')) return [3, 4];
|
|
1948
1943
|
return [4, fn.apply(void 0, __spreadArray([], __read(args), false))];
|
|
1949
1944
|
case 3:
|
|
1950
|
-
|
|
1945
|
+
_b = _d.sent();
|
|
1951
1946
|
return [3, 5];
|
|
1952
1947
|
case 4:
|
|
1953
|
-
|
|
1954
|
-
|
|
1948
|
+
_b = fn;
|
|
1949
|
+
_d.label = 5;
|
|
1955
1950
|
case 5:
|
|
1956
|
-
|
|
1957
|
-
|
|
1951
|
+
_a = _b;
|
|
1952
|
+
_d.label = 6;
|
|
1958
1953
|
case 6:
|
|
1959
|
-
ret =
|
|
1954
|
+
ret = _a;
|
|
1960
1955
|
return [2, ret !== false];
|
|
1961
1956
|
case 7:
|
|
1962
|
-
|
|
1957
|
+
_d.sent();
|
|
1963
1958
|
return [2, false];
|
|
1964
1959
|
case 8: return [2];
|
|
1965
1960
|
}
|
|
@@ -2197,7 +2192,7 @@
|
|
|
2197
2192
|
return internalFindTreeSelect(tree, predicate, childrenField);
|
|
2198
2193
|
}
|
|
2199
2194
|
|
|
2200
|
-
var VERSION = "5.7.
|
|
2195
|
+
var VERSION = "5.7.3";
|
|
2201
2196
|
|
|
2202
2197
|
/**
|
|
2203
2198
|
* 事件触发器,支持浏览器端和 node 端。
|