@rxap/workspace-open-api 19.1.1-dev.0 → 19.1.1-dev.1
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 +6 -0
- package/package.json +2 -2
- package/src/lib/utilities/create-component-type-alias-source-file.js +3 -0
- package/src/lib/utilities/create-component-type-alias-source-file.js.map +1 -1
- package/src/lib/utilities/ref-schema-object.d.ts +3 -0
- package/src/lib/utilities/ref-schema-object.js +4 -0
- package/src/lib/utilities/ref-schema-object.js.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,12 @@
|
|
|
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
|
+
## [19.1.1-dev.1](https://gitlab.com/rxap/packages/compare/@rxap/workspace-open-api@19.1.1-dev.0...@rxap/workspace-open-api@19.1.1-dev.1) (2025-07-07)
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
- support nullable types ([775cb2e](https://gitlab.com/rxap/packages/commit/775cb2e77c60db3cc2e5930e8c18e2535dfc03eb))
|
|
11
|
+
|
|
6
12
|
## [19.1.1-dev.0](https://gitlab.com/rxap/packages/compare/@rxap/workspace-open-api@19.1.0...@rxap/workspace-open-api@19.1.1-dev.0) (2025-05-19)
|
|
7
13
|
|
|
8
14
|
**Note:** Version bump only for package @rxap/workspace-open-api
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "19.1.1-dev.
|
|
2
|
+
"version": "19.1.1-dev.1",
|
|
3
3
|
"name": "@rxap/workspace-open-api",
|
|
4
4
|
"description": "This package provides utilities and generators for working with OpenAPI specifications in a workspace. It includes functionality for generating TypeScript interfaces, data sources, directives, remote methods, and operation commands based on an OpenAPI schema. The package also offers tools for loading OpenAPI configurations and resolving references within the schema.\n",
|
|
5
5
|
"license": "GPL-3.0-or-later",
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
},
|
|
42
42
|
"schematics": "./generators.json",
|
|
43
43
|
"type": "commonjs",
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "ec4bbc38100b50557a75466d6a1006ee26ab8392",
|
|
45
45
|
"types": "./src/index.d.ts",
|
|
46
46
|
"main": "./src/index.js"
|
|
47
47
|
}
|
|
@@ -31,6 +31,9 @@ function CreateComponentTypeAliasSourceFile(project, operationId, schema, basePa
|
|
|
31
31
|
if ((0, workspace_open_api_1.IsArrayRefSchemaObject)(schema)) {
|
|
32
32
|
type += '[]';
|
|
33
33
|
}
|
|
34
|
+
if ((0, workspace_open_api_1.IsSchemaObjectNullable)(schema) && schema.nullable) {
|
|
35
|
+
type += ' | null';
|
|
36
|
+
}
|
|
34
37
|
sourceFile.addTypeAlias({
|
|
35
38
|
name: (0, utilities_1.classify)(operationId) + (0, utilities_1.classify)(fileSuffix),
|
|
36
39
|
isExported: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-component-type-alias-source-file.js","sourceRoot":"","sources":["../../../../../../../packages/workspace/open-api/src/lib/utilities/create-component-type-alias-source-file.ts"],"names":[],"mappings":";;
|
|
1
|
+
{"version":3,"file":"create-component-type-alias-source-file.js","sourceRoot":"","sources":["../../../../../../../packages/workspace/open-api/src/lib/utilities/create-component-type-alias-source-file.ts"],"names":[],"mappings":";;AAqCA,gFA0BC;AA/DD,+CAGyB;AACzB,iEAMkC;AAClC,+BAGc;AAId;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,kCAAkC,CAChD,OAAgB,EAChB,WAAmB,EACnB,MAA8C,EAC9C,QAAgB,EAChB,UAAkB;IAElB,MAAM,UAAU,GAAG,OAAO,CAAC,gBAAgB,CAAC,IAAA,WAAI,EAAC,QAAQ,EAAE,GAAI,IAAA,qBAAS,EAAC,WAAW,CAAE,IAAK,UAAW,KAAK,CAAC,CAAC,CAAC;IAC9G,MAAM,GAAG,GAAG,IAAA,sCAAiB,EAAC,MAAM,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC;IACxE,MAAM,aAAa,GAAG,GAAG,CAAC,OAAO,CAAC,uBAAuB,EAAE,EAAE,CAAC,CAAC;IAC/D,IAAI,IAAI,GAAG,IAAA,oBAAQ,EAAC,aAAa,CAAC,CAAC;IACnC,IAAI,IAAA,2CAAsB,EAAC,MAAM,CAAC,EAAE,CAAC;QACnC,IAAI,IAAI,IAAI,CAAC;IACf,CAAC;IACD,IAAI,IAAA,2CAAsB,EAAC,MAAM,CAAC,IAAI,MAAM,CAAC,QAAQ,EAAE,CAAC;QACtD,IAAI,IAAI,SAAS,CAAC;IACpB,CAAC;IACD,UAAU,CAAC,YAAY,CAAC;QACtB,IAAI,EAAE,IAAA,oBAAQ,EAAC,WAAW,CAAC,GAAG,IAAA,oBAAQ,EAAC,UAAU,CAAC;QAClD,UAAU,EAAE,IAAI;QAChB,IAAI;KACL,CAAC,CAAC;IACH,UAAU,CAAC,qBAAqB,CAAC,CAAC;YAChC,YAAY,EAAE,CAAC,IAAA,oBAAQ,EAAC,aAAa,CAAC,CAAC;YACvC,eAAe,EAAE,GAAG,IAAA,eAAQ,EAAC,QAAQ,EAAE,EAAE,CAAC,IAAI,yCAAoB,IAAK,IAAA,qBAAS,EAAC,aAAa,CAAE,EAAE;SACnG,CAAC,CAAC,CAAC;AACN,CAAC"}
|
|
@@ -33,3 +33,6 @@ export interface ArrayRefSchemaObject {
|
|
|
33
33
|
* @returns True if the object matches the `ArrayRefSchemaObject` type criteria, false otherwise.
|
|
34
34
|
*/
|
|
35
35
|
export declare function IsArrayRefSchemaObject(obj: any): obj is ArrayRefSchemaObject;
|
|
36
|
+
export declare function IsSchemaObjectNullable<T>(obj: T): obj is T & {
|
|
37
|
+
nullable: boolean;
|
|
38
|
+
};
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.IsRefSchemaObject = IsRefSchemaObject;
|
|
4
4
|
exports.IsArrayRefSchemaObject = IsArrayRefSchemaObject;
|
|
5
|
+
exports.IsSchemaObjectNullable = IsSchemaObjectNullable;
|
|
5
6
|
/**
|
|
6
7
|
* Checks if the given object is a reference schema object.
|
|
7
8
|
*
|
|
@@ -34,4 +35,7 @@ function IsRefSchemaObject(obj) {
|
|
|
34
35
|
function IsArrayRefSchemaObject(obj) {
|
|
35
36
|
return obj && obj.type === 'array' && IsRefSchemaObject(obj.items);
|
|
36
37
|
}
|
|
38
|
+
function IsSchemaObjectNullable(obj) {
|
|
39
|
+
return obj && typeof obj === 'object' && 'nullable' in obj && typeof obj.nullable === 'boolean';
|
|
40
|
+
}
|
|
37
41
|
//# sourceMappingURL=ref-schema-object.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ref-schema-object.js","sourceRoot":"","sources":["../../../../../../../packages/workspace/open-api/src/lib/utilities/ref-schema-object.ts"],"names":[],"mappings":";;AAoBA,8CAEC;AAiBD,wDAEC;
|
|
1
|
+
{"version":3,"file":"ref-schema-object.js","sourceRoot":"","sources":["../../../../../../../packages/workspace/open-api/src/lib/utilities/ref-schema-object.ts"],"names":[],"mappings":";;AAoBA,8CAEC;AAiBD,wDAEC;AAED,wDAEC;AAzCD;;;;;;;;;;;;;;;GAeG;AACH,SAAgB,iBAAiB,CAAC,GAAQ;IACxC,OAAO,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC;AAC5B,CAAC;AAOD;;;;;;;;;GASG;AACH,SAAgB,sBAAsB,CAAC,GAAQ;IAC7C,OAAO,GAAG,IAAI,GAAG,CAAC,IAAI,KAAK,OAAO,IAAI,iBAAiB,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;AACrE,CAAC;AAED,SAAgB,sBAAsB,CAAI,GAAM;IAC9C,OAAO,GAAG,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,UAAU,IAAI,GAAG,IAAI,OAAO,GAAG,CAAC,QAAQ,KAAK,SAAS,CAAC;AAClG,CAAC"}
|