@powfix/core-js 0.23.8 → 0.24.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/dist/chunk-AQ5VUG5P.js +39 -0
- package/dist/chunk-JE77HYXB.cjs +43 -0
- package/dist/node/constants/TransactionManagerLogLevel.cjs +1 -1
- package/dist/node/constants/TransactionManagerLogLevel.js +1 -1
- package/dist/node/constants/TransactionManagerTimeoutAction.cjs +1 -1
- package/dist/node/constants/TransactionManagerTimeoutAction.js +1 -1
- package/dist/node/managers/TransactionManager.cjs +7 -7
- package/dist/node/managers/TransactionManager.js +1 -1
- package/dist/node/services/redis/RedisClient.cjs +4 -4
- package/dist/node/services/redis/RedisClient.js +1 -1
- package/dist/node/services/redis/RedisPublisher.cjs +2 -2
- package/dist/node/services/redis/RedisPublisher.js +1 -1
- package/dist/node/services/redis/RedisSubscriber.cjs +1 -1
- package/dist/node/services/redis/RedisSubscriber.js +1 -1
- package/dist/node/utils/HookUtils.cjs +1 -1
- package/dist/node/utils/HookUtils.js +1 -1
- package/dist/node/utils/sequelize-utils/SequelizeUtils.cjs +15 -26
- package/dist/node/utils/sequelize-utils/SequelizeUtils.js +14 -25
- package/dist/shared/constants/COORDINATE.cjs +5 -5
- package/dist/shared/constants/COORDINATE.js +1 -1
- package/dist/shared/constants/CRUD.cjs +1 -1
- package/dist/shared/constants/CRUD.js +1 -1
- package/dist/shared/constants/DATE.cjs +1 -1
- package/dist/shared/constants/DATE.js +1 -1
- package/dist/shared/constants/DISTANCE.cjs +1 -1
- package/dist/shared/constants/DISTANCE.js +1 -1
- package/dist/shared/constants/DURATION.cjs +1 -1
- package/dist/shared/constants/DURATION.js +1 -1
- package/dist/shared/constants/NOT_NULL.cjs +1 -1
- package/dist/shared/constants/NOT_NULL.js +1 -1
- package/dist/shared/features/WatchablePromise.cjs +203 -0
- package/dist/shared/features/WatchablePromise.d.ts +8 -0
- package/dist/shared/features/WatchablePromise.js +203 -0
- package/dist/shared/features/WatchablePromise.types.cjs +1 -0
- package/dist/shared/features/WatchablePromise.types.d.ts +1 -0
- package/dist/shared/features/WatchablePromise.types.js +0 -0
- package/dist/shared/features/index.cjs +10 -0
- package/dist/shared/features/index.d.ts +2 -0
- package/dist/shared/features/index.js +1 -0
- package/dist/shared/index.cjs +9 -0
- package/dist/shared/index.d.ts +1 -0
- package/dist/shared/index.js +1 -0
- package/dist/shared/managers/SessionManager.cjs +4 -4
- package/dist/shared/managers/SessionManager.js +1 -1
- package/dist/shared/scripts/base64Polyfill.cjs +1 -1
- package/dist/shared/scripts/base64Polyfill.js +1 -1
- package/dist/shared/services/time/TimeService.cjs +7 -7
- package/dist/shared/services/time/TimeService.js +1 -1
- package/dist/shared/utils/ArrayUtils.cjs +1 -1
- package/dist/shared/utils/ArrayUtils.js +1 -1
- package/dist/shared/utils/AxiosUtils.cjs +1 -1
- package/dist/shared/utils/AxiosUtils.js +1 -1
- package/dist/shared/utils/BooleanUtils.cjs +1 -1
- package/dist/shared/utils/BooleanUtils.js +1 -1
- package/dist/shared/utils/Calc.cjs +1 -1
- package/dist/shared/utils/Calc.js +1 -1
- package/dist/shared/utils/CoordinateUtils.cjs +1 -1
- package/dist/shared/utils/CoordinateUtils.js +1 -1
- package/dist/shared/utils/DateUtils.cjs +4 -4
- package/dist/shared/utils/DateUtils.js +1 -1
- package/dist/shared/utils/Enum.cjs +5 -5
- package/dist/shared/utils/Enum.js +1 -1
- package/dist/shared/utils/I18nUtils.cjs +1 -1
- package/dist/shared/utils/I18nUtils.js +1 -1
- package/dist/shared/utils/JuminNumberUtils.cjs +1 -1
- package/dist/shared/utils/JuminNumberUtils.js +1 -1
- package/dist/shared/utils/NumberUtils.cjs +1 -1
- package/dist/shared/utils/NumberUtils.js +1 -1
- package/dist/shared/utils/ObjectIdUtils.cjs +1 -1
- package/dist/shared/utils/ObjectIdUtils.js +1 -1
- package/dist/shared/utils/Point3Utils.cjs +1 -1
- package/dist/shared/utils/Point3Utils.js +1 -1
- package/dist/shared/utils/RandomUtils.cjs +1 -1
- package/dist/shared/utils/RandomUtils.js +1 -1
- package/dist/shared/utils/Sequencer.cjs +10 -10
- package/dist/shared/utils/Sequencer.js +1 -1
- package/dist/shared/utils/StringUtils.cjs +2 -2
- package/dist/shared/utils/StringUtils.js +1 -1
- package/dist/shared/utils/Uint8ArrayUtils.cjs +1 -1
- package/dist/shared/utils/Uint8ArrayUtils.js +1 -1
- package/dist/shared/utils/UuidUtils.cjs +1 -1
- package/dist/shared/utils/UuidUtils.js +1 -1
- package/dist/shared/utils/Validator.cjs +1 -1
- package/dist/shared/utils/Validator.js +1 -1
- package/dist/shared/utils/global/atob.cjs +1 -1
- package/dist/shared/utils/global/atob.js +1 -1
- package/dist/shared/utils/global/base64.cjs +1 -1
- package/dist/shared/utils/global/base64.js +1 -1
- package/dist/shared/utils/global/between.cjs +1 -1
- package/dist/shared/utils/global/between.js +1 -1
- package/dist/shared/utils/global/btoa.cjs +1 -1
- package/dist/shared/utils/global/btoa.js +1 -1
- package/dist/shared/utils/global/castArray.cjs +1 -1
- package/dist/shared/utils/global/castArray.js +1 -1
- package/dist/shared/utils/global/circularDistance.cjs +1 -1
- package/dist/shared/utils/global/circularDistance.js +1 -1
- package/dist/shared/utils/global/fallbackIfMatch.cjs +1 -1
- package/dist/shared/utils/global/fallbackIfMatch.js +1 -1
- package/dist/shared/utils/global/fallbackIfNull.cjs +1 -1
- package/dist/shared/utils/global/fallbackIfNull.js +1 -1
- package/dist/shared/utils/global/fallbackIfNullish.cjs +1 -1
- package/dist/shared/utils/global/fallbackIfNullish.js +1 -1
- package/dist/shared/utils/global/fallbackIfUndefined.cjs +1 -1
- package/dist/shared/utils/global/fallbackIfUndefined.js +1 -1
- package/dist/shared/utils/global/firstNonNullish.cjs +1 -1
- package/dist/shared/utils/global/firstNonNullish.js +1 -1
- package/dist/shared/utils/global/flat.cjs +1 -1
- package/dist/shared/utils/global/flat.js +1 -1
- package/dist/shared/utils/global/mapIfNotNullish.cjs +1 -1
- package/dist/shared/utils/global/mapIfNotNullish.js +1 -1
- package/dist/shared/utils/global/processFirstNonNullish.cjs +1 -1
- package/dist/shared/utils/global/processFirstNonNullish.js +1 -1
- package/dist/shared/utils/global/pureEnum.cjs +1 -1
- package/dist/shared/utils/global/pureEnum.js +1 -1
- package/dist/shared/utils/global/sleep.cjs +1 -1
- package/dist/shared/utils/global/sleep.js +1 -1
- package/dist/shared/utils/try-catch/TryCatch.cjs +1 -1
- package/dist/shared/utils/try-catch/TryCatch.js +1 -1
- package/package.json +4 -4
- package/dist/chunk-ETV4XYOV.cjs +0 -18
- package/dist/chunk-PKBMQBKP.js +0 -17
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
function _array_like_to_array(arr, len) {
|
|
3
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
4
|
+
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
5
|
+
return arr2;
|
|
6
|
+
}
|
|
7
|
+
function _array_without_holes(arr) {
|
|
8
|
+
if (Array.isArray(arr)) return _array_like_to_array(arr);
|
|
9
|
+
}
|
|
10
|
+
function _assert_this_initialized(self) {
|
|
11
|
+
if (self === void 0) {
|
|
12
|
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
13
|
+
}
|
|
14
|
+
return self;
|
|
15
|
+
}
|
|
16
|
+
function _call_super(_this, derived, args) {
|
|
17
|
+
derived = _get_prototype_of(derived);
|
|
18
|
+
return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
|
|
19
|
+
}
|
|
20
|
+
function _class_call_check(instance, Constructor) {
|
|
21
|
+
if (!(instance instanceof Constructor)) {
|
|
22
|
+
throw new TypeError("Cannot call a class as a function");
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
function _construct(Parent, args, Class) {
|
|
26
|
+
if (_is_native_reflect_construct()) {
|
|
27
|
+
_construct = Reflect.construct;
|
|
28
|
+
} else {
|
|
29
|
+
_construct = function construct(Parent, args, Class) {
|
|
30
|
+
var a = [
|
|
31
|
+
null
|
|
32
|
+
];
|
|
33
|
+
a.push.apply(a, args);
|
|
34
|
+
var Constructor = Function.bind.apply(Parent, a);
|
|
35
|
+
var instance = new Constructor();
|
|
36
|
+
if (Class) _set_prototype_of(instance, Class.prototype);
|
|
37
|
+
return instance;
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
return _construct.apply(null, arguments);
|
|
41
|
+
}
|
|
42
|
+
function _defineProperties(target, props) {
|
|
43
|
+
for(var i = 0; i < props.length; i++){
|
|
44
|
+
var descriptor = props[i];
|
|
45
|
+
descriptor.enumerable = descriptor.enumerable || false;
|
|
46
|
+
descriptor.configurable = true;
|
|
47
|
+
if ("value" in descriptor) descriptor.writable = true;
|
|
48
|
+
Object.defineProperty(target, descriptor.key, descriptor);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
function _create_class(Constructor, protoProps, staticProps) {
|
|
52
|
+
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
53
|
+
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
54
|
+
return Constructor;
|
|
55
|
+
}
|
|
56
|
+
function _get_prototype_of(o) {
|
|
57
|
+
_get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
|
|
58
|
+
return o.__proto__ || Object.getPrototypeOf(o);
|
|
59
|
+
};
|
|
60
|
+
return _get_prototype_of(o);
|
|
61
|
+
}
|
|
62
|
+
function _inherits(subClass, superClass) {
|
|
63
|
+
if (typeof superClass !== "function" && superClass !== null) {
|
|
64
|
+
throw new TypeError("Super expression must either be null or a function");
|
|
65
|
+
}
|
|
66
|
+
subClass.prototype = Object.create(superClass && superClass.prototype, {
|
|
67
|
+
constructor: {
|
|
68
|
+
value: subClass,
|
|
69
|
+
writable: true,
|
|
70
|
+
configurable: true
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
if (superClass) _set_prototype_of(subClass, superClass);
|
|
74
|
+
}
|
|
75
|
+
function _is_native_function(fn) {
|
|
76
|
+
return Function.toString.call(fn).indexOf("[native code]") !== -1;
|
|
77
|
+
}
|
|
78
|
+
function _iterable_to_array(iter) {
|
|
79
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
80
|
+
}
|
|
81
|
+
function _non_iterable_spread() {
|
|
82
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
83
|
+
}
|
|
84
|
+
function _possible_constructor_return(self, call) {
|
|
85
|
+
if (call && (_type_of(call) === "object" || typeof call === "function")) {
|
|
86
|
+
return call;
|
|
87
|
+
}
|
|
88
|
+
return _assert_this_initialized(self);
|
|
89
|
+
}
|
|
90
|
+
function _set_prototype_of(o, p) {
|
|
91
|
+
_set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
92
|
+
o.__proto__ = p;
|
|
93
|
+
return o;
|
|
94
|
+
};
|
|
95
|
+
return _set_prototype_of(o, p);
|
|
96
|
+
}
|
|
97
|
+
function _to_consumable_array(arr) {
|
|
98
|
+
return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
|
|
99
|
+
}
|
|
100
|
+
function _type_of(obj) {
|
|
101
|
+
"@swc/helpers - typeof";
|
|
102
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
103
|
+
}
|
|
104
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
105
|
+
if (!o) return;
|
|
106
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
107
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
108
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
109
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
110
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
111
|
+
}
|
|
112
|
+
function _wrap_native_super(Class) {
|
|
113
|
+
var _cache = typeof Map === "function" ? new Map() : undefined;
|
|
114
|
+
_wrap_native_super = function wrapNativeSuper(Class) {
|
|
115
|
+
if (Class === null || !_is_native_function(Class)) return Class;
|
|
116
|
+
if (typeof Class !== "function") {
|
|
117
|
+
throw new TypeError("Super expression must either be null or a function");
|
|
118
|
+
}
|
|
119
|
+
if (typeof _cache !== "undefined") {
|
|
120
|
+
if (_cache.has(Class)) return _cache.get(Class);
|
|
121
|
+
_cache.set(Class, Wrapper);
|
|
122
|
+
}
|
|
123
|
+
function Wrapper() {
|
|
124
|
+
return _construct(Class, arguments, _get_prototype_of(this).constructor);
|
|
125
|
+
}
|
|
126
|
+
Wrapper.prototype = Object.create(Class.prototype, {
|
|
127
|
+
constructor: {
|
|
128
|
+
value: Wrapper,
|
|
129
|
+
enumerable: false,
|
|
130
|
+
writable: true,
|
|
131
|
+
configurable: true
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
return _set_prototype_of(Wrapper, Class);
|
|
135
|
+
};
|
|
136
|
+
return _wrap_native_super(Class);
|
|
137
|
+
}
|
|
138
|
+
function _is_native_reflect_construct() {
|
|
139
|
+
try {
|
|
140
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
141
|
+
} catch (_) {}
|
|
142
|
+
return (_is_native_reflect_construct = function() {
|
|
143
|
+
return !!result;
|
|
144
|
+
})();
|
|
145
|
+
}
|
|
146
|
+
var chunkJE77HYXB_cjs = require('../../chunk-JE77HYXB.cjs');
|
|
147
|
+
var _settled, _status, _result;
|
|
148
|
+
var WatchablePromise = /*#__PURE__*/ function(Promise1) {
|
|
149
|
+
_inherits(WatchablePromise, Promise1);
|
|
150
|
+
function WatchablePromise(executor) {
|
|
151
|
+
var _this = this;
|
|
152
|
+
_class_call_check(this, WatchablePromise);
|
|
153
|
+
var _this1;
|
|
154
|
+
var __super = function() {
|
|
155
|
+
for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){
|
|
156
|
+
args[_key] = arguments[_key];
|
|
157
|
+
}
|
|
158
|
+
_this1 = _call_super(_this, WatchablePromise, _to_consumable_array(args));
|
|
159
|
+
chunkJE77HYXB_cjs.__privateAdd(_this1, _settled, false);
|
|
160
|
+
chunkJE77HYXB_cjs.__privateAdd(_this1, _status, "pending");
|
|
161
|
+
chunkJE77HYXB_cjs.__privateAdd(_this1, _result);
|
|
162
|
+
return _this1;
|
|
163
|
+
};
|
|
164
|
+
__super(executor);
|
|
165
|
+
__super(function(resolve, reject) {
|
|
166
|
+
executor(function(value) {
|
|
167
|
+
resolve(value);
|
|
168
|
+
chunkJE77HYXB_cjs.__privateSet(_assert_this_initialized(_this1), _status, "fulfilled");
|
|
169
|
+
chunkJE77HYXB_cjs.__privateSet(_assert_this_initialized(_this1), _result, value);
|
|
170
|
+
}, function(reason) {
|
|
171
|
+
reject(reason);
|
|
172
|
+
chunkJE77HYXB_cjs.__privateSet(_assert_this_initialized(_this1), _status, "rejected");
|
|
173
|
+
chunkJE77HYXB_cjs.__privateSet(_assert_this_initialized(_this1), _result, reason);
|
|
174
|
+
});
|
|
175
|
+
});
|
|
176
|
+
return _assert_this_initialized(_this1);
|
|
177
|
+
}
|
|
178
|
+
_create_class(WatchablePromise, [
|
|
179
|
+
{
|
|
180
|
+
key: "settled",
|
|
181
|
+
get: function get() {
|
|
182
|
+
return chunkJE77HYXB_cjs.__privateGet(this, _settled);
|
|
183
|
+
}
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
key: "status",
|
|
187
|
+
get: function get() {
|
|
188
|
+
return chunkJE77HYXB_cjs.__privateGet(this, _status);
|
|
189
|
+
}
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
key: "result",
|
|
193
|
+
get: function get() {
|
|
194
|
+
return chunkJE77HYXB_cjs.__privateGet(this, _result);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
]);
|
|
198
|
+
return WatchablePromise;
|
|
199
|
+
}(_wrap_native_super(Promise));
|
|
200
|
+
_settled = new WeakMap();
|
|
201
|
+
_status = new WeakMap();
|
|
202
|
+
_result = new WeakMap();
|
|
203
|
+
exports.WatchablePromise = WatchablePromise;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { WatchablePromiseStatus } from "./WatchablePromise.types.js";
|
|
2
|
+
export declare class WatchablePromise<T, E = Error> extends Promise<T> {
|
|
3
|
+
#private;
|
|
4
|
+
constructor(executor: (resolve: (value: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void);
|
|
5
|
+
get settled(): boolean;
|
|
6
|
+
get status(): WatchablePromiseStatus;
|
|
7
|
+
get result(): T | PromiseLike<T> | E | undefined;
|
|
8
|
+
}
|
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
function _array_like_to_array(arr, len) {
|
|
2
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
3
|
+
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
4
|
+
return arr2;
|
|
5
|
+
}
|
|
6
|
+
function _array_without_holes(arr) {
|
|
7
|
+
if (Array.isArray(arr)) return _array_like_to_array(arr);
|
|
8
|
+
}
|
|
9
|
+
function _assert_this_initialized(self) {
|
|
10
|
+
if (self === void 0) {
|
|
11
|
+
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
12
|
+
}
|
|
13
|
+
return self;
|
|
14
|
+
}
|
|
15
|
+
function _call_super(_this, derived, args) {
|
|
16
|
+
derived = _get_prototype_of(derived);
|
|
17
|
+
return _possible_constructor_return(_this, _is_native_reflect_construct() ? Reflect.construct(derived, args || [], _get_prototype_of(_this).constructor) : derived.apply(_this, args));
|
|
18
|
+
}
|
|
19
|
+
function _class_call_check(instance, Constructor) {
|
|
20
|
+
if (!(instance instanceof Constructor)) {
|
|
21
|
+
throw new TypeError("Cannot call a class as a function");
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
function _construct(Parent, args, Class) {
|
|
25
|
+
if (_is_native_reflect_construct()) {
|
|
26
|
+
_construct = Reflect.construct;
|
|
27
|
+
} else {
|
|
28
|
+
_construct = function construct(Parent, args, Class) {
|
|
29
|
+
var a = [
|
|
30
|
+
null
|
|
31
|
+
];
|
|
32
|
+
a.push.apply(a, args);
|
|
33
|
+
var Constructor = Function.bind.apply(Parent, a);
|
|
34
|
+
var instance = new Constructor();
|
|
35
|
+
if (Class) _set_prototype_of(instance, Class.prototype);
|
|
36
|
+
return instance;
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
return _construct.apply(null, arguments);
|
|
40
|
+
}
|
|
41
|
+
function _defineProperties(target, props) {
|
|
42
|
+
for(var i = 0; i < props.length; i++){
|
|
43
|
+
var descriptor = props[i];
|
|
44
|
+
descriptor.enumerable = descriptor.enumerable || false;
|
|
45
|
+
descriptor.configurable = true;
|
|
46
|
+
if ("value" in descriptor) descriptor.writable = true;
|
|
47
|
+
Object.defineProperty(target, descriptor.key, descriptor);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
function _create_class(Constructor, protoProps, staticProps) {
|
|
51
|
+
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
52
|
+
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
53
|
+
return Constructor;
|
|
54
|
+
}
|
|
55
|
+
function _get_prototype_of(o) {
|
|
56
|
+
_get_prototype_of = Object.setPrototypeOf ? Object.getPrototypeOf : function getPrototypeOf(o) {
|
|
57
|
+
return o.__proto__ || Object.getPrototypeOf(o);
|
|
58
|
+
};
|
|
59
|
+
return _get_prototype_of(o);
|
|
60
|
+
}
|
|
61
|
+
function _inherits(subClass, superClass) {
|
|
62
|
+
if (typeof superClass !== "function" && superClass !== null) {
|
|
63
|
+
throw new TypeError("Super expression must either be null or a function");
|
|
64
|
+
}
|
|
65
|
+
subClass.prototype = Object.create(superClass && superClass.prototype, {
|
|
66
|
+
constructor: {
|
|
67
|
+
value: subClass,
|
|
68
|
+
writable: true,
|
|
69
|
+
configurable: true
|
|
70
|
+
}
|
|
71
|
+
});
|
|
72
|
+
if (superClass) _set_prototype_of(subClass, superClass);
|
|
73
|
+
}
|
|
74
|
+
function _is_native_function(fn) {
|
|
75
|
+
return Function.toString.call(fn).indexOf("[native code]") !== -1;
|
|
76
|
+
}
|
|
77
|
+
function _iterable_to_array(iter) {
|
|
78
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
79
|
+
}
|
|
80
|
+
function _non_iterable_spread() {
|
|
81
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
82
|
+
}
|
|
83
|
+
function _possible_constructor_return(self, call) {
|
|
84
|
+
if (call && (_type_of(call) === "object" || typeof call === "function")) {
|
|
85
|
+
return call;
|
|
86
|
+
}
|
|
87
|
+
return _assert_this_initialized(self);
|
|
88
|
+
}
|
|
89
|
+
function _set_prototype_of(o, p) {
|
|
90
|
+
_set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
91
|
+
o.__proto__ = p;
|
|
92
|
+
return o;
|
|
93
|
+
};
|
|
94
|
+
return _set_prototype_of(o, p);
|
|
95
|
+
}
|
|
96
|
+
function _to_consumable_array(arr) {
|
|
97
|
+
return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
|
|
98
|
+
}
|
|
99
|
+
function _type_of(obj) {
|
|
100
|
+
"@swc/helpers - typeof";
|
|
101
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
102
|
+
}
|
|
103
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
104
|
+
if (!o) return;
|
|
105
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
106
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
107
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
108
|
+
if (n === "Map" || n === "Set") return Array.from(n);
|
|
109
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
110
|
+
}
|
|
111
|
+
function _wrap_native_super(Class) {
|
|
112
|
+
var _cache = typeof Map === "function" ? new Map() : undefined;
|
|
113
|
+
_wrap_native_super = function wrapNativeSuper(Class) {
|
|
114
|
+
if (Class === null || !_is_native_function(Class)) return Class;
|
|
115
|
+
if (typeof Class !== "function") {
|
|
116
|
+
throw new TypeError("Super expression must either be null or a function");
|
|
117
|
+
}
|
|
118
|
+
if (typeof _cache !== "undefined") {
|
|
119
|
+
if (_cache.has(Class)) return _cache.get(Class);
|
|
120
|
+
_cache.set(Class, Wrapper);
|
|
121
|
+
}
|
|
122
|
+
function Wrapper() {
|
|
123
|
+
return _construct(Class, arguments, _get_prototype_of(this).constructor);
|
|
124
|
+
}
|
|
125
|
+
Wrapper.prototype = Object.create(Class.prototype, {
|
|
126
|
+
constructor: {
|
|
127
|
+
value: Wrapper,
|
|
128
|
+
enumerable: false,
|
|
129
|
+
writable: true,
|
|
130
|
+
configurable: true
|
|
131
|
+
}
|
|
132
|
+
});
|
|
133
|
+
return _set_prototype_of(Wrapper, Class);
|
|
134
|
+
};
|
|
135
|
+
return _wrap_native_super(Class);
|
|
136
|
+
}
|
|
137
|
+
function _is_native_reflect_construct() {
|
|
138
|
+
try {
|
|
139
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
140
|
+
} catch (_) {}
|
|
141
|
+
return (_is_native_reflect_construct = function() {
|
|
142
|
+
return !!result;
|
|
143
|
+
})();
|
|
144
|
+
}
|
|
145
|
+
import { __privateGet, __privateAdd, __privateSet } from '../../chunk-AQ5VUG5P.js';
|
|
146
|
+
var _settled, _status, _result;
|
|
147
|
+
var WatchablePromise = /*#__PURE__*/ function(Promise1) {
|
|
148
|
+
"use strict";
|
|
149
|
+
_inherits(WatchablePromise, Promise1);
|
|
150
|
+
function WatchablePromise(executor) {
|
|
151
|
+
var _this = this;
|
|
152
|
+
_class_call_check(this, WatchablePromise);
|
|
153
|
+
var _this1;
|
|
154
|
+
var __super = function() {
|
|
155
|
+
for(var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++){
|
|
156
|
+
args[_key] = arguments[_key];
|
|
157
|
+
}
|
|
158
|
+
_this1 = _call_super(_this, WatchablePromise, _to_consumable_array(args));
|
|
159
|
+
__privateAdd(_this1, _settled, false);
|
|
160
|
+
__privateAdd(_this1, _status, "pending");
|
|
161
|
+
__privateAdd(_this1, _result);
|
|
162
|
+
return _this1;
|
|
163
|
+
};
|
|
164
|
+
__super(executor);
|
|
165
|
+
__super(function(resolve, reject) {
|
|
166
|
+
executor(function(value) {
|
|
167
|
+
resolve(value);
|
|
168
|
+
__privateSet(_assert_this_initialized(_this1), _status, "fulfilled");
|
|
169
|
+
__privateSet(_assert_this_initialized(_this1), _result, value);
|
|
170
|
+
}, function(reason) {
|
|
171
|
+
reject(reason);
|
|
172
|
+
__privateSet(_assert_this_initialized(_this1), _status, "rejected");
|
|
173
|
+
__privateSet(_assert_this_initialized(_this1), _result, reason);
|
|
174
|
+
});
|
|
175
|
+
});
|
|
176
|
+
return _assert_this_initialized(_this1);
|
|
177
|
+
}
|
|
178
|
+
_create_class(WatchablePromise, [
|
|
179
|
+
{
|
|
180
|
+
key: "settled",
|
|
181
|
+
get: function get() {
|
|
182
|
+
return __privateGet(this, _settled);
|
|
183
|
+
}
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
key: "status",
|
|
187
|
+
get: function get() {
|
|
188
|
+
return __privateGet(this, _status);
|
|
189
|
+
}
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
key: "result",
|
|
193
|
+
get: function get() {
|
|
194
|
+
return __privateGet(this, _result);
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
]);
|
|
198
|
+
return WatchablePromise;
|
|
199
|
+
}(_wrap_native_super(Promise));
|
|
200
|
+
_settled = new WeakMap();
|
|
201
|
+
_status = new WeakMap();
|
|
202
|
+
_result = new WeakMap();
|
|
203
|
+
export { WatchablePromise };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'use strict';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type WatchablePromiseStatus = 'pending' | 'fulfilled' | 'rejected';
|
|
File without changes
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
var WatchablePromise = require('./WatchablePromise');
|
|
3
|
+
Object.keys(WatchablePromise).forEach(function(k) {
|
|
4
|
+
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
5
|
+
enumerable: true,
|
|
6
|
+
get: function get() {
|
|
7
|
+
return WatchablePromise[k];
|
|
8
|
+
}
|
|
9
|
+
});
|
|
10
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './WatchablePromise.js';
|
package/dist/shared/index.cjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
var constants = require('./constants');
|
|
3
|
+
var features = require('./features');
|
|
3
4
|
var interfaces = require('./interfaces');
|
|
4
5
|
var managers = require('./managers');
|
|
5
6
|
var scripts = require('./scripts');
|
|
@@ -14,6 +15,14 @@ Object.keys(constants).forEach(function(k) {
|
|
|
14
15
|
}
|
|
15
16
|
});
|
|
16
17
|
});
|
|
18
|
+
Object.keys(features).forEach(function(k) {
|
|
19
|
+
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
20
|
+
enumerable: true,
|
|
21
|
+
get: function get() {
|
|
22
|
+
return features[k];
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
});
|
|
17
26
|
Object.keys(interfaces).forEach(function(k) {
|
|
18
27
|
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) Object.defineProperty(exports, k, {
|
|
19
28
|
enumerable: true,
|
package/dist/shared/index.d.ts
CHANGED
package/dist/shared/index.js
CHANGED
|
@@ -217,7 +217,7 @@ function _ts_generator(thisArg, body) {
|
|
|
217
217
|
};
|
|
218
218
|
}
|
|
219
219
|
}
|
|
220
|
-
var
|
|
220
|
+
var chunkJE77HYXB_cjs = require('../../chunk-JE77HYXB.cjs');
|
|
221
221
|
var jwtDecode = require('jwt-decode');
|
|
222
222
|
var moment = require('moment');
|
|
223
223
|
var EventEmitter = require('eventemitter3');
|
|
@@ -235,8 +235,8 @@ var _SessionManager = /*#__PURE__*/ function(_EventEmitter__default_default) {
|
|
|
235
235
|
var _this;
|
|
236
236
|
_this = _call_super(this, _SessionManager);
|
|
237
237
|
// Service parameters
|
|
238
|
-
|
|
239
|
-
|
|
238
|
+
chunkJE77HYXB_cjs.__publicField(_this, "api");
|
|
239
|
+
chunkJE77HYXB_cjs.__publicField(_this, "storageProvider");
|
|
240
240
|
_this.api = options.api;
|
|
241
241
|
_this.storageProvider = options.storageProvider;
|
|
242
242
|
console.log("SessionManager initialized", Date.now(), options.api);
|
|
@@ -493,6 +493,6 @@ var _SessionManager = /*#__PURE__*/ function(_EventEmitter__default_default) {
|
|
|
493
493
|
]);
|
|
494
494
|
return _SessionManager;
|
|
495
495
|
}(EventEmitter__default.default);
|
|
496
|
-
|
|
496
|
+
chunkJE77HYXB_cjs.__publicField(_SessionManager, "DEFAULT_AUTHORIZATION_STORAGE_KEY", "AUTHORIZATION");
|
|
497
497
|
var SessionManager = _SessionManager;
|
|
498
498
|
exports.SessionManager = SessionManager;
|
|
@@ -216,7 +216,7 @@ function _ts_generator(thisArg, body) {
|
|
|
216
216
|
};
|
|
217
217
|
}
|
|
218
218
|
}
|
|
219
|
-
import { __publicField } from '../../chunk-
|
|
219
|
+
import { __publicField } from '../../chunk-AQ5VUG5P.js';
|
|
220
220
|
import { jwtDecode } from 'jwt-decode';
|
|
221
221
|
import moment from 'moment';
|
|
222
222
|
import EventEmitter from 'eventemitter3';
|
|
@@ -192,7 +192,7 @@ function _ts_generator(thisArg, body) {
|
|
|
192
192
|
};
|
|
193
193
|
}
|
|
194
194
|
}
|
|
195
|
-
var
|
|
195
|
+
var chunkJE77HYXB_cjs = require('../../../chunk-JE77HYXB.cjs');
|
|
196
196
|
var EventEmitter = require('eventemitter3');
|
|
197
197
|
function _interopDefault(e) {
|
|
198
198
|
return e && e.__esModule ? e : {
|
|
@@ -208,13 +208,13 @@ var TimeService = /*#__PURE__*/ function(_EventEmitter__default_default) {
|
|
|
208
208
|
var _this;
|
|
209
209
|
_this = _call_super(this, TimeService);
|
|
210
210
|
// Internal
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
211
|
+
chunkJE77HYXB_cjs.__publicField(_this, "syncHandler");
|
|
212
|
+
chunkJE77HYXB_cjs.__publicField(_this, "offset");
|
|
213
|
+
chunkJE77HYXB_cjs.__publicField(_this, "syncedAt");
|
|
214
214
|
// Members
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
215
|
+
chunkJE77HYXB_cjs.__publicField(_this, "syncInterval");
|
|
216
|
+
chunkJE77HYXB_cjs.__publicField(_this, "clientTimeProvider");
|
|
217
|
+
chunkJE77HYXB_cjs.__publicField(_this, "serverTimeProvider");
|
|
218
218
|
_this.syncInterval = options === null || options === void 0 ? void 0 : options.syncInterval;
|
|
219
219
|
_this.clientTimeProvider = options === null || options === void 0 ? void 0 : options.clientTimeProvider;
|
|
220
220
|
_this.serverTimeProvider = options === null || options === void 0 ? void 0 : options.serverTimeProvider;
|
|
@@ -191,7 +191,7 @@ function _ts_generator(thisArg, body) {
|
|
|
191
191
|
};
|
|
192
192
|
}
|
|
193
193
|
}
|
|
194
|
-
import { __publicField } from '../../../chunk-
|
|
194
|
+
import { __publicField } from '../../../chunk-AQ5VUG5P.js';
|
|
195
195
|
import EventEmitter from 'eventemitter3';
|
|
196
196
|
var LOG_TAG = "TimeService";
|
|
197
197
|
var TimeService = /*#__PURE__*/ function(EventEmitter) {
|
|
@@ -43,7 +43,7 @@ function _unsupported_iterable_to_array(o, minLen) {
|
|
|
43
43
|
if (n === "Map" || n === "Set") return Array.from(n);
|
|
44
44
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
45
45
|
}
|
|
46
|
-
require('../../chunk-
|
|
46
|
+
require('../../chunk-JE77HYXB.cjs');
|
|
47
47
|
var global = require('./global');
|
|
48
48
|
var ArrayUtils = /*#__PURE__*/ function() {
|
|
49
49
|
function ArrayUtils() {
|
|
@@ -42,7 +42,7 @@ function _unsupported_iterable_to_array(o, minLen) {
|
|
|
42
42
|
if (n === "Map" || n === "Set") return Array.from(n);
|
|
43
43
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
44
44
|
}
|
|
45
|
-
import '../../chunk-
|
|
45
|
+
import '../../chunk-AQ5VUG5P.js';
|
|
46
46
|
import { castArray } from './global/index.js';
|
|
47
47
|
var ArrayUtils = /*#__PURE__*/ function() {
|
|
48
48
|
"use strict";
|
|
@@ -18,7 +18,7 @@ function _create_class(Constructor, protoProps, staticProps) {
|
|
|
18
18
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
19
19
|
return Constructor;
|
|
20
20
|
}
|
|
21
|
-
require('../../chunk-
|
|
21
|
+
require('../../chunk-JE77HYXB.cjs');
|
|
22
22
|
var AxiosUtils = /*#__PURE__*/ function() {
|
|
23
23
|
function AxiosUtils() {
|
|
24
24
|
_class_call_check(this, AxiosUtils);
|
|
@@ -17,7 +17,7 @@ function _create_class(Constructor, protoProps, staticProps) {
|
|
|
17
17
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
18
18
|
return Constructor;
|
|
19
19
|
}
|
|
20
|
-
import '../../chunk-
|
|
20
|
+
import '../../chunk-AQ5VUG5P.js';
|
|
21
21
|
var AxiosUtils = /*#__PURE__*/ function() {
|
|
22
22
|
"use strict";
|
|
23
23
|
function AxiosUtils() {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
'use strict';
|
|
2
|
-
require('../../chunk-
|
|
2
|
+
require('../../chunk-JE77HYXB.cjs');
|
|
3
3
|
function parseBoolean(value, defaultValue) {
|
|
4
4
|
if (value === void 0 || value === null) return defaultValue;
|
|
5
5
|
return value === "true" || value === true || value === 1 || value === "1";
|
|
@@ -18,7 +18,7 @@ function _create_class(Constructor, protoProps, staticProps) {
|
|
|
18
18
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
19
19
|
return Constructor;
|
|
20
20
|
}
|
|
21
|
-
require('../../chunk-
|
|
21
|
+
require('../../chunk-JE77HYXB.cjs');
|
|
22
22
|
var Calc = /*#__PURE__*/ function() {
|
|
23
23
|
function Calc() {
|
|
24
24
|
_class_call_check(this, Calc);
|
|
@@ -17,7 +17,7 @@ function _create_class(Constructor, protoProps, staticProps) {
|
|
|
17
17
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
18
18
|
return Constructor;
|
|
19
19
|
}
|
|
20
|
-
import '../../chunk-
|
|
20
|
+
import '../../chunk-AQ5VUG5P.js';
|
|
21
21
|
var Calc = /*#__PURE__*/ function() {
|
|
22
22
|
"use strict";
|
|
23
23
|
function Calc() {
|
|
@@ -18,7 +18,7 @@ function _create_class(Constructor, protoProps, staticProps) {
|
|
|
18
18
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
19
19
|
return Constructor;
|
|
20
20
|
}
|
|
21
|
-
require('../../chunk-
|
|
21
|
+
require('../../chunk-JE77HYXB.cjs');
|
|
22
22
|
var CoordinateUtils = /*#__PURE__*/ function() {
|
|
23
23
|
function CoordinateUtils() {
|
|
24
24
|
_class_call_check(this, CoordinateUtils);
|