@powfix/core-js 0.13.22 → 0.13.23
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/index.browser.d.ts +1 -0
- package/dist/index.browser.js +17 -0
- package/dist/index.d.ts +1 -4
- package/dist/index.js +1 -6
- package/dist/src/constants/index.d.ts +2 -2
- package/dist/src/constants/index.js +2 -2
- package/dist/src/index.browser.d.ts +7 -0
- package/dist/{browser.js → src/index.browser.js} +7 -6
- package/dist/src/index.d.ts +8 -0
- package/dist/src/index.js +24 -0
- package/dist/src/interfaces/backend/index.d.ts +1 -0
- package/dist/src/{utils/backend/base → interfaces/backend}/index.js +1 -1
- package/dist/src/interfaces/index.d.ts +2 -2
- package/dist/src/interfaces/index.js +2 -2
- package/dist/src/managers/TransactionManager.js +1 -1
- package/dist/src/managers/index.browser.d.ts +1 -0
- package/dist/src/managers/index.browser.js +2 -0
- package/dist/src/scripts/index.browser.d.ts +1 -0
- package/dist/src/scripts/index.browser.js +17 -0
- package/dist/src/scripts/index.d.ts +1 -1
- package/dist/src/scripts/index.js +1 -1
- package/dist/src/services/SessionService.d.ts +1 -1
- package/dist/src/services/{browser.js → index.browser.js} +0 -2
- package/dist/src/services/index.d.ts +1 -1
- package/dist/src/services/index.js +1 -2
- package/dist/src/services/time/TimeService.d.ts +1 -1
- package/dist/src/types/index.browser.d.ts +1 -0
- package/dist/src/types/index.browser.js +17 -0
- package/dist/src/types/index.d.ts +1 -1
- package/dist/src/types/index.js +1 -1
- package/dist/src/utils/BooleanUtils.js +1 -2
- package/dist/src/utils/UuidUtils.d.ts +0 -1
- package/dist/src/utils/backend/{base/SequelizeUtils.d.ts → SequelizeUtils.d.ts} +2 -2
- package/dist/src/utils/backend/{base/SequelizeUtils.js → SequelizeUtils.js} +1 -1
- package/dist/src/utils/backend/index.d.ts +1 -1
- package/dist/src/utils/backend/index.js +1 -1
- package/dist/src/utils/global/circularDistance.js +1 -2
- package/dist/src/utils/global/fallbackIfEqual.js +1 -2
- package/dist/src/utils/global/fallbackIfNull.js +1 -2
- package/dist/src/utils/global/fallbackIfUndefined.js +1 -2
- package/dist/src/utils/global/firstNonNullish.js +1 -2
- package/dist/src/utils/global/processFirstNonNullish.js +1 -2
- package/dist/src/utils/global/pureEnum.js +3 -4
- package/dist/src/utils/index.d.ts +1 -1
- package/dist/src/utils/index.js +1 -1
- package/package.json +6 -6
- package/dist/browser.d.ts +0 -6
- package/dist/src/utils/backend/base/index.d.ts +0 -1
- /package/dist/src/constants/{transactionManager → backend}/TransactionManagerLogLevel.d.ts +0 -0
- /package/dist/src/constants/{transactionManager → backend}/TransactionManagerLogLevel.js +0 -0
- /package/dist/src/constants/{transactionManager → backend}/TransactionManagerTimeoutAction.d.ts +0 -0
- /package/dist/src/constants/{transactionManager → backend}/TransactionManagerTimeoutAction.js +0 -0
- /package/dist/src/constants/{transactionManager → backend}/index.d.ts +0 -0
- /package/dist/src/constants/{transactionManager → backend}/index.js +0 -0
- /package/dist/src/constants/{browser.d.ts → index.browser.d.ts} +0 -0
- /package/dist/src/constants/{browser.js → index.browser.js} +0 -0
- /package/dist/src/interfaces/{db → backend/db}/index.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/index.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/Hook.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/Hook.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/HookFn.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/HookFn.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/HookType.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/HookType.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/ReloadOption.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/ReloadOption.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/TransactionOption.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/TransactionOption.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/UpsertOptions.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/UpsertOptions.js +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/index.d.ts +0 -0
- /package/dist/src/interfaces/{db → backend/db}/sequelize/index.js +0 -0
- /package/dist/src/interfaces/{browser.d.ts → index.browser.d.ts} +0 -0
- /package/dist/src/interfaces/{browser.js → index.browser.js} +0 -0
- /package/dist/src/scripts/{base64-polyfill.d.ts → base64Polyfill.d.ts} +0 -0
- /package/dist/src/scripts/{base64-polyfill.js → base64Polyfill.js} +0 -0
- /package/dist/src/services/{browser.d.ts → index.browser.d.ts} +0 -0
- /package/dist/src/utils/{browser.d.ts → index.browser.d.ts} +0 -0
- /package/dist/src/utils/{browser.js → index.browser.js} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './src/index.browser';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./src/index.browser"), exports);
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -14,9 +14,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
|
|
18
|
-
__exportStar(require("./browser"), exports);
|
|
19
|
-
__exportStar(require("./src/constants"), exports);
|
|
20
|
-
__exportStar(require("./src/managers"), exports);
|
|
21
|
-
// services
|
|
22
|
-
__exportStar(require("./src/services"), exports);
|
|
17
|
+
__exportStar(require("./src/index"), exports);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './
|
|
2
|
-
export * from './
|
|
1
|
+
export * from './index.browser';
|
|
2
|
+
export * from './backend';
|
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
18
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
18
|
+
__exportStar(require("./backend"), exports);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './constants/index.browser';
|
|
2
|
+
export * from './interfaces/index.browser';
|
|
3
|
+
export * from './managers/index.browser';
|
|
4
|
+
export * from './scripts/index.browser';
|
|
5
|
+
export * from './services/index.browser';
|
|
6
|
+
export * from './types/index.browser';
|
|
7
|
+
export * from './utils/index.browser';
|
|
@@ -14,9 +14,10 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
18
|
-
__exportStar(require("./
|
|
19
|
-
__exportStar(require("./
|
|
20
|
-
__exportStar(require("./
|
|
21
|
-
__exportStar(require("./
|
|
22
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./constants/index.browser"), exports);
|
|
18
|
+
__exportStar(require("./interfaces/index.browser"), exports);
|
|
19
|
+
__exportStar(require("./managers/index.browser"), exports);
|
|
20
|
+
__exportStar(require("./scripts/index.browser"), exports);
|
|
21
|
+
__exportStar(require("./services/index.browser"), exports);
|
|
22
|
+
__exportStar(require("./types/index.browser"), exports);
|
|
23
|
+
__exportStar(require("./utils/index.browser"), exports);
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
18
|
+
__exportStar(require("./constants"), exports);
|
|
19
|
+
__exportStar(require("./interfaces"), exports);
|
|
20
|
+
__exportStar(require("./managers"), exports);
|
|
21
|
+
__exportStar(require("./scripts"), exports);
|
|
22
|
+
__exportStar(require("./services"), exports);
|
|
23
|
+
__exportStar(require("./types"), exports);
|
|
24
|
+
__exportStar(require("./utils"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './db';
|
|
@@ -14,4 +14,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./db"), exports);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './browser';
|
|
2
|
-
export * from './
|
|
1
|
+
export * from './index.browser';
|
|
2
|
+
export * from './backend';
|
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./browser"), exports);
|
|
18
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
18
|
+
__exportStar(require("./backend"), exports);
|
|
@@ -75,7 +75,7 @@ class TransactionManager {
|
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
77
|
flush(action) {
|
|
78
|
-
return Promise.allSettled(Array.from(this.transactionTimeoutMap.entries()).map((
|
|
78
|
+
return Promise.allSettled(Array.from(this.transactionTimeoutMap.entries()).map((_a) => __awaiter(this, [_a], void 0, function* ([transaction, transactionTimeout]) {
|
|
79
79
|
const handled = yield this.execute(transaction, action !== null && action !== void 0 ? action : transactionTimeout.action, 'flush');
|
|
80
80
|
this.remove(transaction);
|
|
81
81
|
return {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './base64Polyfill';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./base64Polyfill"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './
|
|
1
|
+
export * from './index.browser';
|
|
@@ -14,4 +14,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
@@ -7,7 +7,7 @@ export declare class SessionService {
|
|
|
7
7
|
protected storageProvider: StorageProvider;
|
|
8
8
|
private emitter;
|
|
9
9
|
readonly on: <T extends "AUTHORIZATION_CHANGED">(event: T, fn: (...args: EventEmitter3.ArgumentMap<SessionService.Event>[Extract<T, "AUTHORIZATION_CHANGED">]) => void, context?: any) => EventEmitter3<SessionService.Event, any>;
|
|
10
|
-
readonly off: <T extends "AUTHORIZATION_CHANGED">(event: T, fn?: ((...args: EventEmitter3.ArgumentMap<SessionService.Event>[Extract<T, "AUTHORIZATION_CHANGED">]) => void) | undefined, context?: any, once?: boolean
|
|
10
|
+
readonly off: <T extends "AUTHORIZATION_CHANGED">(event: T, fn?: ((...args: EventEmitter3.ArgumentMap<SessionService.Event>[Extract<T, "AUTHORIZATION_CHANGED">]) => void) | undefined, context?: any, once?: boolean) => EventEmitter3<SessionService.Event, any>;
|
|
11
11
|
protected readonly emit: <T extends "AUTHORIZATION_CHANGED">(event: T, ...args: EventEmitter3.ArgumentMap<SessionService.Event>[Extract<T, "AUTHORIZATION_CHANGED">]) => boolean;
|
|
12
12
|
constructor(options: SessionService.Options);
|
|
13
13
|
private get key();
|
|
@@ -14,7 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
// Directories
|
|
18
17
|
__exportStar(require("./time"), exports);
|
|
19
|
-
// Files
|
|
20
18
|
__exportStar(require("./SessionService"), exports);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './browser';
|
|
1
|
+
export * from './index.browser';
|
|
2
2
|
export * from './redis';
|
|
@@ -14,6 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./browser"), exports);
|
|
18
|
-
// Directories
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
19
18
|
__exportStar(require("./redis"), exports);
|
|
@@ -11,7 +11,7 @@ export declare class TimeService {
|
|
|
11
11
|
private syncedAt?;
|
|
12
12
|
private emitter;
|
|
13
13
|
readonly on: <T extends TimeService.Event>(event: T, fn: (...args: any[]) => void, context?: any) => EventEmitter3<TimeService.Event, any>;
|
|
14
|
-
readonly off: <T extends TimeService.Event>(event: T, fn?: ((...args: any[]) => void) | undefined, context?: any, once?: boolean
|
|
14
|
+
readonly off: <T extends TimeService.Event>(event: T, fn?: ((...args: any[]) => void) | undefined, context?: any, once?: boolean) => EventEmitter3<TimeService.Event, any>;
|
|
15
15
|
private readonly emit;
|
|
16
16
|
static calculateNTPResultOffset(ntpResult: TimeService.NTPResult): TimeService.Offset;
|
|
17
17
|
constructor(option: TimeService.Option);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './IntRage';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./IntRage"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './
|
|
1
|
+
export * from './index.browser';
|
package/dist/src/types/index.js
CHANGED
|
@@ -14,4 +14,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.parseBoolean =
|
|
3
|
+
exports.parseBoolean = parseBoolean;
|
|
4
4
|
function parseBoolean(value, defaultValue) {
|
|
5
5
|
if (value === undefined || value === null)
|
|
6
6
|
return defaultValue;
|
|
7
7
|
return (value === 'true' || value === true) || (value === 1 || value === '1');
|
|
8
8
|
}
|
|
9
|
-
exports.parseBoolean = parseBoolean;
|
|
@@ -28,8 +28,8 @@ export type UuidKeys<Model> = ExtractUuidKeys<Model>;
|
|
|
28
28
|
export declare class SequelizeUtils {
|
|
29
29
|
static decimal2Number(value: any): number | null | undefined;
|
|
30
30
|
static getPrimaryUuidColumn: () => Partial<ModelAttributeColumnOptions>;
|
|
31
|
-
static getForeignUuidColumn: <Model = never, AdditionalKeys extends Exclude<ExtractAdditionalKeys<Model>,
|
|
32
|
-
columnName: Model extends undefined ? string :
|
|
31
|
+
static getForeignUuidColumn: <Model = never, AdditionalKeys extends Exclude<ExtractAdditionalKeys<Model>, UuidKeys<Model>> = never>({ columnName, allowNull }: {
|
|
32
|
+
columnName: Model extends undefined ? string : (UuidKeys<Model> | AdditionalKeys);
|
|
33
33
|
allowNull: boolean;
|
|
34
34
|
}) => Partial<ModelAttributeColumnOptions>;
|
|
35
35
|
static getUuidColumn: ({ columnName, ...overrideOptions }: UuidColumnOptions) => Partial<ModelAttributeColumnOptions>;
|
|
@@ -12,7 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
12
12
|
};
|
|
13
13
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
14
|
exports.SequelizeUtils = void 0;
|
|
15
|
-
const UuidUtils_1 = require("
|
|
15
|
+
const UuidUtils_1 = require("../UuidUtils");
|
|
16
16
|
class SequelizeUtils {
|
|
17
17
|
static decimal2Number(value) {
|
|
18
18
|
if (value === null || value === undefined) {
|
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./base"), exports);
|
|
18
17
|
__exportStar(require("./HookUtils"), exports);
|
|
18
|
+
__exportStar(require("./SequelizeUtils"), exports);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.circularDistance =
|
|
3
|
+
exports.circularDistance = circularDistance;
|
|
4
4
|
function circularDistance(value, target, min, max) {
|
|
5
5
|
const range = max - min;
|
|
6
6
|
const from = value - min;
|
|
@@ -12,4 +12,3 @@ function circularDistance(value, target, min, max) {
|
|
|
12
12
|
return range - from + to;
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
|
-
exports.circularDistance = circularDistance;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.fallbackIfEqual =
|
|
3
|
+
exports.fallbackIfEqual = fallbackIfEqual;
|
|
4
4
|
function fallbackIfEqual(value, condition, fallback) {
|
|
5
5
|
if (typeof value === typeof condition && value === condition) {
|
|
6
6
|
return fallback;
|
|
7
7
|
}
|
|
8
8
|
return value;
|
|
9
9
|
}
|
|
10
|
-
exports.fallbackIfEqual = fallbackIfEqual;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.fallbackIfNull =
|
|
3
|
+
exports.fallbackIfNull = fallbackIfNull;
|
|
4
4
|
const fallbackIfEqual_1 = require("./fallbackIfEqual");
|
|
5
5
|
function fallbackIfNull(value, fallback) {
|
|
6
6
|
return (0, fallbackIfEqual_1.fallbackIfEqual)(value, null, fallback);
|
|
7
7
|
}
|
|
8
|
-
exports.fallbackIfNull = fallbackIfNull;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.fallbackIfUndefined =
|
|
3
|
+
exports.fallbackIfUndefined = fallbackIfUndefined;
|
|
4
4
|
const fallbackIfEqual_1 = require("./fallbackIfEqual");
|
|
5
5
|
function fallbackIfUndefined(value, fallback) {
|
|
6
6
|
return (0, fallbackIfEqual_1.fallbackIfEqual)(value, undefined, fallback);
|
|
7
7
|
}
|
|
8
|
-
exports.fallbackIfUndefined = fallbackIfUndefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.firstNonNullish =
|
|
3
|
+
exports.firstNonNullish = firstNonNullish;
|
|
4
4
|
function firstNonNullish(...args) {
|
|
5
5
|
if (args == null || !Array.isArray(args) || args.length === 0) {
|
|
6
6
|
return undefined;
|
|
@@ -11,4 +11,3 @@ function firstNonNullish(...args) {
|
|
|
11
11
|
}
|
|
12
12
|
return firstNonNullish(...args.slice(1));
|
|
13
13
|
}
|
|
14
|
-
exports.firstNonNullish = firstNonNullish;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.processFirstNonNullish =
|
|
3
|
+
exports.processFirstNonNullish = processFirstNonNullish;
|
|
4
4
|
const firstNonNullish_1 = require("./firstNonNullish");
|
|
5
5
|
function processFirstNonNullish(processor, ...args) {
|
|
6
6
|
const fallback = (0, firstNonNullish_1.firstNonNullish)(...args);
|
|
@@ -9,4 +9,3 @@ function processFirstNonNullish(processor, ...args) {
|
|
|
9
9
|
}
|
|
10
10
|
return processor(fallback);
|
|
11
11
|
}
|
|
12
|
-
exports.processFirstNonNullish = processFirstNonNullish;
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.pureEnum = pureEnum;
|
|
4
|
+
exports.pureEnumKeys = pureEnumKeys;
|
|
5
|
+
exports.pureEnumValues = pureEnumValues;
|
|
4
6
|
function pureEnum(e) {
|
|
5
7
|
return Object.entries(e).filter(([key, value]) => !/^\d+$/g.test(key) && typeof value !== 'function');
|
|
6
8
|
}
|
|
7
|
-
exports.pureEnum = pureEnum;
|
|
8
9
|
function pureEnumKeys(e) {
|
|
9
10
|
return pureEnum(e).map(([key]) => key);
|
|
10
11
|
}
|
|
11
|
-
exports.pureEnumKeys = pureEnumKeys;
|
|
12
12
|
function pureEnumValues(e) {
|
|
13
13
|
return pureEnum(e).map(([, value]) => value);
|
|
14
14
|
}
|
|
15
|
-
exports.pureEnumValues = pureEnumValues;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './browser';
|
|
1
|
+
export * from './index.browser';
|
|
2
2
|
export * from './backend';
|
package/dist/src/utils/index.js
CHANGED
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./browser"), exports);
|
|
17
|
+
__exportStar(require("./index.browser"), exports);
|
|
18
18
|
__exportStar(require("./backend"), exports);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@powfix/core-js",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.23",
|
|
4
4
|
"description": "core package",
|
|
5
5
|
"author": "Kwon Kyung-Min <powfix@gmail.com>",
|
|
6
6
|
"private": false,
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"homepage": "https://github.com/powfix/core-js",
|
|
17
17
|
"license": "MIT",
|
|
18
18
|
"main": "dist/index.js",
|
|
19
|
-
"browser": "dist/browser.js",
|
|
19
|
+
"browser": "dist/index.browser.js",
|
|
20
20
|
"scripts": {
|
|
21
21
|
"clean": "rm -rf dist",
|
|
22
22
|
"build": "yarn clean; tsc -p ."
|
|
@@ -28,19 +28,19 @@
|
|
|
28
28
|
"base-64": "^1.0.0",
|
|
29
29
|
"eventemitter3": "^5.0.1",
|
|
30
30
|
"jwt-decode": "^4.0.0",
|
|
31
|
-
"redis": "
|
|
31
|
+
"redis": "4.7.0",
|
|
32
32
|
"uuid": "9.0.1"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@types/base-64": "1.0.2",
|
|
36
36
|
"@types/node": "20.9.5",
|
|
37
37
|
"@types/uuid": "9.0.7",
|
|
38
|
-
"axios": "1.
|
|
38
|
+
"axios": "^1.8.4",
|
|
39
39
|
"moment": "^2.30.1",
|
|
40
|
-
"sequelize": "
|
|
40
|
+
"sequelize": "6.37.7",
|
|
41
41
|
"sequelize-typescript": "^2.1.6",
|
|
42
42
|
"ts-node": "^10.9.2",
|
|
43
|
-
"typescript": "5.
|
|
43
|
+
"typescript": "5.8.3"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
46
46
|
"axios": ">=1.7.0",
|
package/dist/browser.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './SequelizeUtils';
|
|
File without changes
|
|
File without changes
|
/package/dist/src/constants/{transactionManager → backend}/TransactionManagerTimeoutAction.d.ts
RENAMED
|
File without changes
|
/package/dist/src/constants/{transactionManager → backend}/TransactionManagerTimeoutAction.js
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|