@scalar/oas-utils 0.4.33 → 0.5.0

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.
Files changed (69) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/dist/entities/cookie/cookie.d.ts +2 -17
  3. package/dist/entities/cookie/cookie.d.ts.map +1 -1
  4. package/dist/entities/environment/environment.d.ts +2 -14
  5. package/dist/entities/environment/environment.d.ts.map +1 -1
  6. package/dist/entities/shared/utility.d.ts +1 -1
  7. package/dist/entities/shared/utility.d.ts.map +1 -1
  8. package/dist/entities/spec/collection.d.ts +76 -501
  9. package/dist/entities/spec/collection.d.ts.map +1 -1
  10. package/dist/entities/spec/operation.d.ts +60 -290
  11. package/dist/entities/spec/operation.d.ts.map +1 -1
  12. package/dist/entities/spec/parameters.d.ts +33 -50
  13. package/dist/entities/spec/parameters.d.ts.map +1 -1
  14. package/dist/entities/spec/request-examples.d.ts +161 -998
  15. package/dist/entities/spec/request-examples.d.ts.map +1 -1
  16. package/dist/entities/spec/request-examples.js +11 -6
  17. package/dist/entities/spec/request-examples.js.map +2 -2
  18. package/dist/entities/spec/requests.d.ts +102 -595
  19. package/dist/entities/spec/requests.d.ts.map +1 -1
  20. package/dist/entities/spec/server.d.ts +12 -156
  21. package/dist/entities/spec/server.d.ts.map +1 -1
  22. package/dist/entities/spec/spec-objects.d.ts +37 -229
  23. package/dist/entities/spec/spec-objects.d.ts.map +1 -1
  24. package/dist/entities/spec/x-scalar-environments.d.ts +8 -56
  25. package/dist/entities/spec/x-scalar-environments.d.ts.map +1 -1
  26. package/dist/entities/spec/x-scalar-secrets.d.ts +2 -14
  27. package/dist/entities/spec/x-scalar-secrets.d.ts.map +1 -1
  28. package/dist/entities/workspace/workspace.d.ts +218 -98
  29. package/dist/entities/workspace/workspace.d.ts.map +1 -1
  30. package/dist/entities/workspace/workspace.js +4 -5
  31. package/dist/entities/workspace/workspace.js.map +2 -2
  32. package/dist/helpers/parse.js +1 -1
  33. package/dist/helpers/parse.js.map +2 -2
  34. package/dist/helpers/schema-model.d.ts +3 -3
  35. package/dist/helpers/schema-model.d.ts.map +1 -1
  36. package/dist/helpers/schema-model.js.map +1 -1
  37. package/dist/helpers/security/get-schemes.d.ts +27 -27
  38. package/dist/helpers/security/get-schemes.d.ts.map +1 -1
  39. package/dist/migrations/v-2.5.0/migration.d.ts.map +1 -1
  40. package/dist/migrations/v-2.5.0/migration.js.map +2 -2
  41. package/dist/spec-getters/get-example-from-schema.d.ts +26 -23
  42. package/dist/spec-getters/get-example-from-schema.d.ts.map +1 -1
  43. package/dist/spec-getters/get-example-from-schema.js +330 -174
  44. package/dist/spec-getters/get-example-from-schema.js.map +2 -2
  45. package/package.json +9 -9
  46. package/dist/helpers/operation-to-har/index.d.ts +0 -2
  47. package/dist/helpers/operation-to-har/index.d.ts.map +0 -1
  48. package/dist/helpers/operation-to-har/index.js +0 -5
  49. package/dist/helpers/operation-to-har/index.js.map +0 -7
  50. package/dist/helpers/operation-to-har/operation-to-har.d.ts +0 -49
  51. package/dist/helpers/operation-to-har/operation-to-har.d.ts.map +0 -1
  52. package/dist/helpers/operation-to-har/operation-to-har.js +0 -68
  53. package/dist/helpers/operation-to-har/operation-to-har.js.map +0 -7
  54. package/dist/helpers/operation-to-har/process-body.d.ts +0 -12
  55. package/dist/helpers/operation-to-har/process-body.d.ts.map +0 -1
  56. package/dist/helpers/operation-to-har/process-body.js +0 -80
  57. package/dist/helpers/operation-to-har/process-body.js.map +0 -7
  58. package/dist/helpers/operation-to-har/process-parameters.d.ts +0 -19
  59. package/dist/helpers/operation-to-har/process-parameters.d.ts.map +0 -1
  60. package/dist/helpers/operation-to-har/process-parameters.js +0 -261
  61. package/dist/helpers/operation-to-har/process-parameters.js.map +0 -7
  62. package/dist/helpers/operation-to-har/process-security-schemes.d.ts +0 -15
  63. package/dist/helpers/operation-to-har/process-security-schemes.d.ts.map +0 -1
  64. package/dist/helpers/operation-to-har/process-security-schemes.js +0 -62
  65. package/dist/helpers/operation-to-har/process-security-schemes.js.map +0 -7
  66. package/dist/helpers/operation-to-har/process-server-url.d.ts +0 -6
  67. package/dist/helpers/operation-to-har/process-server-url.d.ts.map +0 -1
  68. package/dist/helpers/operation-to-har/process-server-url.js +0 -27
  69. package/dist/helpers/operation-to-har/process-server-url.js.map +0 -7
package/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
  # @scalar/oas-utils
2
2
 
