@rxap/ts-morph 1.1.0-dev.1 → 1.1.0-dev.10
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/CHANGELOG.md +67 -0
- package/README.md +1 -1
- package/package.json +4 -4
- package/src/index.d.ts +1 -0
- package/src/index.js +1 -0
- package/src/index.js.map +1 -1
- package/src/lib/angular/coerce-component-import.js +2 -1
- package/src/lib/angular/coerce-component-import.js.map +1 -1
- package/src/lib/coerce-decorator.js +5 -0
- package/src/lib/coerce-decorator.js.map +1 -1
- package/src/lib/data-property.d.ts +7 -4
- package/src/lib/data-property.js +25 -6
- package/src/lib/data-property.js.map +1 -1
- package/src/lib/find-function.js +1 -1
- package/src/lib/find-function.js.map +1 -1
- package/src/lib/nest/coerce-nest-operation.d.ts +6 -5
- package/src/lib/nest/coerce-nest-operation.js +30 -26
- package/src/lib/nest/coerce-nest-operation.js.map +1 -1
- package/src/lib/nest/operation-id-utilities.d.ts +4 -4
- package/src/lib/nest/operation-id-utilities.js +11 -11
- package/src/lib/nest/operation-id-utilities.js.map +1 -1
- package/src/lib/type-import.d.ts +5 -3
- package/src/lib/type-import.js +25 -11
- package/src/lib/type-import.js.map +1 -1
- package/src/lib/upstream-options.d.ts +45 -0
- package/src/lib/upstream-options.js +54 -0
- package/src/lib/upstream-options.js.map +1 -0
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,73 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [1.1.0-dev.10](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.9...@rxap/ts-morph@1.1.0-dev.10) (2024-03-04)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- add type TypeName ([8e3f328](https://gitlab.com/rxap/packages/commit/8e3f32805558d10d80cad46e040e88efeaa7c0d3))
|
|
11
|
+
|
|
12
|
+
# [1.1.0-dev.9](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.8...@rxap/ts-morph@1.1.0-dev.9) (2024-03-01)
|
|
13
|
+
|
|
14
|
+
### Bug Fixes
|
|
15
|
+
|
|
16
|
+
- detect icon config ([8648071](https://gitlab.com/rxap/packages/commit/8648071772f28933d686f1984e7bb081b241f1f4))
|
|
17
|
+
|
|
18
|
+
# [1.1.0-dev.8](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.7...@rxap/ts-morph@1.1.0-dev.8) (2024-03-01)
|
|
19
|
+
|
|
20
|
+
### Bug Fixes
|
|
21
|
+
|
|
22
|
+
- guess type for uuid ([c0dc126](https://gitlab.com/rxap/packages/commit/c0dc12663d77b56624b2dfb4be347ec3101cb4cd))
|
|
23
|
+
|
|
24
|
+
# [1.1.0-dev.7](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.6...@rxap/ts-morph@1.1.0-dev.7) (2024-02-29)
|
|
25
|
+
|
|
26
|
+
### Bug Fixes
|
|
27
|
+
|
|
28
|
+
- add type arguments correctly ([6a4de9c](https://gitlab.com/rxap/packages/commit/6a4de9c1b7affa2bd42a854be647b7fcae36e8c9))
|
|
29
|
+
|
|
30
|
+
# [1.1.0-dev.6](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.5...@rxap/ts-morph@1.1.0-dev.6) (2024-02-29)
|
|
31
|
+
|
|
32
|
+
### Bug Fixes
|
|
33
|
+
|
|
34
|
+
- improve operation naming and return types ([16ea0b3](https://gitlab.com/rxap/packages/commit/16ea0b3eb2f7679c101d034e72f8013f5513ecb6))
|
|
35
|
+
|
|
36
|
+
### Features
|
|
37
|
+
|
|
38
|
+
- generate table select resolve method ([5db6649](https://gitlab.com/rxap/packages/commit/5db6649cac0ff8dd36170679fc726057fa5d57d1))
|
|
39
|
+
|
|
40
|
+
# [1.1.0-dev.5](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.4...@rxap/ts-morph@1.1.0-dev.5) (2024-02-28)
|
|
41
|
+
|
|
42
|
+
### Bug Fixes
|
|
43
|
+
|
|
44
|
+
- respect the identifier option ([bd6c6b2](https://gitlab.com/rxap/packages/commit/bd6c6b2d6770534f7d2136ac489acae2de8f0d16))
|
|
45
|
+
|
|
46
|
+
### Features
|
|
47
|
+
|
|
48
|
+
- support custom properties for accordion controllers ([82da170](https://gitlab.com/rxap/packages/commit/82da170f9ff490ec2502e0b21283b100848e6108))
|
|
49
|
+
|
|
50
|
+
# [1.1.0-dev.4](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.3...@rxap/ts-morph@1.1.0-dev.4) (2024-02-26)
|
|
51
|
+
|
|
52
|
+
### Features
|
|
53
|
+
|
|
54
|
+
- support default type import ([0c50e7a](https://gitlab.com/rxap/packages/commit/0c50e7a837d4b985f3fbb5062d058e54cd223e22))
|
|
55
|
+
|
|
56
|
+
# [1.1.0-dev.3](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.2...@rxap/ts-morph@1.1.0-dev.3) (2024-02-26)
|
|
57
|
+
|
|
58
|
+
### Bug Fixes
|
|
59
|
+
|
|
60
|
+
- support non service commands ([7346933](https://gitlab.com/rxap/packages/commit/73469338e563e4c2d589f8059959380acc6d61fb))
|
|
61
|
+
|
|
62
|
+
# [1.1.0-dev.2](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.1...@rxap/ts-morph@1.1.0-dev.2) (2024-02-25)
|
|
63
|
+
|
|
64
|
+
### Bug Fixes
|
|
65
|
+
|
|
66
|
+
- use namedImport before name ([eb33f27](https://gitlab.com/rxap/packages/commit/eb33f276c69aaddbb73e8e93a781d08986f56136))
|
|
67
|
+
|
|
68
|
+
### Features
|
|
69
|
+
|
|
70
|
+
- add NormalizeTypeImportList function ([8887b8e](https://gitlab.com/rxap/packages/commit/8887b8e92a32f88d2f1703253a12d68a0ed36294))
|
|
71
|
+
- support upstream configurations ([3c972cf](https://gitlab.com/rxap/packages/commit/3c972cfc1aea45d9cabca07f24f4627f4aff03aa))
|
|
72
|
+
|
|
6
73
|
# [1.1.0-dev.1](https://gitlab.com/rxap/packages/compare/@rxap/ts-morph@1.1.0-dev.0...@rxap/ts-morph@1.1.0-dev.1) (2024-02-22)
|
|
7
74
|
|
|
8
75
|
### Bug Fixes
|
package/README.md
CHANGED
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.1.0-dev.
|
|
2
|
+
"version": "1.1.0-dev.10",
|
|
3
3
|
"name": "@rxap/ts-morph",
|
|
4
4
|
"license": "GPL-3.0-or-later",
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"tslib": "2.6.2"
|
|
7
7
|
},
|
|
8
8
|
"peerDependencies": {
|
|
9
|
-
"@rxap/utilities": "^16.0.
|
|
9
|
+
"@rxap/utilities": "^16.1.0-dev.5",
|
|
10
10
|
"ts-morph": "^18.0.0",
|
|
11
11
|
"tslib": "2.6.2"
|
|
12
12
|
},
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"packageGroup": [
|
|
29
29
|
{
|
|
30
30
|
"package": "@rxap/utilities",
|
|
31
|
-
"version": "16.0.
|
|
31
|
+
"version": "16.1.0-dev.5"
|
|
32
32
|
}
|
|
33
33
|
]
|
|
34
34
|
},
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"directory": "packages/ts-morph"
|
|
43
43
|
},
|
|
44
44
|
"type": "commonjs",
|
|
45
|
-
"gitHead": "
|
|
45
|
+
"gitHead": "1cbac86e12b74f4ffffb4b4b9b65f2bdfdb47384",
|
|
46
46
|
"main": "./src/index.js",
|
|
47
47
|
"types": "./src/index.d.ts"
|
|
48
48
|
}
|
package/src/index.d.ts
CHANGED
package/src/index.js
CHANGED
|
@@ -67,6 +67,7 @@ tslib_1.__exportStar(require("./lib/has-constructor-parameter"), exports);
|
|
|
67
67
|
tslib_1.__exportStar(require("./lib/provider-object"), exports);
|
|
68
68
|
tslib_1.__exportStar(require("./lib/to-mapping-object"), exports);
|
|
69
69
|
tslib_1.__exportStar(require("./lib/type-import"), exports);
|
|
70
|
+
tslib_1.__exportStar(require("./lib/upstream-options"), exports);
|
|
70
71
|
tslib_1.__exportStar(require("./lib/write-type"), exports);
|
|
71
72
|
// endregion
|
|
72
73
|
//# sourceMappingURL=index.js.map
|
package/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../packages/ts-morph/src/index.ts"],"names":[],"mappings":";;;AAAA,cAAc;AACd,yEAA+C;AAC/C,0EAAgD;AAChD,mFAAyD;AACzD,+EAAqD;AACrD,8EAAoD;AACpD,0EAAgD;AAChD,4EAAkD;AAClD,gFAAsD;AACtD,4EAAkD;AAClD,sFAA4D;AAC5D,4EAAkD;AAClD,sFAA4D;AAC5D,iFAAuD;AACvD,mFAAyD;AACzD,+EAAqD;AACrD,iFAAuD;AACvD,wEAA8C;AAC9C,2EAAiD;AACjD,mFAAyD;AACzD,yFAA+D;AAC/D,kFAAwD;AACxD,0EAAgD;AAChD,8EAAoD;AACpD,2EAAiD;AACjD,0EAAgD;AAChD,0EAAgD;AAChD,4EAAkD;AAClD,iFAAuD;AACvD,mFAAyD;AACzD,YAAY;AAEZ,iBAAiB;AACjB,mFAAyD;AACzD,gFAAsD;AACtD,+EAAqD;AACrD,yEAA+C;AAC/C,4EAAkD;AAClD,uFAA6D;AAC7D,YAAY;AAEZ,UAAU;AACV,sEAA4C;AAC5C,4EAAkD;AAClD,qEAA2C;AAC3C,yEAA+C;AAC/C,oEAA0C;AAC1C,sEAA4C;AAC5C,6DAAmC;AACnC,iEAAuC;AACvC,4EAAkD;AAClD,4EAAkD;AAClD,+DAAqC;AACrC,4EAAkD;AAClD,4EAAkD;AAClD,mEAAyC;AACzC,kEAAwC;AACxC,4EAAkD;AAClD,+DAAqC;AACrC,8DAAoC;AACpC,8DAAoC;AACpC,8EAAoD;AACpD,0DAAgC;AAChC,6FAAmE;AACnE,0EAAgD;AAChD,gEAAsC;AACtC,kEAAwC;AACxC,4DAAkC;AAClC,2DAAiC;AACjC,YAAY"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../packages/ts-morph/src/index.ts"],"names":[],"mappings":";;;AAAA,cAAc;AACd,yEAA+C;AAC/C,0EAAgD;AAChD,mFAAyD;AACzD,+EAAqD;AACrD,8EAAoD;AACpD,0EAAgD;AAChD,4EAAkD;AAClD,gFAAsD;AACtD,4EAAkD;AAClD,sFAA4D;AAC5D,4EAAkD;AAClD,sFAA4D;AAC5D,iFAAuD;AACvD,mFAAyD;AACzD,+EAAqD;AACrD,iFAAuD;AACvD,wEAA8C;AAC9C,2EAAiD;AACjD,mFAAyD;AACzD,yFAA+D;AAC/D,kFAAwD;AACxD,0EAAgD;AAChD,8EAAoD;AACpD,2EAAiD;AACjD,0EAAgD;AAChD,0EAAgD;AAChD,4EAAkD;AAClD,iFAAuD;AACvD,mFAAyD;AACzD,YAAY;AAEZ,iBAAiB;AACjB,mFAAyD;AACzD,gFAAsD;AACtD,+EAAqD;AACrD,yEAA+C;AAC/C,4EAAkD;AAClD,uFAA6D;AAC7D,YAAY;AAEZ,UAAU;AACV,sEAA4C;AAC5C,4EAAkD;AAClD,qEAA2C;AAC3C,yEAA+C;AAC/C,oEAA0C;AAC1C,sEAA4C;AAC5C,6DAAmC;AACnC,iEAAuC;AACvC,4EAAkD;AAClD,4EAAkD;AAClD,+DAAqC;AACrC,4EAAkD;AAClD,4EAAkD;AAClD,mEAAyC;AACzC,kEAAwC;AACxC,4EAAkD;AAClD,+DAAqC;AACrC,8DAAoC;AACpC,8DAAoC;AACpC,8EAAoD;AACpD,0DAAgC;AAChC,6FAAmE;AACnE,0EAAgD;AAChD,gEAAsC;AACtC,kEAAwC;AACxC,4DAAkC;AAClC,iEAAuC;AACvC,2DAAiC;AACjC,YAAY"}
|
|
@@ -15,9 +15,10 @@ const get_component_decorator_object_1 = require("./get-component-decorator-obje
|
|
|
15
15
|
* @returns - The updated imports array after coercing the import.
|
|
16
16
|
*/
|
|
17
17
|
function CoerceComponentImport(sourceFileOrClassDeclaration, componentImport) {
|
|
18
|
+
var _a;
|
|
18
19
|
const classDeclaration = sourceFileOrClassDeclaration instanceof ts_morph_2.ClassDeclaration ? sourceFileOrClassDeclaration : (0, ts_morph_1.GetComponentClass)(sourceFileOrClassDeclaration);
|
|
19
20
|
const sourceFile = sourceFileOrClassDeclaration instanceof ts_morph_2.SourceFile ? sourceFileOrClassDeclaration : sourceFileOrClassDeclaration.getSourceFile();
|
|
20
|
-
const importName = typeof componentImport === 'string' ? componentImport : componentImport.name;
|
|
21
|
+
const importName = typeof componentImport === 'string' ? componentImport : (_a = componentImport.namedImport) !== null && _a !== void 0 ? _a : componentImport.name;
|
|
21
22
|
if ((0, ts_morph_1.IsTypeImport)(componentImport)) {
|
|
22
23
|
(0, coerce_imports_1.CoerceImports)(sourceFile, (0, ts_morph_1.TypeImportToImportStructure)(componentImport));
|
|
23
24
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-component-import.js","sourceRoot":"","sources":["../../../../../../packages/ts-morph/src/lib/angular/coerce-component-import.ts"],"names":[],"mappings":";;;AAAA,6CAMwB;AACxB,sDAAkD;AAClD,uCAGkB;AAClB,kHAAyG;AACzG,qFAA+E;AAE/E;;;;;;;GAOG;AACH,SAAgB,qBAAqB,CACnC,4BAA2D,EAC3D,eAAoC
|
|
1
|
+
{"version":3,"file":"coerce-component-import.js","sourceRoot":"","sources":["../../../../../../packages/ts-morph/src/lib/angular/coerce-component-import.ts"],"names":[],"mappings":";;;AAAA,6CAMwB;AACxB,sDAAkD;AAClD,uCAGkB;AAClB,kHAAyG;AACzG,qFAA+E;AAE/E;;;;;;;GAOG;AACH,SAAgB,qBAAqB,CACnC,4BAA2D,EAC3D,eAAoC;;IAGpC,MAAM,gBAAgB,GAAG,4BAA4B,YAAY,2BAAgB,CAAC,CAAC,CAAC,4BAA4B,CAAC,CAAC,CAAC,IAAA,4BAAiB,EAAC,4BAA4B,CAAC,CAAC;IACnK,MAAM,UAAU,GAAG,4BAA4B,YAAY,qBAAU,CAAC,CAAC,CAAC,4BAA4B,CAAC,CAAC,CAAC,4BAA4B,CAAC,aAAa,EAAE,CAAC;IAEpJ,MAAM,UAAU,GAAG,OAAO,eAAe,KAAK,QAAQ,CAAC,CAAC,CAAC,eAAe,CAAC,CAAC,CAAC,MAAA,eAAe,CAAC,WAAW,mCAAI,eAAe,CAAC,IAAI,CAAC;IAE/H,IAAI,IAAA,uBAAY,EAAC,eAAe,CAAC,EAAE;QACjC,IAAA,8BAAa,EAAC,UAAU,EAAE,IAAA,sCAA2B,EAAC,eAAe,CAAC,CAAC,CAAC;KACzE;IAED,MAAM,wBAAwB,GAAG,IAAA,4DAA2B,EAAC,gBAAgB,CAAC,CAAC;IAE/E,MAAM,YAAY,GAAG,IAAA,qFAAsC,EAAC,wBAAwB,EAAE,SAAS,CAAC,CAAC;IAEjG,IAAA,6BAAkB,EAAC,YAAY,EAAE,UAAU,CAAC,CAAC;IAE7C,OAAO,YAAY,CAAC;AAEtB,CAAC;AAtBD,sDAsBC"}
|
|
@@ -3,6 +3,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.CoerceDecorator = void 0;
|
|
4
4
|
const find_function_1 = require("./find-function");
|
|
5
5
|
function CoerceDecorator(decoratableNode, name, structure = {}, compareTo = find_function_1.FindByNameFunction) {
|
|
6
|
+
const match = name.match(/(.+)<(.+)>/);
|
|
7
|
+
if (match) {
|
|
8
|
+
name = match[1];
|
|
9
|
+
structure.typeArguments = match[2].split(',');
|
|
10
|
+
}
|
|
6
11
|
let decorator = decoratableNode.getDecorator(compareTo(Object.assign(Object.assign({}, structure), { name })));
|
|
7
12
|
if (!decorator) {
|
|
8
13
|
decorator = decoratableNode.addDecorator({ name });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-decorator.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/coerce-decorator.ts"],"names":[],"mappings":";;;AAMA,mDAGyB;AAEzB,SAAgB,eAAe,CAC7B,eAAgC,EAChC,IAAY,EACZ,YAAqE,EAAE,EACvE,YAA4F,kCAAkB;IAE9G,IAAI,SAAS,GAAG,eAAe,CAAC,YAAY,CAAC,SAAS,iCACjD,SAAS,KACZ,IAAI,IACJ,CAAC,CAAC;IACJ,IAAI,CAAC,SAAS,EAAE;QACd,SAAS,GAAG,eAAe,CAAC,YAAY,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC;QACnD,SAAS,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;KAC1B;IACD,OAAO,SAAS,CAAC;AACnB,CAAC;
|
|
1
|
+
{"version":3,"file":"coerce-decorator.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/coerce-decorator.ts"],"names":[],"mappings":";;;AAMA,mDAGyB;AAEzB,SAAgB,eAAe,CAC7B,eAAgC,EAChC,IAAY,EACZ,YAAqE,EAAE,EACvE,YAA4F,kCAAkB;IAE9G,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;IACvC,IAAI,KAAK,EAAE;QACT,IAAI,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;QAChB,SAAS,CAAC,aAAa,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;KAC/C;IACD,IAAI,SAAS,GAAG,eAAe,CAAC,YAAY,CAAC,SAAS,iCACjD,SAAS,KACZ,IAAI,IACJ,CAAC,CAAC;IACJ,IAAI,CAAC,SAAS,EAAE;QACd,SAAS,GAAG,eAAe,CAAC,YAAY,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC;QACnD,SAAS,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;KAC1B;IACD,OAAO,SAAS,CAAC;AACnB,CAAC;AApBD,0CAoBC"}
|
|
@@ -1,15 +1,18 @@
|
|
|
1
|
-
import { TypeImport } from '@rxap/ts-morph';
|
|
1
|
+
import { TypeImport, TypeName } from '@rxap/ts-morph';
|
|
2
2
|
import { Normalized } from '@rxap/utilities';
|
|
3
3
|
import { OptionalKind, PropertySignatureStructure, SourceFile } from 'ts-morph';
|
|
4
4
|
import { NormalizedTypeImport } from './type-import';
|
|
5
5
|
export interface DataProperty {
|
|
6
6
|
name: string;
|
|
7
|
-
type?:
|
|
7
|
+
type?: TypeImport | TypeName;
|
|
8
8
|
isArray?: boolean;
|
|
9
|
+
isOptional?: boolean;
|
|
10
|
+
source?: string | null;
|
|
9
11
|
}
|
|
10
12
|
export interface NormalizedDataProperty extends Readonly<Normalized<DataProperty>> {
|
|
11
13
|
type: NormalizedTypeImport;
|
|
14
|
+
source: string | null;
|
|
12
15
|
}
|
|
13
|
-
export declare function NormalizeDataProperty(property:
|
|
14
|
-
export declare function NormalizeDataPropertyList(propertyList?: Array<string | DataProperty>, defaultType?: string):
|
|
16
|
+
export declare function NormalizeDataProperty(property: TypeName | Readonly<DataProperty>, defaultType?: TypeImport | TypeName, isArray?: boolean): NormalizedDataProperty;
|
|
17
|
+
export declare function NormalizeDataPropertyList(propertyList?: Array<string | DataProperty>, defaultType?: string): Array<NormalizedDataProperty>;
|
|
15
18
|
export declare function NormalizeDataPropertyToPropertySignatureStructure(property: DataProperty, sourceFile: SourceFile): OptionalKind<PropertySignatureStructure>;
|
package/src/lib/data-property.js
CHANGED
|
@@ -8,28 +8,42 @@ function guessType(name) {
|
|
|
8
8
|
case 'uuid':
|
|
9
9
|
case 'name':
|
|
10
10
|
return 'string';
|
|
11
|
+
case 'icon':
|
|
12
|
+
return {
|
|
13
|
+
name: 'IconConfig',
|
|
14
|
+
moduleSpecifier: '@rxap/utilities',
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
if (name.match(/Uuid$/)) {
|
|
18
|
+
return 'string';
|
|
19
|
+
}
|
|
20
|
+
if (name.match(/Name$/)) {
|
|
21
|
+
return 'string';
|
|
11
22
|
}
|
|
12
23
|
if (name.match(/^(is|has)[A-Z]/)) {
|
|
13
24
|
return 'boolean';
|
|
14
25
|
}
|
|
15
26
|
return 'unknown';
|
|
16
27
|
}
|
|
17
|
-
function NormalizeDataProperty(property, defaultType = 'unknown') {
|
|
18
|
-
var _a, _b;
|
|
28
|
+
function NormalizeDataProperty(property, defaultType = 'unknown', isArray = false) {
|
|
29
|
+
var _a, _b, _c, _d;
|
|
19
30
|
let name;
|
|
20
31
|
let type = 'unknown';
|
|
21
|
-
let
|
|
32
|
+
let isOptional = false;
|
|
33
|
+
let source = null;
|
|
22
34
|
if (typeof property === 'string') {
|
|
23
35
|
// name:type
|
|
24
36
|
// username:string
|
|
25
37
|
const fragments = property.split(':');
|
|
26
38
|
name = fragments[0];
|
|
27
|
-
type = fragments[1] ||
|
|
39
|
+
type = fragments[1] || type; // convert an empty string to undefined
|
|
28
40
|
}
|
|
29
41
|
else {
|
|
30
42
|
name = property.name;
|
|
31
|
-
type = (_a = property.type) !== null && _a !== void 0 ? _a :
|
|
43
|
+
type = (_a = property.type) !== null && _a !== void 0 ? _a : type;
|
|
32
44
|
isArray = (_b = property.isArray) !== null && _b !== void 0 ? _b : isArray;
|
|
45
|
+
isOptional = (_c = property.isOptional) !== null && _c !== void 0 ? _c : isOptional;
|
|
46
|
+
source = (_d = property.source) !== null && _d !== void 0 ? _d : source;
|
|
33
47
|
}
|
|
34
48
|
if (name.endsWith('[]')) {
|
|
35
49
|
isArray = true;
|
|
@@ -40,17 +54,22 @@ function NormalizeDataProperty(property, defaultType = 'unknown') {
|
|
|
40
54
|
name = name.slice(6, -1);
|
|
41
55
|
}
|
|
42
56
|
type !== null && type !== void 0 ? type : (type = defaultType);
|
|
57
|
+
if (type === 'unknown') {
|
|
58
|
+
type = guessType(name);
|
|
59
|
+
}
|
|
43
60
|
name = name.replace(/\.\?/g, '.').split('.').join('.?');
|
|
44
61
|
return Object.freeze({
|
|
45
62
|
name,
|
|
46
63
|
type: (0, type_import_1.NormalizeTypeImport)(type),
|
|
47
64
|
isArray,
|
|
65
|
+
isOptional,
|
|
66
|
+
source,
|
|
48
67
|
});
|
|
49
68
|
}
|
|
50
69
|
exports.NormalizeDataProperty = NormalizeDataProperty;
|
|
51
70
|
function NormalizeDataPropertyList(propertyList, defaultType = 'unknown') {
|
|
52
71
|
var _a;
|
|
53
|
-
return
|
|
72
|
+
return (_a = propertyList === null || propertyList === void 0 ? void 0 : propertyList.map(property => NormalizeDataProperty(property, defaultType))) !== null && _a !== void 0 ? _a : [];
|
|
54
73
|
}
|
|
55
74
|
exports.NormalizeDataPropertyList = NormalizeDataPropertyList;
|
|
56
75
|
function NormalizeDataPropertyToPropertySignatureStructure(property, sourceFile) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"data-property.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/data-property.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"data-property.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/data-property.ts"],"names":[],"mappings":";;;AAUA,+CAGuB;AACvB,6CAAyC;AAezC,SAAS,SAAS,CAAC,IAAY;IAC7B,QAAQ,IAAI,EAAE;QACZ,KAAK,MAAM,CAAC;QACZ,KAAK,MAAM;YACT,OAAO,QAAQ,CAAC;QAClB,KAAK,MAAM;YACT,OAAO;gBACL,IAAI,EAAE,YAAY;gBAClB,eAAe,EAAE,iBAAiB;aACnC,CAAC;KACL;IACD,IAAI,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,EAAE;QACvB,OAAO,QAAQ,CAAC;KACjB;IACD,IAAI,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,EAAE;QACvB,OAAO,QAAQ,CAAC;KACjB;IACD,IAAI,IAAI,CAAC,KAAK,CAAC,gBAAgB,CAAC,EAAE;QAChC,OAAO,SA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AAJ,IAAI,cAAJ,IAAI,IAAJ,IAAI,GAAK,WAAW,EAAC;IACrB,IAAI,IAAI,KAAK,SAAS,EAAE;QACtB,IAAI,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC;KACxB;IACD,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACxD,OAAO,MAAM,CAAC,MAAM,CAAC;QACnB,IAAI;QACJ,IAAI,EAAE,IAAA,iCAAmB,EAAC,IAAI,CAAC;QAC/B,OAAO;QACP,UAAU;QACV,MAAM;KACP,CAAC,CAAC;AACL,CAAC;AAtCD,sDAsCC;AAED,SAAgB,yBAAyB,CAAC,YAA2C,EAAE,WAAW,GAAG,SAAS;;IAC5G,OAAO,MAAA,YAAY,aAAZ,YAAY,uBAAZ,YAAY,CAAE,GAAG,CAAC,QAAQ,CAAC,EAAE,CAAC,qBAAqB,CAAC,QAAQ,EAAE,WAAW,CAAC,CAAC,mCAAI,EAAE,CAAC;AAC3F,CAAC;AAFD,8DAEC;AAED,SAAgB,iDAAiD,CAC/D,QAAsB,EACtB,UAAsB;IAEtB,OAAO;QACL,IAAI,EAAE,IAAA,sBAAS,EAAC,QAAQ,EAAE,UAAU,CAAC;QACrC,IAAI,EAAE,QAAQ,CAAC,IAAI;KACpB,CAAC;AACJ,CAAC;AARD,8GAQC"}
|
package/src/lib/find-function.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.FindByNameFunction = void 0;
|
|
4
4
|
function FindByNameFunction(compareTo) {
|
|
5
|
-
return node => node.getName() === compareTo.name;
|
|
5
|
+
return node => { var _a; return ((_a = node.getName()) === null || _a === void 0 ? void 0 : _a.trim()) === compareTo.name; };
|
|
6
6
|
}
|
|
7
7
|
exports.FindByNameFunction = FindByNameFunction;
|
|
8
8
|
//# sourceMappingURL=find-function.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-function.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/find-function.ts"],"names":[],"mappings":";;;AAIA,SAAgB,kBAAkB,CAGhC,SAAoB;IACpB,OAAO,IAAI,CAAC,EAAE,
|
|
1
|
+
{"version":3,"file":"find-function.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/find-function.ts"],"names":[],"mappings":";;;AAIA,SAAgB,kBAAkB,CAGhC,SAAoB;IACpB,OAAO,IAAI,CAAC,EAAE,WAAC,OAAA,CAAA,MAAA,IAAI,CAAC,OAAO,EAAE,0CAAE,IAAI,EAAE,MAAK,SAAS,CAAC,IAAI,CAAA,EAAA,CAAC;AAC3D,CAAC;AALD,gDAKC"}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { ClassDeclaration, DecoratorStructure, MethodDeclaration, OptionalKind, SourceFile, StatementStructures, WriterFunction } from 'ts-morph';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
import { DataProperty } from '../data-property';
|
|
3
|
+
import { TypeImport } from '../type-import';
|
|
4
|
+
export interface OperationParameter extends DataProperty {
|
|
5
|
+
type?: string | WriterFunction | TypeImport;
|
|
6
|
+
pipeList?: Array<string | WriterFunction | TypeImport>;
|
|
6
7
|
defaultValue?: string | WriterFunction;
|
|
8
|
+
hasQuestionToken?: boolean;
|
|
7
9
|
required?: boolean;
|
|
8
|
-
isArray?: boolean;
|
|
9
10
|
/**
|
|
10
11
|
* (optional) the method parameter name. If not defined the name property will be used
|
|
11
12
|
*/
|
|
@@ -7,8 +7,9 @@ const coerce_class_method_1 = require("../coerce-class-method");
|
|
|
7
7
|
const coerce_decorator_1 = require("../coerce-decorator");
|
|
8
8
|
const coerce_imports_1 = require("../coerce-imports");
|
|
9
9
|
const coerce_statements_1 = require("../coerce-statements");
|
|
10
|
+
const write_type_1 = require("../write-type");
|
|
10
11
|
const get_controller_class_1 = require("./get-controller-class");
|
|
11
|
-
function buildMethodQueryParameters(queryList,
|
|
12
|
+
function buildMethodQueryParameters(queryList, sourceFile) {
|
|
12
13
|
if (queryList.length) {
|
|
13
14
|
return queryList.map(query => {
|
|
14
15
|
var _a, _b;
|
|
@@ -16,7 +17,7 @@ function buildMethodQueryParameters(queryList, importStructures) {
|
|
|
16
17
|
undefined) {
|
|
17
18
|
return query;
|
|
18
19
|
}
|
|
19
|
-
|
|
20
|
+
(0, coerce_imports_1.CoerceImports)(sourceFile, {
|
|
20
21
|
namedImports: ['DefaultValuePipe'],
|
|
21
22
|
moduleSpecifier: '@nestjs/common',
|
|
22
23
|
});
|
|
@@ -35,35 +36,38 @@ function buildMethodQueryParameters(queryList, importStructures) {
|
|
|
35
36
|
w.write(')');
|
|
36
37
|
});
|
|
37
38
|
return Object.assign(Object.assign({}, query), { pipeList });
|
|
38
|
-
}).map(
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
39
|
+
}).map(({ alias, name, type, hasQuestionToken, required, defaultValue, pipeList = [], isArray, }) => ({
|
|
40
|
+
name: alias !== null && alias !== void 0 ? alias : name,
|
|
41
|
+
type: (0, write_type_1.WriteType)({ type: type !== null && type !== void 0 ? type : 'unknown', isArray: isArray }, sourceFile),
|
|
42
|
+
hasQuestionToken: hasQuestionToken !== null && hasQuestionToken !== void 0 ? hasQuestionToken : (!required && defaultValue === undefined),
|
|
43
|
+
decorators: [
|
|
44
|
+
{
|
|
45
|
+
name: 'Query',
|
|
46
|
+
arguments: [
|
|
47
|
+
w => w.quote(name),
|
|
48
|
+
...pipeList.map(pipe => {
|
|
49
|
+
if (typeof pipe === 'string') {
|
|
50
|
+
return pipe;
|
|
51
|
+
}
|
|
52
|
+
if (typeof pipe === 'function') {
|
|
53
|
+
return pipe;
|
|
54
|
+
}
|
|
55
|
+
return (0, write_type_1.WriteType)(pipe, sourceFile);
|
|
56
|
+
}),
|
|
57
|
+
],
|
|
58
|
+
},
|
|
59
|
+
],
|
|
60
|
+
}));
|
|
57
61
|
}
|
|
58
62
|
return [];
|
|
59
63
|
}
|
|
60
|
-
function buildMethodParamParameters(paramList) {
|
|
64
|
+
function buildMethodParamParameters(paramList, sourceFile) {
|
|
61
65
|
if (paramList.length) {
|
|
62
66
|
return paramList.map(param => {
|
|
63
|
-
var _a;
|
|
67
|
+
var _a, _b;
|
|
64
68
|
return ({
|
|
65
69
|
name: (_a = param.alias) !== null && _a !== void 0 ? _a : param.name,
|
|
66
|
-
type: param.type,
|
|
70
|
+
type: (0, write_type_1.WriteType)({ type: (_b = param.type) !== null && _b !== void 0 ? _b : 'unknown', isArray: param.isArray }, sourceFile),
|
|
67
71
|
decorators: [
|
|
68
72
|
{
|
|
69
73
|
name: 'Param',
|
|
@@ -208,8 +212,8 @@ function CoerceNestOperation(sourceFile, options) {
|
|
|
208
212
|
scope: ts_morph_1.Scope.Public,
|
|
209
213
|
isAsync,
|
|
210
214
|
parameters: [
|
|
211
|
-
...buildMethodQueryParameters(queryList,
|
|
212
|
-
...buildMethodParamParameters(paramList),
|
|
215
|
+
...buildMethodQueryParameters(queryList, sourceFile),
|
|
216
|
+
...buildMethodParamParameters(paramList, sourceFile),
|
|
213
217
|
...buildMethodBodyParameters(body),
|
|
214
218
|
].sort((a, b) => {
|
|
215
219
|
if (a.hasQuestionToken && b.hasQuestionToken) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-nest-operation.js","sourceRoot":"","sources":["../../../../../../packages/ts-morph/src/lib/nest/coerce-nest-operation.ts"],"names":[],"mappings":";;;AAAA,+CAGyB;AACzB,uCAckB;AAClB,gEAA2D;AAC3D,0DAAsD;AACtD,sDAAkD;AAClD,4DAAwD;
|
|
1
|
+
{"version":3,"file":"coerce-nest-operation.js","sourceRoot":"","sources":["../../../../../../packages/ts-morph/src/lib/nest/coerce-nest-operation.ts"],"names":[],"mappings":";;;AAAA,+CAGyB;AACzB,uCAckB;AAClB,gEAA2D;AAC3D,0DAAsD;AACtD,sDAAkD;AAClD,4DAAwD;AAGxD,8CAA0C;AAC1C,iEAA4D;AA+C5D,SAAS,0BAA0B,CACjC,SAA+B,EAC/B,UAAsB;IAEtB,IAAI,SAAS,CAAC,MAAM,EAAE;QACpB,OAAO,SAAS,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE;;YAC3B,IAAI,KAAK,CAAC,YAAY;gBACpB,SAAS,EAAE;gBACX,OAAO,KAAK,CAAC;aACd;YACD,IAAA,8BAAa,EAAC,UAAU,EAAE;gBACxB,YAAY,EAAE,CAAE,kBAAkB,CAAE;gBACpC,eAAe,EAAE,gBAAgB;aAClC,CAAC,CAAC;YACH,MAAM,QAAQ,GAAG,MAAA,MAAA,KAAK,CAAC,QAAQ,0CAAE,KAAK,EAAE,mCAAI,EAAE,CAAC;YAC/C,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE;gBAChB,CAAC,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAC;gBACjC,IAAI,OAAO,KAAK,CAAC,YAAY,KAAK,QAAQ,EAAE;oBAC1C,CAAC,CAAC,KAAK,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;iBAC7B;qBAAM,IAAI,OAAO,KAAK,CAAC,YAAY,KAAK,UAAU,EAAE;oBACnD,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC;iBACvB;qBAAM;oBACL,MAAM,IAAI,KAAK,CAAC,uDAAuD,CAAC,CAAC;iBAC1E;gBACD,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;YACf,CAAC,CAAC,CAAC;YACH,uCACK,KAAK,KACR,QAAQ,IACR;QACJ,CAAC,CAAC,CAAC,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
1
|
+
export declare function OperationIdToRemoteMethodClassName(operationId: string): string;
|
|
2
|
+
export declare function OperationIdToCommandClassName(operationId: string): string;
|
|
3
3
|
export declare function OperationIdToResponseClassName(operationId: string): string;
|
|
4
4
|
export declare function OperationIdToParameterClassName(operationId: string): string;
|
|
5
|
-
export declare function
|
|
5
|
+
export declare function OperationIdToClassRemoteMethodImportPath(operationId: string, scope?: string | null): string;
|
|
6
6
|
export declare function OperationIdToRequestBodyClassName(operationId: string): string;
|
|
7
|
-
export declare function
|
|
7
|
+
export declare function OperationIdToCommandClassImportPath(operationId: string, scope?: string | null, isService?: boolean): string;
|
|
8
8
|
export declare function OpenApiResponseClassImportPath(response: string, serverId: string, scope?: string | null): string;
|
|
9
9
|
export declare function OperationIdToResponseClassImportPath(operationId: string, scope?: string | null): string;
|
|
10
10
|
export declare function OperationIdToParameterClassImportPath(operationId: string, scope?: string | null): string;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.OperationIdToRequestBodyClassImportPath = exports.OperationIdToParameterClassImportPath = exports.OperationIdToResponseClassImportPath = exports.OpenApiResponseClassImportPath = exports.
|
|
3
|
+
exports.OperationIdToRequestBodyClassImportPath = exports.OperationIdToParameterClassImportPath = exports.OperationIdToResponseClassImportPath = exports.OpenApiResponseClassImportPath = exports.OperationIdToCommandClassImportPath = exports.OperationIdToRequestBodyClassName = exports.OperationIdToClassRemoteMethodImportPath = exports.OperationIdToParameterClassName = exports.OperationIdToResponseClassName = exports.OperationIdToCommandClassName = exports.OperationIdToRemoteMethodClassName = void 0;
|
|
4
4
|
const utilities_1 = require("@rxap/utilities");
|
|
5
|
-
function
|
|
5
|
+
function OperationIdToRemoteMethodClassName(operationId) {
|
|
6
6
|
const [id] = operationId.split('@');
|
|
7
7
|
return (0, utilities_1.classify)(id) + 'RemoteMethod';
|
|
8
8
|
}
|
|
9
|
-
exports.
|
|
10
|
-
function
|
|
9
|
+
exports.OperationIdToRemoteMethodClassName = OperationIdToRemoteMethodClassName;
|
|
10
|
+
function OperationIdToCommandClassName(operationId) {
|
|
11
11
|
const [id] = operationId.split('@');
|
|
12
12
|
return (0, utilities_1.classify)(id) + 'Command';
|
|
13
13
|
}
|
|
14
|
-
exports.
|
|
14
|
+
exports.OperationIdToCommandClassName = OperationIdToCommandClassName;
|
|
15
15
|
function OperationIdToResponseClassName(operationId) {
|
|
16
16
|
const [id] = operationId.split('@');
|
|
17
17
|
return (0, utilities_1.classify)(id) + 'Response';
|
|
@@ -22,7 +22,7 @@ function OperationIdToParameterClassName(operationId) {
|
|
|
22
22
|
return (0, utilities_1.classify)(id) + 'Parameter';
|
|
23
23
|
}
|
|
24
24
|
exports.OperationIdToParameterClassName = OperationIdToParameterClassName;
|
|
25
|
-
function
|
|
25
|
+
function OperationIdToClassRemoteMethodImportPath(operationId, scope) {
|
|
26
26
|
const [id, serverId = 'legacy'] = operationId.split('@');
|
|
27
27
|
if (scope) {
|
|
28
28
|
return `${scope}/open-api-${(0, utilities_1.dasherize)(serverId)}/remote-methods/${(0, utilities_1.dasherize)(id)}.remote-method`;
|
|
@@ -31,22 +31,22 @@ function OperationIdToClassImportPath(operationId, scope) {
|
|
|
31
31
|
return `open-api-${(0, utilities_1.dasherize)(serverId)}/remote-methods/${(0, utilities_1.dasherize)(id)}.remote-method`;
|
|
32
32
|
}
|
|
33
33
|
}
|
|
34
|
-
exports.
|
|
34
|
+
exports.OperationIdToClassRemoteMethodImportPath = OperationIdToClassRemoteMethodImportPath;
|
|
35
35
|
function OperationIdToRequestBodyClassName(operationId) {
|
|
36
36
|
const [id] = operationId.split('@');
|
|
37
37
|
return (0, utilities_1.classify)(id) + 'RequestBody';
|
|
38
38
|
}
|
|
39
39
|
exports.OperationIdToRequestBodyClassName = OperationIdToRequestBodyClassName;
|
|
40
|
-
function
|
|
40
|
+
function OperationIdToCommandClassImportPath(operationId, scope, isService = false) {
|
|
41
41
|
const [id, serverId = 'legacy'] = operationId.split('@');
|
|
42
42
|
if (scope) {
|
|
43
|
-
return `${scope}
|
|
43
|
+
return `${scope}/${isService ? 'service-' : ''}open-api-${(0, utilities_1.dasherize)(serverId)}/commands/${(0, utilities_1.dasherize)(id)}.command`;
|
|
44
44
|
}
|
|
45
45
|
else {
|
|
46
|
-
return
|
|
46
|
+
return `${isService ? 'service-' : ''}open-api-${(0, utilities_1.dasherize)(serverId)}/commands/${(0, utilities_1.dasherize)(id)}.command`;
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
|
-
exports.
|
|
49
|
+
exports.OperationIdToCommandClassImportPath = OperationIdToCommandClassImportPath;
|
|
50
50
|
function OpenApiResponseClassImportPath(response, serverId, scope) {
|
|
51
51
|
if (scope) {
|
|
52
52
|
return `${scope}/open-api-${(0, utilities_1.dasherize)(serverId)}/responses/${(0, utilities_1.dasherize)(response)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"operation-id-utilities.js","sourceRoot":"","sources":["../../../../../../packages/ts-morph/src/lib/nest/operation-id-utilities.ts"],"names":[],"mappings":";;;AAAA,+CAGyB;AAGzB,SAAgB,
|
|
1
|
+
{"version":3,"file":"operation-id-utilities.js","sourceRoot":"","sources":["../../../../../../packages/ts-morph/src/lib/nest/operation-id-utilities.ts"],"names":[],"mappings":";;;AAAA,+CAGyB;AAGzB,SAAgB,kCAAkC,CAAC,WAAmB;IACpE,MAAM,CAAE,EAAE,CAAE,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACtC,OAAO,IAAA,oBAAQ,EAAC,EAAE,CAAC,GAAG,cAAc,CAAC;AACvC,CAAC;AAHD,gFAGC;AAED,SAAgB,6BAA6B,CAAC,WAAmB;IAC/D,MAAM,CAAE,EAAE,CAAE,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IACtC,OAAO,IAAA,oBAAQ,EAAC,EAAE,CAAC,GAAG,SAAS,CAAC;AAClC,CAAC;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C;AAPD,oFAOC;AAED,SAAgB,qCAAqC,CAAC,WAAmB,EAAE,KAAqB;IAC9F,MAAM,CAAE,EAAE,EAAE,QAAQ,GAAG,QAAQ,CAAE,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC3D,IAAI,KAAK,EAAE;QACT,OAAO,GAAI,KAAM,aAAc,IAAA,qBAAS,EAAC,QAAQ,CAAE,eAAgB,IAAA,qBAAS,EAAC,EAAE,CAAE,YAAY,CAAC;KAC/F;SAAM;QACL,OAAO,YAAa,IAAA,qBAAS,EAAC,QAAQ,CAAE,eAAgB,IAAA,qBAAS,EAAC,EAAE,CAAE,YAAY,CAAC;KACpF;AACH,CAAC;AAPD,sFAOC;AAED,SAAgB,uCAAuC,CAAC,WAAmB,EAAE,KAAqB;IAChG,MAAM,CAAE,EAAE,EAAE,QAAQ,GAAG,QAAQ,CAAE,GAAG,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;IAC3D,IAAI,KAAK,EAAE;QACT,OAAO,GAAI,KAAM,aAAc,IAAA,qBAAS,EAAC,QAAQ,CAAE,mBAAoB,IAAA,qBAAS,EAAC,EAAE,CAAE,eAAe,CAAC;KACtG;SAAM;QACL,OAAO,YAAa,IAAA,qBAAS,EAAC,QAAQ,CAAE,mBAAoB,IAAA,qBAAS,EAAC,EAAE,CAAE,eAAe,CAAC;KAC3F;AACH,CAAC;AAPD,0FAOC"}
|
package/src/lib/type-import.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ImportDeclarationStructure, OptionalKind } from 'ts-morph';
|
|
2
|
+
export type TypeName = string | '<self>' | '<deferred>' | 'unknown' | 'string' | 'number' | 'boolean' | 'any';
|
|
2
3
|
export interface TypeImport {
|
|
3
|
-
name:
|
|
4
|
+
name: TypeName;
|
|
4
5
|
moduleSpecifier?: string | null;
|
|
5
6
|
namedImport?: string | null;
|
|
6
7
|
namespaceImport?: string | null;
|
|
@@ -11,11 +12,12 @@ export declare function IsTypeImport(value: any): value is TypeImport;
|
|
|
11
12
|
export declare function RequiresTypeImport(typeImport: TypeImport): boolean;
|
|
12
13
|
export declare function TypeImportToImportStructure(typeImport: TypeImport): OptionalKind<ImportDeclarationStructure>;
|
|
13
14
|
export interface NormalizedTypeImport {
|
|
14
|
-
name: string;
|
|
15
|
+
name: string | '<self>' | '<deferred>';
|
|
15
16
|
moduleSpecifier: string | null;
|
|
16
17
|
namedImport: string | null;
|
|
17
18
|
namespaceImport: string | null;
|
|
18
19
|
isTypeOnly: boolean | null;
|
|
19
20
|
defaultImport: string | null;
|
|
20
21
|
}
|
|
21
|
-
export declare function NormalizeTypeImport(typeImport?: Readonly<TypeImport> | string): NormalizedTypeImport;
|
|
22
|
+
export declare function NormalizeTypeImport(typeImport?: Readonly<TypeImport> | string, defaultType?: TypeImport | string): NormalizedTypeImport;
|
|
23
|
+
export declare function NormalizeTypeImportList(typeImportList?: Array<TypeImport | string>, defaultType?: string): NormalizedTypeImport[];
|
package/src/lib/type-import.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NormalizeTypeImport = exports.TypeImportToImportStructure = exports.RequiresTypeImport = exports.IsTypeImport = void 0;
|
|
3
|
+
exports.NormalizeTypeImportList = exports.NormalizeTypeImport = exports.TypeImportToImportStructure = exports.RequiresTypeImport = exports.IsTypeImport = void 0;
|
|
4
4
|
function IsTypeImport(value) {
|
|
5
5
|
return typeof value === 'object' && typeof value.name === 'string';
|
|
6
6
|
}
|
|
@@ -31,8 +31,8 @@ function TypeImportToImportStructure(typeImport) {
|
|
|
31
31
|
return structure;
|
|
32
32
|
}
|
|
33
33
|
exports.TypeImportToImportStructure = TypeImportToImportStructure;
|
|
34
|
-
function NormalizeTypeImport(typeImport) {
|
|
35
|
-
var _a, _b, _c, _d, _e;
|
|
34
|
+
function NormalizeTypeImport(typeImport, defaultType = 'unknown') {
|
|
35
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
36
36
|
let name;
|
|
37
37
|
let moduleSpecifier = null;
|
|
38
38
|
let namedImport = null;
|
|
@@ -40,7 +40,17 @@ function NormalizeTypeImport(typeImport) {
|
|
|
40
40
|
let isTypeOnly = false;
|
|
41
41
|
let defaultImport = null;
|
|
42
42
|
if (!typeImport) {
|
|
43
|
-
|
|
43
|
+
if (typeof defaultType === 'string') {
|
|
44
|
+
name = defaultType;
|
|
45
|
+
}
|
|
46
|
+
else {
|
|
47
|
+
name = defaultType.name;
|
|
48
|
+
moduleSpecifier = (_a = defaultType.moduleSpecifier) !== null && _a !== void 0 ? _a : moduleSpecifier;
|
|
49
|
+
namedImport = (_b = defaultType.namedImport) !== null && _b !== void 0 ? _b : namedImport;
|
|
50
|
+
namespaceImport = (_c = defaultType.namespaceImport) !== null && _c !== void 0 ? _c : namespaceImport;
|
|
51
|
+
isTypeOnly = (_d = defaultType.isTypeOnly) !== null && _d !== void 0 ? _d : isTypeOnly;
|
|
52
|
+
defaultImport = (_e = defaultType.defaultImport) !== null && _e !== void 0 ? _e : defaultImport;
|
|
53
|
+
}
|
|
44
54
|
}
|
|
45
55
|
else if (typeof typeImport === 'string') {
|
|
46
56
|
// name:moduleSpecifier:namedImport
|
|
@@ -52,20 +62,24 @@ function NormalizeTypeImport(typeImport) {
|
|
|
52
62
|
}
|
|
53
63
|
else {
|
|
54
64
|
name = typeImport.name;
|
|
55
|
-
moduleSpecifier = (
|
|
56
|
-
namedImport = (
|
|
57
|
-
namespaceImport = (
|
|
58
|
-
isTypeOnly = (
|
|
59
|
-
defaultImport = (
|
|
65
|
+
moduleSpecifier = (_f = typeImport.moduleSpecifier) !== null && _f !== void 0 ? _f : moduleSpecifier;
|
|
66
|
+
namedImport = (_g = typeImport.namedImport) !== null && _g !== void 0 ? _g : namedImport;
|
|
67
|
+
namespaceImport = (_h = typeImport.namespaceImport) !== null && _h !== void 0 ? _h : namespaceImport;
|
|
68
|
+
isTypeOnly = (_j = typeImport.isTypeOnly) !== null && _j !== void 0 ? _j : isTypeOnly;
|
|
69
|
+
defaultImport = (_k = typeImport.defaultImport) !== null && _k !== void 0 ? _k : defaultImport;
|
|
60
70
|
}
|
|
61
|
-
return
|
|
71
|
+
return {
|
|
62
72
|
name,
|
|
63
73
|
moduleSpecifier,
|
|
64
74
|
namedImport,
|
|
65
75
|
namespaceImport,
|
|
66
76
|
isTypeOnly,
|
|
67
77
|
defaultImport,
|
|
68
|
-
}
|
|
78
|
+
};
|
|
69
79
|
}
|
|
70
80
|
exports.NormalizeTypeImport = NormalizeTypeImport;
|
|
81
|
+
function NormalizeTypeImportList(typeImportList = [], defaultType = 'unknown') {
|
|
82
|
+
return typeImportList.map(type => NormalizeTypeImport(type, defaultType));
|
|
83
|
+
}
|
|
84
|
+
exports.NormalizeTypeImportList = NormalizeTypeImportList;
|
|
71
85
|
//# sourceMappingURL=type-import.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"type-import.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/type-import.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"type-import.js","sourceRoot":"","sources":["../../../../../packages/ts-morph/src/lib/type-import.ts"],"names":[],"mappings":";;;AAgBA,SAAgB,YAAY,CAAC,KAAU;IACrC,OAAO,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,CAAC,IAAI,KAAK,QAAQ,CAAC;AACrE,CAAC;AAFD,oCAEC;AAED,SAAgB,kBAAkB,CAAC,UAAsB;IACvD,OAAO,CAAC,CAAC,UAAU,CAAC,eAAe,CAAC;AACtC,CAAC;AAFD,gDAEC;AAED,SAAgB,2BAA2B,CAAC,UAAsB;IAChE,IAAI,CAAC,UAAU,CAAC,eAAe,EAAE;QAC/B,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAC;KACpD;IACD,MAAM,SAAS,GAA6C;QAC1D,eAAe,EAAE,UA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
|
+
}
|
|
5
|
+
export type UpstreamOptions = OpenApiUpstreamOptions | BaseUpstreamOptions;
|
|
6
|
+
export type NormalizedUpstreamOptions = NormalizedOpenApiUpstreamOptions | NormalizedBaseUpstreamOptions;
|
|
7
|
+
export interface BaseUpstreamOptions {
|
|
8
|
+
kind: UpstreamOptionsKinds;
|
|
9
|
+
}
|
|
10
|
+
export interface NormalizedBaseUpstreamOptions extends Readonly<Normalized<BaseUpstreamOptions>> {
|
|
11
|
+
kind: UpstreamOptionsKinds;
|
|
12
|
+
}
|
|
13
|
+
export declare function NormalizeBaseUpstreamOptions(options: BaseUpstreamOptions): NormalizedBaseUpstreamOptions;
|
|
14
|
+
export interface CommandMapper {
|
|
15
|
+
pageIndex?: string;
|
|
16
|
+
pageSize?: string;
|
|
17
|
+
sortBy?: string;
|
|
18
|
+
sortDirection?: string;
|
|
19
|
+
list?: string;
|
|
20
|
+
total?: string;
|
|
21
|
+
value?: string;
|
|
22
|
+
filter?: {
|
|
23
|
+
eq: string;
|
|
24
|
+
join: string;
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
export interface NormalizedCommandMapper extends Readonly<Normalized<CommandMapper>> {
|
|
28
|
+
filter: {
|
|
29
|
+
eq: string;
|
|
30
|
+
join: string;
|
|
31
|
+
} | null;
|
|
32
|
+
}
|
|
33
|
+
export declare function NormalizeCommandMapper(mapper?: CommandMapper | null): NormalizedCommandMapper | null;
|
|
34
|
+
export interface OpenApiUpstreamOptions extends BaseUpstreamOptions {
|
|
35
|
+
operationId: string;
|
|
36
|
+
isService?: boolean;
|
|
37
|
+
scope?: string;
|
|
38
|
+
mapper?: CommandMapper;
|
|
39
|
+
}
|
|
40
|
+
export interface NormalizedOpenApiUpstreamOptions extends Readonly<Normalized<OpenApiUpstreamOptions>> {
|
|
41
|
+
kind: UpstreamOptionsKinds.OPEN_API;
|
|
42
|
+
}
|
|
43
|
+
export declare function NormalizeOpenApiUpstreamOptions(options: OpenApiUpstreamOptions): NormalizedOpenApiUpstreamOptions;
|
|
44
|
+
export declare function IsNormalizedOpenApiUpstreamOptions(options: NormalizedUpstreamOptions): options is NormalizedOpenApiUpstreamOptions;
|
|
45
|
+
export declare function NormalizeUpstreamOptions(options?: UpstreamOptions): NormalizedUpstreamOptions | null;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NormalizeUpstreamOptions = exports.IsNormalizedOpenApiUpstreamOptions = exports.NormalizeOpenApiUpstreamOptions = exports.NormalizeCommandMapper = exports.NormalizeBaseUpstreamOptions = exports.UpstreamOptionsKinds = void 0;
|
|
4
|
+
var UpstreamOptionsKinds;
|
|
5
|
+
(function (UpstreamOptionsKinds) {
|
|
6
|
+
UpstreamOptionsKinds["OPEN_API"] = "open-api";
|
|
7
|
+
})(UpstreamOptionsKinds || (exports.UpstreamOptionsKinds = UpstreamOptionsKinds = {}));
|
|
8
|
+
function NormalizeBaseUpstreamOptions(options) {
|
|
9
|
+
return Object.freeze({
|
|
10
|
+
kind: options.kind,
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
exports.NormalizeBaseUpstreamOptions = NormalizeBaseUpstreamOptions;
|
|
14
|
+
function NormalizeCommandMapper(mapper) {
|
|
15
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
16
|
+
if (!mapper || Object.keys(mapper).length === 0) {
|
|
17
|
+
return null;
|
|
18
|
+
}
|
|
19
|
+
return Object.freeze({
|
|
20
|
+
pageIndex: (_a = mapper.pageIndex) !== null && _a !== void 0 ? _a : null,
|
|
21
|
+
pageSize: (_b = mapper.pageSize) !== null && _b !== void 0 ? _b : null,
|
|
22
|
+
sortBy: (_c = mapper.sortBy) !== null && _c !== void 0 ? _c : null,
|
|
23
|
+
list: (_d = mapper.list) !== null && _d !== void 0 ? _d : null,
|
|
24
|
+
total: (_e = mapper.total) !== null && _e !== void 0 ? _e : null,
|
|
25
|
+
value: (_f = mapper.value) !== null && _f !== void 0 ? _f : null,
|
|
26
|
+
sortDirection: (_g = mapper.sortDirection) !== null && _g !== void 0 ? _g : null,
|
|
27
|
+
filter: mapper.filter && Object.keys((_h = mapper.filter) !== null && _h !== void 0 ? _h : {}).length ? {
|
|
28
|
+
eq: mapper.filter.eq,
|
|
29
|
+
join: mapper.filter.join,
|
|
30
|
+
} : null,
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
exports.NormalizeCommandMapper = NormalizeCommandMapper;
|
|
34
|
+
function NormalizeOpenApiUpstreamOptions(options) {
|
|
35
|
+
var _a, _b;
|
|
36
|
+
return Object.freeze(Object.assign(Object.assign({}, NormalizeBaseUpstreamOptions(options)), { kind: UpstreamOptionsKinds.OPEN_API, operationId: options.operationId, mapper: NormalizeCommandMapper(options.mapper), scope: (_a = options.scope) !== null && _a !== void 0 ? _a : null, isService: (_b = options.isService) !== null && _b !== void 0 ? _b : false }));
|
|
37
|
+
}
|
|
38
|
+
exports.NormalizeOpenApiUpstreamOptions = NormalizeOpenApiUpstreamOptions;
|
|
39
|
+
function IsNormalizedOpenApiUpstreamOptions(options) {
|
|
40
|
+
return options.kind === UpstreamOptionsKinds.OPEN_API;
|
|
41
|
+
}
|
|
42
|
+
exports.IsNormalizedOpenApiUpstreamOptions = IsNormalizedOpenApiUpstreamOptions;
|
|
43
|
+
// endregion
|
|
44
|
+
function NormalizeUpstreamOptions(options) {
|
|
45
|
+
if (!options || Object.keys(options).length === 0) {
|
|
46
|
+
return null;
|
|
47
|
+
}
|
|
48
|
+
switch (options.kind) {
|
|
49
|
+
case UpstreamOptionsKinds.OPEN_API:
|
|
50
|
+
return NormalizeOpenApiUpstreamOptions(options);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
exports.NormalizeUpstreamOptions = NormalizeUpstreamOptions;
|
|
54
|
+
//# sourceMappingURL=upstream-options.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"upstream-options.js","source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