@mxpicture/gcp-functions-common 1.1.91 → 1.2.2
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/annotation/anno.head.d.ts +3 -3
- package/dist/annotation/anno.head.d.ts.map +1 -1
- package/dist/annotation/anno.head.js +0 -1
- package/dist/annotation/anno.head.js.map +1 -1
- package/dist/annotation/anno.property.d.ts +2 -2
- package/dist/annotation/anno.property.d.ts.map +1 -1
- package/dist/decorator/DecoArray.d.ts +1 -1
- package/dist/decorator/DecoArray.d.ts.map +1 -1
- package/dist/decorator/DecoBoolean.d.ts +1 -1
- package/dist/decorator/DecoBoolean.d.ts.map +1 -1
- package/dist/decorator/DecoDate.d.ts +3 -2
- package/dist/decorator/DecoDate.d.ts.map +1 -1
- package/dist/decorator/DecoDate.js.map +1 -1
- package/dist/decorator/DecoEnum.d.ts +2 -2
- package/dist/decorator/DecoEnum.d.ts.map +1 -1
- package/dist/decorator/DecoNumber.d.ts +1 -1
- package/dist/decorator/DecoNumber.d.ts.map +1 -1
- package/dist/decorator/DecoObject.d.ts +2 -2
- package/dist/decorator/DecoObject.d.ts.map +1 -1
- package/dist/decorator/DecoProperty.d.ts +14 -2
- package/dist/decorator/DecoProperty.d.ts.map +1 -1
- package/dist/decorator/DecoProperty.js +12 -0
- package/dist/decorator/DecoProperty.js.map +1 -1
- package/dist/decorator/DecoString.d.ts +1 -1
- package/dist/decorator/DecoString.d.ts.map +1 -1
- package/dist/decorator/Decorator.d.ts +4 -13
- package/dist/decorator/Decorator.d.ts.map +1 -1
- package/dist/decorator/Decorator.js +3 -15
- package/dist/decorator/Decorator.js.map +1 -1
- package/dist/decorator/deco.browser.d.ts +10 -0
- package/dist/decorator/deco.browser.d.ts.map +1 -0
- package/dist/decorator/deco.browser.js +22 -0
- package/dist/decorator/deco.browser.js.map +1 -0
- package/dist/decorator/deco.cast.d.ts +1 -1
- package/dist/decorator/deco.cast.d.ts.map +1 -1
- package/dist/decorator/deco.enum.d.ts +15 -4
- package/dist/decorator/deco.enum.d.ts.map +1 -1
- package/dist/decorator/deco.enum.js +38 -11
- package/dist/decorator/deco.enum.js.map +1 -1
- package/dist/decorator/deco.names.d.ts +2 -2
- package/dist/decorator/deco.names.d.ts.map +1 -1
- package/dist/decorator/deco.names.js +1 -1
- package/dist/decorator/deco.names.js.map +1 -1
- package/dist/decorator/deco.paths.js +1 -1
- package/dist/decorator/deco.paths.js.map +1 -1
- package/dist/decorator/deco.routes.d.ts +2 -2
- package/dist/decorator/deco.routes.d.ts.map +1 -1
- package/dist/decorator/index.d.ts +1 -0
- package/dist/decorator/index.d.ts.map +1 -1
- package/dist/decorator/index.js +1 -0
- package/dist/decorator/index.js.map +1 -1
- package/dist/helper/EnumRegistry.d.ts +36 -2
- package/dist/helper/EnumRegistry.d.ts.map +1 -1
- package/dist/helper/EnumRegistry.js +34 -0
- package/dist/helper/EnumRegistry.js.map +1 -1
- package/dist/helper/FirebaseTimestamp.d.ts +1 -1
- package/dist/helper/FirebaseTimestamp.d.ts.map +1 -1
- package/dist/helper/helper.annotation.d.ts +3 -3
- package/dist/helper/helper.annotation.d.ts.map +1 -1
- package/dist/helper/helper.date.d.ts +42 -0
- package/dist/helper/helper.date.d.ts.map +1 -1
- package/dist/helper/helper.date.js +42 -0
- package/dist/helper/helper.date.js.map +1 -1
- package/dist/helper/helper.document.d.ts +1 -1
- package/dist/helper/helper.document.d.ts.map +1 -1
- package/dist/helper/helper.timestamp.d.ts.map +1 -1
- package/dist/helper/helper.timestamp.js +1 -1
- package/dist/helper/helper.timestamp.js.map +1 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +1 -0
- package/dist/types/index.js.map +1 -1
- package/dist/types/types.annotation.d.ts +2 -4
- package/dist/types/types.annotation.d.ts.map +1 -1
- package/dist/types/types.deco.common.d.ts +0 -3
- package/dist/types/types.deco.common.d.ts.map +1 -1
- package/dist/types/types.filter.d.ts +1 -1
- package/dist/types/types.filter.d.ts.map +1 -1
- package/dist/types/types.function.d.ts +1 -1
- package/dist/types/types.function.d.ts.map +1 -1
- package/dist/types/types.generator.d.ts +17 -0
- package/dist/types/types.generator.d.ts.map +1 -0
- package/dist/types/types.generator.js +2 -0
- package/dist/types/types.generator.js.map +1 -0
- package/dist/types/types.routes.d.ts +1 -1
- package/dist/types/types.routes.d.ts.map +1 -1
- package/package.json +4 -3
- package/dist/path/index.d.ts +0 -2
- package/dist/path/index.d.ts.map +0 -1
- package/dist/path/index.js +0 -3
- package/dist/path/index.js.map +0 -1
- package/dist/path/path.common.d.ts +0 -72
- package/dist/path/path.common.d.ts.map +0 -1
- package/dist/path/path.common.js +0 -85
- package/dist/path/path.common.js.map +0 -1
package/dist/path/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/path/index.ts"],"names":[],"mappings":"AACA,cAAc,kBAAkB,CAAC"}
|
package/dist/path/index.js
DELETED
package/dist/path/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/path/index.ts"],"names":[],"mappings":"AAAA,kEAAkE;AAClE,cAAc,kBAAkB,CAAC"}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Enumerates the high-level base directory categories within the repository.
|
|
3
|
-
*/
|
|
4
|
-
export declare enum BasePathType {
|
|
5
|
-
/** The `packages` directory that holds all workspace packages. */
|
|
6
|
-
packages = "packages",
|
|
7
|
-
/** The repository root directory. */
|
|
8
|
-
root = "root"
|
|
9
|
-
}
|
|
10
|
-
/**
|
|
11
|
-
* Enumerates the workspace package names within the `packages` directory.
|
|
12
|
-
*/
|
|
13
|
-
export declare enum WsPathType {
|
|
14
|
-
backend = "backend",
|
|
15
|
-
common = "common",
|
|
16
|
-
frontend = "frontend",
|
|
17
|
-
fs = "fs",
|
|
18
|
-
generator = "generator"
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Maps each {@link BasePathType} to its resolved absolute file-system path.
|
|
22
|
-
*/
|
|
23
|
-
export type BasePath = Record<BasePathType, string>;
|
|
24
|
-
/**
|
|
25
|
-
* Pre-resolved absolute paths for the base directory categories.
|
|
26
|
-
*/
|
|
27
|
-
export declare const basePaths: BasePath;
|
|
28
|
-
/**
|
|
29
|
-
* Maps each {@link WsPathType} to its resolved absolute file-system path.
|
|
30
|
-
*/
|
|
31
|
-
export type WsPath = Record<WsPathType, string>;
|
|
32
|
-
/**
|
|
33
|
-
* Pre-resolved absolute paths for every workspace package directory.
|
|
34
|
-
*/
|
|
35
|
-
export declare const wsPaths: WsPath;
|
|
36
|
-
/**
|
|
37
|
-
* Extended path information for a specific workspace, including the
|
|
38
|
-
* package directory name, workspace name, and `package.json` location.
|
|
39
|
-
*/
|
|
40
|
-
export interface CurrentPaths extends BasePath {
|
|
41
|
-
/** Name of the top-level directory (expected to be `"packages"`). */
|
|
42
|
-
pkgDirName: string;
|
|
43
|
-
/** The workspace name (one of the {@link WsPathType} values). */
|
|
44
|
-
wsName: string;
|
|
45
|
-
/** Absolute path to the workspace's `package.json`. */
|
|
46
|
-
packageJsonPath: string;
|
|
47
|
-
}
|
|
48
|
-
/**
|
|
49
|
-
* Absolute path to the repository-level `changelog.json` file.
|
|
50
|
-
*/
|
|
51
|
-
export declare const changelogPath: string;
|
|
52
|
-
/**
|
|
53
|
-
* Returns the absolute path to the `package.json` of the given workspace.
|
|
54
|
-
*
|
|
55
|
-
* @param type - The workspace whose `package.json` path is requested.
|
|
56
|
-
* @returns The resolved absolute path.
|
|
57
|
-
*/
|
|
58
|
-
export declare const packageJsonPath: (type: WsPathType) => string;
|
|
59
|
-
/**
|
|
60
|
-
* Derives {@link CurrentPaths} for the workspace that contains the given file path.
|
|
61
|
-
*
|
|
62
|
-
* @remarks
|
|
63
|
-
* Accepts both absolute and relative paths. The path must reside within one of
|
|
64
|
-
* the known workspace directories under `packages/`. Throws if the path does
|
|
65
|
-
* not match the expected layout.
|
|
66
|
-
*
|
|
67
|
-
* @param currentPath - A file-system path within a workspace.
|
|
68
|
-
* @returns Resolved path information for the containing workspace.
|
|
69
|
-
* @throws If the path does not start with `packages/` or names an unknown workspace.
|
|
70
|
-
*/
|
|
71
|
-
export declare const createCurrentWsPaths: (currentPath: string) => CurrentPaths;
|
|
72
|
-
//# sourceMappingURL=path.common.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"path.common.d.ts","sourceRoot":"","sources":["../../src/path/path.common.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,oBAAY,YAAY;IACtB,kEAAkE;IAClE,QAAQ,aAAa;IACrB,qCAAqC;IACrC,IAAI,SAAS;CACd;AAED;;GAEG;AACH,oBAAY,UAAU;IACpB,OAAO,YAAY;IACnB,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,EAAE,OAAO;IACT,SAAS,cAAc;CACxB;AAED;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,YAAY,EAAE,MAAM,CAAC,CAAC;AAEpD;;GAEG;AACH,eAAO,MAAM,SAAS,EAAE,QAGvB,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,MAAM,GAAG,MAAM,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC;AAEhD;;GAEG;AACH,eAAO,MAAM,OAAO,EAAE,MAMrB,CAAC;AAEF;;;GAGG;AACH,MAAM,WAAW,YAAa,SAAQ,QAAQ;IAC5C,qEAAqE;IACrE,UAAU,EAAE,MAAM,CAAC;IACnB,iEAAiE;IACjE,MAAM,EAAE,MAAM,CAAC;IACf,uDAAuD;IACvD,eAAe,EAAE,MAAM,CAAC;CACzB;AAED;;GAEG;AACH,eAAO,MAAM,aAAa,QAAyC,CAAC;AAEpE;;;;;GAKG;AACH,eAAO,MAAM,eAAe,GAAI,MAAM,UAAU,WACX,CAAC;AAEtC;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,oBAAoB,GAAI,aAAa,MAAM,KAAG,YAyB1D,CAAC"}
|
package/dist/path/path.common.js
DELETED
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import { isAbsolute, join, relative, resolve, sep } from "path";
|
|
2
|
-
const packagesDir = resolve(import.meta.dirname, "../../..");
|
|
3
|
-
/**
|
|
4
|
-
* Enumerates the high-level base directory categories within the repository.
|
|
5
|
-
*/
|
|
6
|
-
export var BasePathType;
|
|
7
|
-
(function (BasePathType) {
|
|
8
|
-
/** The `packages` directory that holds all workspace packages. */
|
|
9
|
-
BasePathType["packages"] = "packages";
|
|
10
|
-
/** The repository root directory. */
|
|
11
|
-
BasePathType["root"] = "root";
|
|
12
|
-
})(BasePathType || (BasePathType = {}));
|
|
13
|
-
/**
|
|
14
|
-
* Enumerates the workspace package names within the `packages` directory.
|
|
15
|
-
*/
|
|
16
|
-
export var WsPathType;
|
|
17
|
-
(function (WsPathType) {
|
|
18
|
-
WsPathType["backend"] = "backend";
|
|
19
|
-
WsPathType["common"] = "common";
|
|
20
|
-
WsPathType["frontend"] = "frontend";
|
|
21
|
-
WsPathType["fs"] = "fs";
|
|
22
|
-
WsPathType["generator"] = "generator";
|
|
23
|
-
})(WsPathType || (WsPathType = {}));
|
|
24
|
-
/**
|
|
25
|
-
* Pre-resolved absolute paths for the base directory categories.
|
|
26
|
-
*/
|
|
27
|
-
export const basePaths = {
|
|
28
|
-
[BasePathType.packages]: packagesDir,
|
|
29
|
-
[BasePathType.root]: resolve(packagesDir, ".."),
|
|
30
|
-
};
|
|
31
|
-
/**
|
|
32
|
-
* Pre-resolved absolute paths for every workspace package directory.
|
|
33
|
-
*/
|
|
34
|
-
export const wsPaths = {
|
|
35
|
-
[WsPathType.backend]: join(packagesDir, WsPathType.backend),
|
|
36
|
-
[WsPathType.common]: join(packagesDir, WsPathType.common),
|
|
37
|
-
[WsPathType.frontend]: join(packagesDir, WsPathType.frontend),
|
|
38
|
-
[WsPathType.fs]: join(packagesDir, WsPathType.fs),
|
|
39
|
-
[WsPathType.generator]: join(packagesDir, WsPathType.generator),
|
|
40
|
-
};
|
|
41
|
-
/**
|
|
42
|
-
* Absolute path to the repository-level `changelog.json` file.
|
|
43
|
-
*/
|
|
44
|
-
export const changelogPath = join(basePaths.root, "changelog.json");
|
|
45
|
-
/**
|
|
46
|
-
* Returns the absolute path to the `package.json` of the given workspace.
|
|
47
|
-
*
|
|
48
|
-
* @param type - The workspace whose `package.json` path is requested.
|
|
49
|
-
* @returns The resolved absolute path.
|
|
50
|
-
*/
|
|
51
|
-
export const packageJsonPath = (type) => join(wsPaths[type], "package.json");
|
|
52
|
-
/**
|
|
53
|
-
* Derives {@link CurrentPaths} for the workspace that contains the given file path.
|
|
54
|
-
*
|
|
55
|
-
* @remarks
|
|
56
|
-
* Accepts both absolute and relative paths. The path must reside within one of
|
|
57
|
-
* the known workspace directories under `packages/`. Throws if the path does
|
|
58
|
-
* not match the expected layout.
|
|
59
|
-
*
|
|
60
|
-
* @param currentPath - A file-system path within a workspace.
|
|
61
|
-
* @returns Resolved path information for the containing workspace.
|
|
62
|
-
* @throws If the path does not start with `packages/` or names an unknown workspace.
|
|
63
|
-
*/
|
|
64
|
-
export const createCurrentWsPaths = (currentPath) => {
|
|
65
|
-
const res = isAbsolute(currentPath)
|
|
66
|
-
? relative(basePaths.root, changelogPath)
|
|
67
|
-
: currentPath;
|
|
68
|
-
const parts = res.split(sep);
|
|
69
|
-
const pkgDirName = parts.shift();
|
|
70
|
-
if (pkgDirName !== "packages")
|
|
71
|
-
throw new Error(`Unsuppoted location. expected: packages/*, got: ${res}`);
|
|
72
|
-
const _wsName = parts.shift();
|
|
73
|
-
if (!_wsName)
|
|
74
|
-
throw new Error(`Unsuppoted workpace. expected: packages/*, got: ${res}`);
|
|
75
|
-
const wsName = _wsName;
|
|
76
|
-
if (!Object.values(WsPathType).includes(wsName))
|
|
77
|
-
throw new Error(`Unsuppoted workpace: ${res}`);
|
|
78
|
-
return {
|
|
79
|
-
...basePaths,
|
|
80
|
-
pkgDirName,
|
|
81
|
-
wsName,
|
|
82
|
-
packageJsonPath: packageJsonPath(wsName),
|
|
83
|
-
};
|
|
84
|
-
};
|
|
85
|
-
//# sourceMappingURL=path.common.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"path.common.js","sourceRoot":"","sources":["../../src/path/path.common.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,MAAM,CAAC;AAEhE,MAAM,WAAW,GAAG,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC,CAAC;AAE7D;;GAEG;AACH,MAAM,CAAN,IAAY,YAKX;AALD,WAAY,YAAY;IACtB,kEAAkE;IAClE,qCAAqB,CAAA;IACrB,qCAAqC;IACrC,6BAAa,CAAA;AACf,CAAC,EALW,YAAY,KAAZ,YAAY,QAKvB;AAED;;GAEG;AACH,MAAM,CAAN,IAAY,UAMX;AAND,WAAY,UAAU;IACpB,iCAAmB,CAAA;IACnB,+BAAiB,CAAA;IACjB,mCAAqB,CAAA;IACrB,uBAAS,CAAA;IACT,qCAAuB,CAAA;AACzB,CAAC,EANW,UAAU,KAAV,UAAU,QAMrB;AAOD;;GAEG;AACH,MAAM,CAAC,MAAM,SAAS,GAAa;IACjC,CAAC,YAAY,CAAC,QAAQ,CAAC,EAAE,WAAW;IACpC,CAAC,YAAY,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC;CAChD,CAAC;AAOF;;GAEG;AACH,MAAM,CAAC,MAAM,OAAO,GAAW;IAC7B,CAAC,UAAU,CAAC,OAAO,CAAC,EAAE,IAAI,CAAC,WAAW,EAAE,UAAU,CAAC,OAAO,CAAC;IAC3D,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE,IAAI,CAAC,WAAW,EAAE,UAAU,CAA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