3
+ ## 0.5.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 008a0f3: feat: migrate to Zod 4
8
+
9
+ ### Patch Changes
10
+
11
+ - f833196: fix: performance issues on references
12
+ - Updated dependencies [008a0f3]
13
+ - @scalar/openapi-types@0.4.0
14
+ - @scalar/types@0.3.0
15
+ - @scalar/themes@0.13.20
16
+ - @scalar/workspace-store@0.16.2
17
+
18
+ ## 0.4.34
19
+
20
+ ### Patch Changes
21
+
22
+ - Updated dependencies [2b98503]
23
+ - Updated dependencies [c6736fd]
24
+ - Updated dependencies [4951456]
25
+ - @scalar/workspace-store@0.16.1
26
+ - @scalar/json-magic@0.6.0
27
+
3
28
  ## 0.4.33
4
29
 
5
30
  ### Patch Changes
@@ -1,26 +1,11 @@
1
1
  import { z } from 'zod';
2
2
  export declare const cookieSchema: z.ZodObject<{
3
- uid: z.ZodBranded<z.ZodDefault<z.ZodOptional<z.ZodString>>, "cookie">;
4
- /** Defines the cookie name and its value. A cookie definition begins with a name-value pair. */
3
+ uid: z.core.$ZodBranded<z.ZodDefault<z.ZodOptional<z.ZodString>>, "cookie">;
5
4
  name: z.ZodDefault<z.ZodString>;
6
5
  value: z.ZodDefault<z.ZodString>;
7
- /** Defines the host to which the cookie will be sent. */
8
6
  domain: z.ZodOptional<z.ZodString>;
9
- /** Indicates the path that must exist in the requested URL for the browser to send the Cookie header. */
10
7
  path: z.ZodOptional<z.ZodString>;
11
- }, "strip", z.ZodTypeAny, {
12
- uid: string & z.BRAND<"cookie">;
13
- name: string;
14
- value: string;
15
- domain?: string | undefined;
16
- path?: string | undefined;
17
- }, {
18
- uid?: string | undefined;
19
- name?: string | undefined;
20
- value?: string | undefined;
21
- domain?: string | undefined;
22
- path?: string | undefined;
23
- }>;
8
+ }, z.core.$strip>;
24
9
  /**
25
10
  * Cookies
26
11
  *
@@ -1 +1 @@
1
- {"version":3,"file":"cookie.d.ts","sourceRoot":"","sources":["../../../src/entities/cookie/cookie.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,YAAY;;IAEvB,kGAAkG;;;IAGlG,yDAAyD;;IAEzD,yGAAyG;;;;;;;;;;;;;;EAEzG,CAAA;AAEF;;;;GAIG;AACH,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAA"}
1
+ {"version":3,"file":"cookie.d.ts","sourceRoot":"","sources":["../../../src/entities/cookie/cookie.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,YAAY;;;;;;iBASvB,CAAA;AAEF;;;;GAIG;AACH,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAA"}
@@ -1,23 +1,11 @@
1
1
  import { z } from 'zod';
2
2
  export declare const environmentSchema: z.ZodObject<{
3
- uid: z.ZodBranded<z.ZodString, "environment">;
3
+ uid: z.core.$ZodBranded<z.ZodString, "environment">;
4
4
  name: z.ZodDefault<z.ZodOptional<z.ZodString>>;
5
5
  color: z.ZodDefault<z.ZodOptional<z.ZodString>>;
6
6
  value: z.ZodDefault<z.ZodString>;
7
7
  isDefault: z.ZodOptional<z.ZodBoolean>;
8
- }, "strip", z.ZodTypeAny, {
9
- uid: string & z.BRAND<"environment">;
10
- name: string;
11
- value: string;
12
- color: string;
13
- isDefault?: boolean | undefined;
14
- }, {
15
- uid: string;
16
- name?: string | undefined;
17
- value?: string | undefined;
18
- color?: string | undefined;
19
- isDefault?: boolean | undefined;
20
- }>;
8
+ }, z.core.$strip>;
21
9
  /** Environment */
22
10
  export type Environment = z.infer<typeof environmentSchema>;
23
11
  export type EnvironmentPayload = z.input<typeof environmentSchema>;
@@ -1 +1 @@
1
- {"version":3,"file":"environment.d.ts","sourceRoot":"","sources":["../../../src/entities/environment/environment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;EAM5B,CAAA;AAEF,kBAAkB;AAClB,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAC3D,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA"}
1
+ {"version":3,"file":"environment.d.ts","sourceRoot":"","sources":["../../../src/entities/environment/environment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,iBAAiB;;;;;;iBAM5B,CAAA;AAEF,kBAAkB;AAClB,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA;AAC3D,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAA"}
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
2
  /** Schema for selectedSecuritySchemeUids */
3
- export declare const selectedSecuritySchemeUidSchema: z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodBranded<z.ZodString, "securityScheme">, z.ZodArray<z.ZodBranded<z.ZodString, "securityScheme">, "many">]>, "many">>;
3
+ export declare const selectedSecuritySchemeUidSchema: z.ZodDefault<z.ZodArray<z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "securityScheme">, z.ZodArray<z.core.$ZodBranded<z.ZodString, "securityScheme">>]>>>;
4
4
  export type SelectedSecuritySchemeUids = z.infer<typeof selectedSecuritySchemeUidSchema>;
5
5
  //# sourceMappingURL=utility.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"utility.d.ts","sourceRoot":"","sources":["../../../src/entities/shared/utility.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,4CAA4C;AAC5C,eAAO,MAAM,+BAA+B,8JAM9B,CAAA;AAEd,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAA"}
1
+ {"version":3,"file":"utility.d.ts","sourceRoot":"","sources":["../../../src/entities/shared/utility.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,4CAA4C;AAC5C,eAAO,MAAM,+BAA+B,mKAM9B,CAAA;AAEd,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAA"}