swagger-typescript-api 13.12.4 → 13.12.6

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.
@@ -171,7 +171,7 @@ var ComponentTypeNameResolver = class extends NameResolver {
171
171
  //#endregion
172
172
  //#region package.json
173
173
  var name = "swagger-typescript-api";
174
- var version = "13.12.4";
174
+ var version = "13.12.6";
175
175
  var description = "Generate the API client for Fetch or Axios from an OpenAPI Specification";
176
176
  //#endregion
177
177
  //#region src/constants.ts
@@ -261,6 +261,7 @@ const TsKeyword = {
261
261
  String: "string",
262
262
  Boolean: "boolean",
263
263
  Any: "any",
264
+ Never: "never",
264
265
  Void: "void",
265
266
  Unknown: "unknown",
266
267
  Null: "null",
@@ -1009,10 +1010,11 @@ var MonoSchemaParser = class {
1009
1010
  var ArraySchemaParser = class extends MonoSchemaParser {
1010
1011
  parse() {
1011
1012
  let contentType;
1012
- const { type, description, items } = this.schema || {};
1013
- if (Array.isArray(items) && type === SCHEMA_TYPES$1.ARRAY) {
1013
+ const { type, description, items, prefixItems } = this.schema || {};
1014
+ const tupleItems = Array.isArray(prefixItems) ? prefixItems : Array.isArray(items) ? items : null;
1015
+ if (tupleItems && type === SCHEMA_TYPES$1.ARRAY) {
1014
1016
  const tupleContent = [];
1015
- for (const item of items) tupleContent.push(this.schemaParserFabric.createSchemaParser({
1017
+ for (const item of tupleItems) tupleContent.push(this.schemaParserFabric.createSchemaParser({
1016
1018
  schema: item,
1017
1019
  schemaPath: this.schemaPath
1018
1020
  }).getInlineParseContent());
@@ -1561,6 +1563,7 @@ var SchemaParser = class {
1561
1563
  }
1562
1564
  };
1563
1565
  parseSchema = () => {
1566
+ if (typeof this.schema === "boolean") return this._baseSchemaParsers[SCHEMA_TYPES$1.PRIMITIVE]({ type: this.schema ? this.config.Ts.Keyword.Any : this.config.Ts.Keyword.Never }, this.typeName);
1564
1567
  if (!this.schema) return this._baseSchemaParsers[SCHEMA_TYPES$1.PRIMITIVE](null, this.typeName);
1565
1568
  let schemaType = null;
1566
1569
  let parsedSchema = null;
@@ -4223,4 +4226,4 @@ async function generateApi(config) {
4223
4226
  //#endregion
4224
4227
  export { SCHEMA_TYPES as a, constants_exports as c, version as d, RequestContentKind as i, description as l, generateTemplates as n, CodeGenConfig as o, TemplatesGenConfig as r, HTTP_CLIENT as s, generateApi as t, name as u };
4225
4228
 
4226
- //# sourceMappingURL=src-BZg10unC.mjs.map
4229
+ //# sourceMappingURL=src-Dex5t5WU.mjs.map