@scalar/postman-to-openapi 0.7.25 → 0.7.27

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 CHANGED
@@ -1,5 +1,14 @@
1
1
  # @scalar/postman-to-openapi
2
2
 
3
+ ## 0.7.27
4
+
5
+ ### Patch Changes
6
+
7
+ - [#10559](https://github.com/scalar/scalar/pull/10559): Clean up Biome warnings in package code and tests. Handle rejected debounced callbacks and await streaming writes.
8
+ - [#10506](https://github.com/scalar/scalar/pull/10506): Organize imports consistently with the checks enforced in CI.
9
+
10
+ ## 0.7.26
11
+
3
12
  ## 0.7.25
4
13
 
5
14
  ## 0.7.24
@@ -1 +1 @@
1
- {"version":3,"file":"path-items.d.ts","sourceRoot":"","sources":["../../src/helpers/path-items.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AAExD,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,SAAS,CAAA;AAY9C,KAAK,WAAW,GAAG,KAAK,GAAG,KAAK,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,GAAG,OAAO,CAAA;AAE7F,eAAO,MAAM,8BAA8B,2BAA2B,CAAA;AACtE,eAAO,MAAM,qCAAqC,kCAAkC,CAAA;AACpF,eAAO,MAAM,uCAAuC,oCAAoC,CAAA;AAIxF,eAAO,MAAM,iCAAiC,8BAA8B,CAAA;AAE5E;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG;IACxB,SAAS,EAAE,MAAM,CAAA;IACjB,MAAM,CAAC,EAAE,WAAW,CAAC,YAAY,CAAA;IACjC,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,WAAW,CAAA;CACpB,CAAA;AAED,KAAK,wBAAwB,GAAG,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;AAoB3D;;;;;GAKG;AACH,wBAAgB,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AM,CAAA;IACZ,MAAM,EAAE,WAAW,CAAA;CACpB,CAAA;AAED,KAAK,wBAAwB,GAAG,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;AAoB3D;;;;;GAKG;AACH,wBAAgB,WAAW,CACzB,IAAI,EAAE,IAAI,GAAG,SAAS,EACtB,WAAW,GAAE,MAAkB,EAC/B,UAAU,GAAE,MAAM,EAAO,EACzB,UAAU,GAAE,MAAW,EACvB,yBAAyB,GAAE,OAAe,EAC1C,cAAc,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,KAAK,MAAM,GAAG,SAAS,EAC3D,wBAAwB,GAAE,wBAAoC,EAC9D,WAAW,CAAC,EAAE,SAAS,MAAM,EAAE,GAC9B;IACD,KAAK,EAAE,WAAW,CAAC,WAAW,CAAA;IAC9B,UAAU,EAAE,WAAW,CAAC,gBAAgB,CAAA;IACxC,WAAW,EAAE,WAAW,EAAE,CAAA;CAC3B,CAkNA;AAED,wBAAgB,8BAA8B,CAC5C,WAAW,EAAE,MAAM,GAAG,SAAS,GAC9B;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,MAAM,CAAA;CAAE,GAAG,IAAI,CAkCpD"}
@@ -74,7 +74,8 @@ export function processItem(item, exampleName = 'default', parentTags = [], pare
74
74
  const sourceRequestName = name?.trim() || exampleName;
75
75
  const operationExampleName = preserveCollapsedVariants ? sourceRequestName : exampleName;
76
76
  const method = (typeof request === 'string' ? 'get' : request.method || 'get').toLowerCase();
77
- const requestUrl = typeof request === 'string' ? request : typeof request.url === 'string' ? request.url : (request.url?.raw ?? '');
77
+ const url = typeof request === 'string' ? request : request.url;
78
+ const requestUrl = typeof url === 'string' ? url : (url?.raw ?? '');
78
79
  const path = extractPathFromUrl(requestUrl);
79
80
  // Normalize path parameters from ':param' to '{param}'
80
81
  const normalizedPath = normalizePath(path);
@@ -92,12 +93,12 @@ export function processItem(item, exampleName = 'default', parentTags = [], pare
92
93
  const pathParameterNames = extractPathParameterNames(normalizedPath);
93
94
  // Extract operation ID if present
94
95
  const { operationId, summary } = extractOperationInfo(name);
95
- const description = typeof request === 'string'
96
- ? ''
97
- : typeof request.description === 'string'
98
- ? request.description
99
- : (request.description?.content ?? '');
100
- const tagName = parentTags.length > 0 ? (resolveTagName ? resolveTagName(parentTags) : parentTags.join(' > ')) : undefined;
96
+ const requestDescription = typeof request === 'string' ? '' : request.description;
97
+ const description = typeof requestDescription === 'string' ? requestDescription : (requestDescription?.content ?? '');
98
+ let tagName;
99
+ if (parentTags.length > 0) {
100
+ tagName = resolveTagName ? resolveTagName(parentTags) : parentTags.join(' > ');
101
+ }
101
102
  // Derive media-type signals from request headers before they are filtered out
102
103
  // of `parameters[in=header]`. Content-Type drives the request body media type;
103
104
  // Accept drives responses when no saved-response Content-Type is available.
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { type ConvertOptions, convert, type PostmanRequestIndexPath, type TagNamingStrategy } from './convert.js';
2
- export { isPostmanCollection } from './is-postman-collection.js';
1
+ export { type ConvertOptions, type PostmanRequestIndexPath, type TagNamingStrategy, convert } from './convert.js';
3
2
  export { extractPathFromUrl, normalizePath } from './helpers/urls.js';
3
+ export { isPostmanCollection } from './is-postman-collection.js';
4
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,cAAc,EAAE,OAAO,EAAE,KAAK,uBAAuB,EAAE,KAAK,iBAAiB,EAAE,MAAM,WAAW,CAAA;AAC9G,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAA;AAC7D,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,cAAc,EAAE,KAAK,uBAAuB,EAAE,KAAK,iBAAiB,EAAE,OAAO,EAAE,MAAM,WAAW,CAAA;AAC9G,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAA;AAClE,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAA"}
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
1
  export { convert } from './convert.js';
2
- export { isPostmanCollection } from './is-postman-collection.js';
3
2
  export { extractPathFromUrl, normalizePath } from './helpers/urls.js';
3
+ export { isPostmanCollection } from './is-postman-collection.js';
package/package.json CHANGED
@@ -19,7 +19,7 @@
19
19
  "export",
20
20
  "scalar"
21
21
  ],
22
- "version": "0.7.25",
22
+ "version": "0.7.27",
23
23
  "engines": {
24
24
  "node": ">=22"
25
25
  },
@@ -38,11 +38,11 @@
38
38
  "CHANGELOG.md"
39
39
  ],
40
40
  "dependencies": {
41
- "@scalar/helpers": "0.16.1",
42
- "@scalar/openapi-types": "0.9.7"
41
+ "@scalar/helpers": "0.16.3",
42
+ "@scalar/openapi-types": "0.9.8"
43
43
  },
44
44
  "devDependencies": {
45
- "@scalar/openapi-parser": "0.29.11",
45
+ "@scalar/openapi-parser": "0.29.13",
46
46
  "@types/node": "^24.1.0",
47
47
  "vite": "8.1.5"
48
48
  },