@scalar/schemas 0.14.0 → 0.16.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.
- package/CHANGELOG.md +16 -0
- package/dist/api-reference/api-reference-configuration.d.ts +6 -3
- package/dist/api-reference/api-reference-configuration.d.ts.map +1 -1
- package/dist/api-reference/api-reference-configuration.js +4 -1
- package/dist/api-reference/base-configuration.d.ts +1 -1
- package/dist/api-reference/base-configuration.d.ts.map +1 -1
- package/dist/api-reference/base-configuration.js +1 -0
- package/dist/openapi/3.1/callback.js +2 -2
- package/dist/openapi/3.1/components.js +11 -11
- package/dist/openapi/3.1/document.js +8 -8
- package/dist/openapi/3.1/info.js +2 -2
- package/dist/openapi/3.1/link.js +1 -1
- package/dist/openapi/3.1/media-type.js +3 -3
- package/dist/openapi/3.1/operation.js +8 -8
- package/dist/openapi/3.1/parameter.js +4 -4
- package/dist/openapi/3.1/path-item.js +4 -4
- package/dist/openapi/3.1/request-body.js +1 -1
- package/dist/openapi/3.1/response.js +3 -3
- package/dist/openapi/3.1/schema.js +4 -4
- package/dist/openapi/3.1/server.js +1 -1
- package/dist/openapi/3.1/tag.js +1 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @scalar/schemas
|
|
2
2
|
|
|
3
|
+
## 0.16.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#10781](https://github.com/scalar/scalar/pull/10781): feat: add a Halloween theme preset with a moonlit sky, bats, and pumpkin accents
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- [#10767](https://github.com/scalar/scalar/pull/10767): Declare `@scalar/types` as a dependency, since the API reference configuration schema imports it at runtime and installs without hoisting failed to resolve it.
|
|
12
|
+
|
|
13
|
+
## 0.15.0
|
|
14
|
+
|
|
15
|
+
### Minor Changes
|
|
16
|
+
|
|
17
|
+
- [#10697](https://github.com/scalar/scalar/pull/10697): Add `urlRouting: false` to keep API reference navigation in internal state without reading or changing the host page URL.
|
|
18
|
+
|
|
3
19
|
## 0.14.0
|
|
4
20
|
|
|
5
21
|
### Minor Changes
|
|
@@ -14,7 +14,7 @@ export declare const apiReferenceConfigurationSchema: import("@scalar/validation
|
|
|
14
14
|
showDeveloperTools: import("@scalar/validation").UnionSchema<readonly [LiteralSchema<"localhost">, LiteralSchema<"always">, LiteralSchema<"never">]>;
|
|
15
15
|
showToolbar: import("@scalar/validation").UnionSchema<readonly [LiteralSchema<"localhost">, LiteralSchema<"always">, LiteralSchema<"never">]>;
|
|
16
16
|
operationTitleSource: import("@scalar/validation").UnionSchema<readonly [LiteralSchema<"summary">, LiteralSchema<"path">]>;
|
|
17
|
-
theme: import("@scalar/validation").UnionSchema<readonly [LiteralSchema<"default">, LiteralSchema<"alternate">, LiteralSchema<"moon">, LiteralSchema<"purple">, LiteralSchema<"solarized">, LiteralSchema<"bluePlanet">, LiteralSchema<"deepSpace">, LiteralSchema<"saturn">, LiteralSchema<"kepler">, LiteralSchema<"elysiajs">, LiteralSchema<"fastify">, LiteralSchema<"mars">, LiteralSchema<"laserwave">, LiteralSchema<"none">]>;
|
|
17
|
+
theme: import("@scalar/validation").UnionSchema<readonly [LiteralSchema<"default">, LiteralSchema<"alternate">, LiteralSchema<"moon">, LiteralSchema<"purple">, LiteralSchema<"solarized">, LiteralSchema<"bluePlanet">, LiteralSchema<"deepSpace">, LiteralSchema<"saturn">, LiteralSchema<"kepler">, LiteralSchema<"elysiajs">, LiteralSchema<"fastify">, LiteralSchema<"mars">, LiteralSchema<"laserwave">, LiteralSchema<"halloween">, LiteralSchema<"none">]>;
|
|
18
18
|
_integration: import("@scalar/validation").OptionalSchema<import("@scalar/validation").UnionSchema<readonly [LiteralSchema<"adonisjs">, LiteralSchema<"astro">, LiteralSchema<"docusaurus">, LiteralSchema<"dotnet">, LiteralSchema<"elysiajs">, LiteralSchema<"express">, LiteralSchema<"fastapi">, LiteralSchema<"fastify">, LiteralSchema<"go">, LiteralSchema<"hono">, LiteralSchema<"html">, LiteralSchema<"laravel">, LiteralSchema<"litestar">, LiteralSchema<"nestjs">, LiteralSchema<"nextjs">, LiteralSchema<"nitro">, LiteralSchema<"nuxt">, LiteralSchema<"platformatic">, LiteralSchema<"react">, LiteralSchema<"rust">, LiteralSchema<"svelte">, LiteralSchema<"vue">, import("@scalar/validation").NullableSchema]>>;
|
|
19
19
|
onRequestSent: import("@scalar/validation").OptionalSchema<import("@scalar/validation").FunctionSchema<(input: string) => void>>;
|
|
20
20
|
persistAuth: import("@scalar/validation").BooleanSchema;
|
|
@@ -134,6 +134,7 @@ export declare const apiReferenceConfigurationSchema: import("@scalar/validation
|
|
|
134
134
|
}) => Response | void | Promise<Response | void>>>;
|
|
135
135
|
onShowMore: import("@scalar/validation").OptionalSchema<import("@scalar/validation").FunctionSchema<(tagId: string) => Promise<void> | void>>;
|
|
136
136
|
onSidebarClick: import("@scalar/validation").OptionalSchema<import("@scalar/validation").FunctionSchema<(href: string) => Promise<void> | void>>;
|
|
137
|
+
urlRouting: import("@scalar/validation").OptionalSchema<import("@scalar/validation").BooleanSchema>;
|
|
137
138
|
pathRouting: import("@scalar/validation").OptionalSchema<import("@scalar/validation").ObjectSchema<{
|
|
138
139
|
basePath: import("@scalar/validation").StringSchema;
|
|
139
140
|
}>>;
|
|
@@ -189,7 +190,7 @@ export declare const apiReferenceConfigurationWithSourceSchema: (rawInput: unkno
|
|
|
189
190
|
showDeveloperTools: "localhost" | "always" | "never";
|
|
190
191
|
showToolbar: "localhost" | "always" | "never";
|
|
191
192
|
operationTitleSource: "summary" | "path";
|
|
192
|
-
theme: "default" | "alternate" | "moon" | "purple" | "solarized" | "bluePlanet" | "deepSpace" | "saturn" | "kepler" | "elysiajs" | "fastify" | "mars" | "laserwave" | "none";
|
|
193
|
+
theme: "default" | "alternate" | "moon" | "purple" | "solarized" | "bluePlanet" | "deepSpace" | "saturn" | "kepler" | "elysiajs" | "fastify" | "mars" | "laserwave" | "halloween" | "none";
|
|
193
194
|
persistAuth: boolean;
|
|
194
195
|
telemetry: boolean;
|
|
195
196
|
externalUrls: {
|
|
@@ -331,6 +332,7 @@ export declare const apiReferenceConfigurationWithSourceSchema: (rawInput: unkno
|
|
|
331
332
|
}) => Response | void | Promise<Response | void>) | undefined;
|
|
332
333
|
onShowMore?: ((tagId: string) => Promise<void> | void) | undefined;
|
|
333
334
|
onSidebarClick?: ((href: string) => Promise<void> | void) | undefined;
|
|
335
|
+
urlRouting?: boolean | undefined;
|
|
334
336
|
pathRouting?: {
|
|
335
337
|
basePath: string;
|
|
336
338
|
} | undefined;
|
|
@@ -374,7 +376,7 @@ export declare const apiReferenceConfigurationWithSourceSchema: (rawInput: unkno
|
|
|
374
376
|
showDeveloperTools: "localhost" | "always" | "never";
|
|
375
377
|
showToolbar: "localhost" | "always" | "never";
|
|
376
378
|
operationTitleSource: "summary" | "path";
|
|
377
|
-
theme: "default" | "alternate" | "moon" | "purple" | "solarized" | "bluePlanet" | "deepSpace" | "saturn" | "kepler" | "elysiajs" | "fastify" | "mars" | "laserwave" | "none";
|
|
379
|
+
theme: "default" | "alternate" | "moon" | "purple" | "solarized" | "bluePlanet" | "deepSpace" | "saturn" | "kepler" | "elysiajs" | "fastify" | "mars" | "laserwave" | "halloween" | "none";
|
|
378
380
|
persistAuth: boolean;
|
|
379
381
|
telemetry: boolean;
|
|
380
382
|
externalUrls: {
|
|
@@ -516,6 +518,7 @@ export declare const apiReferenceConfigurationWithSourceSchema: (rawInput: unkno
|
|
|
516
518
|
}) => Response | void | Promise<Response | void>) | undefined;
|
|
517
519
|
onShowMore?: ((tagId: string) => Promise<void> | void) | undefined;
|
|
518
520
|
onSidebarClick?: ((href: string) => Promise<void> | void) | undefined;
|
|
521
|
+
urlRouting?: boolean | undefined;
|
|
519
522
|
pathRouting?: {
|
|
520
523
|
basePath: string;
|
|
521
524
|
} | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api-reference-configuration.d.ts","sourceRoot":"","sources":["../../src/api-reference/api-reference-configuration.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAmB,QAAQ,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAA;AACjF,OAAO,EACL,KAAK,aAAa,EAenB,MAAM,oBAAoB,CAAA;AAO3B,eAAO,MAAM,+BAA+B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAwBvC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;mBAgGoC,aAAa,CAAC,QAAQ,CAAC;mBACvB,aAAa,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;;;;oHAYnC,MAAM,KAAK,IAAI;oHAGf,IAAI;6GAGX,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI;qHAKhD;QACN,OAAO,EAAE,OAAO,CAAA;QAChB,cAAc,EAAE,OAAO,CAAA;QACvB,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;KACrC,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI;oHASlB;QACN,OAAO,EAAE,OAAO,CAAA;QAChB,cAAc,EAAE,OAAO,CAAA;QACvB,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;KACrC,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI;wHAQjB;QAAE,QAAQ,EAAE,QAAQ,CAAC;QAAC,OAAO,EAAE,OAAO,CAAA;KAAE,KAAK,QAAQ,GAAG,IAAI,GAAG,OAAO,CAAC,QAAQ,GAAG,IAAI,CAAC;gHAKpE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI;mHAG5B,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI
|
|
1
|
+
{"version":3,"file":"api-reference-configuration.d.ts","sourceR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AAE,KAAK,EAAE,MAAM,CAAC;YAAC,IAAI,EAAE,MAAM,CAAA;SAAE,CAAA;KAAE,KAAK,MAAM;wBAG3E,MAAM,KAAK,MAAM,GAAG,IAAI,GAAG,SAAS;gCA2Cb,GAAG,KAAK,GAAG,KAAK,MAAM;iDAGG,GAAG,KAAK,GAAG,KAAK,MAAM;kBA6FvG,CAAA"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DEFAULT_MODELS_SECTION_LABEL } from '@scalar/types/api-reference';
|
|
2
2
|
import { any, array, boolean, coerce, evaluate, fn, intersection, literal, number, object, optional, record, string, union, } from '@scalar/validation';
|
|
3
|
-
import { apiReferencePluginSchema } from '
|
|
3
|
+
import { apiReferencePluginSchema } from './api-reference-plugin.js';
|
|
4
4
|
import { baseConfigurationSchema } from './base-configuration.js';
|
|
5
5
|
import { sourceConfigurationSchema } from './source-configuration.js';
|
|
6
6
|
export const apiReferenceConfigurationSchema = intersection([
|
|
@@ -141,6 +141,9 @@ export const apiReferenceConfigurationSchema = intersection([
|
|
|
141
141
|
onSidebarClick: optional(fn(), {
|
|
142
142
|
typeComment: 'onSidebarClick is fired when the user clicks on a sidebar item',
|
|
143
143
|
}),
|
|
144
|
+
urlRouting: optional(boolean(), {
|
|
145
|
+
typeComment: 'Sync navigation with the browser URL. Set to false for embedded references that must leave the host URL and history alone. Defaults to true.',
|
|
146
|
+
}),
|
|
144
147
|
pathRouting: optional(object({
|
|
145
148
|
basePath: string(),
|
|
146
149
|
}), {
|
|
@@ -12,7 +12,7 @@ export declare const baseConfigurationSchema: import("@scalar/validation").Objec
|
|
|
12
12
|
showDeveloperTools: import("@scalar/validation").UnionSchema<readonly [import("@scalar/validation").LiteralSchema<"localhost">, import("@scalar/validation").LiteralSchema<"always">, import("@scalar/validation").LiteralSchema<"never">]>;
|
|
13
13
|
showToolbar: import("@scalar/validation").UnionSchema<readonly [import("@scalar/validation").LiteralSchema<"localhost">, import("@scalar/validation").LiteralSchema<"always">, import("@scalar/validation").LiteralSchema<"never">]>;
|
|
14
14
|
operationTitleSource: import("@scalar/validation").UnionSchema<readonly [import("@scalar/validation").LiteralSchema<"summary">, import("@scalar/validation").LiteralSchema<"path">]>;
|
|
15
|
-
theme: import("@scalar/validation").UnionSchema<readonly [import("@scalar/validation").LiteralSchema<"default">, import("@scalar/validation").LiteralSchema<"alternate">, import("@scalar/validation").LiteralSchema<"moon">, import("@scalar/validation").LiteralSchema<"purple">, import("@scalar/validation").LiteralSchema<"solarized">, import("@scalar/validation").LiteralSchema<"bluePlanet">, import("@scalar/validation").LiteralSchema<"deepSpace">, import("@scalar/validation").LiteralSchema<"saturn">, import("@scalar/validation").LiteralSchema<"kepler">, import("@scalar/validation").LiteralSchema<"elysiajs">, import("@scalar/validation").LiteralSchema<"fastify">, import("@scalar/validation").LiteralSchema<"mars">, import("@scalar/validation").LiteralSchema<"laserwave">, import("@scalar/validation").LiteralSchema<"none">]>;
|
|
15
|
+
theme: import("@scalar/validation").UnionSchema<readonly [import("@scalar/validation").LiteralSchema<"default">, import("@scalar/validation").LiteralSchema<"alternate">, import("@scalar/validation").LiteralSchema<"moon">, import("@scalar/validation").LiteralSchema<"purple">, import("@scalar/validation").LiteralSchema<"solarized">, import("@scalar/validation").LiteralSchema<"bluePlanet">, import("@scalar/validation").LiteralSchema<"deepSpace">, import("@scalar/validation").LiteralSchema<"saturn">, import("@scalar/validation").LiteralSchema<"kepler">, import("@scalar/validation").LiteralSchema<"elysiajs">, import("@scalar/validation").LiteralSchema<"fastify">, import("@scalar/validation").LiteralSchema<"mars">, import("@scalar/validation").LiteralSchema<"laserwave">, import("@scalar/validation").LiteralSchema<"halloween">, import("@scalar/validation").LiteralSchema<"none">]>;
|
|
16
16
|
_integration: import("@scalar/validation").OptionalSchema<import("@scalar/validation").UnionSchema<readonly [import("@scalar/validation").LiteralSchema<"adonisjs">, import("@scalar/validation").LiteralSchema<"astro">, import("@scalar/validation").LiteralSchema<"docusaurus">, import("@scalar/validation").LiteralSchema<"dotnet">, import("@scalar/validation").LiteralSchema<"elysiajs">, import("@scalar/validation").LiteralSchema<"express">, import("@scalar/validation").LiteralSchema<"fastapi">, import("@scalar/validation").LiteralSchema<"fastify">, import("@scalar/validation").LiteralSchema<"go">, import("@scalar/validation").LiteralSchema<"hono">, import("@scalar/validation").LiteralSchema<"html">, import("@scalar/validation").LiteralSchema<"laravel">, import("@scalar/validation").LiteralSchema<"litestar">, import("@scalar/validation").LiteralSchema<"nestjs">, import("@scalar/validation").LiteralSchema<"nextjs">, import("@scalar/validation").LiteralSchema<"nitro">, import("@scalar/validation").LiteralSchema<"nuxt">, import("@scalar/validation").LiteralSchema<"platformatic">, import("@scalar/validation").LiteralSchema<"react">, import("@scalar/validation").LiteralSchema<"rust">, import("@scalar/validation").LiteralSchema<"svelte">, import("@scalar/validation").LiteralSchema<"vue">, import("@scalar/validation").NullableSchema]>>;
|
|
17
17
|
onRequestSent: import("@scalar/validation").OptionalSchema<import("@scalar/validation").FunctionSchema<(input: string) => void>>;
|
|
18
18
|
persistAuth: import("@scalar/validation").BooleanSchema;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-configuration.d.ts","sourceRoot":"","sources":["../../src/api-reference/base-configuration.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"base-configuration.d.ts","sourceRoot":"","sources":["../../src/api-reference/base-configuration.ts"],"names":[],"mappings":"AAcA,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;mHA6HC,MAAM,KAAK,IAAI;;;;;;;;;EAYlD,CAAA"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { lazy, record, string } from '@scalar/validation';
|
|
2
|
-
import { pathItem } from '
|
|
3
|
-
import { recursiveRef } from '
|
|
2
|
+
import { pathItem } from './path-item.js';
|
|
3
|
+
import { recursiveRef } from './reference.js';
|
|
4
4
|
export const callback = record(string(), recursiveRef(lazy(() => pathItem)), {
|
|
5
5
|
typeName: 'CallbackObject',
|
|
6
6
|
});
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { lazy, object, optional, record, string } from '@scalar/validation';
|
|
2
|
-
import { callback } from '
|
|
3
|
-
import { example } from '
|
|
4
|
-
import { link } from '
|
|
5
|
-
import { header } from '
|
|
6
|
-
import { parameter } from '
|
|
7
|
-
import { pathItem } from '
|
|
8
|
-
import { normalRef, recursiveRef } from '
|
|
9
|
-
import { requestBody } from '
|
|
10
|
-
import { response } from '
|
|
11
|
-
import { schema } from '
|
|
12
|
-
import { securityScheme } from '
|
|
2
|
+
import { callback } from './callback.js';
|
|
3
|
+
import { example } from './example.js';
|
|
4
|
+
import { link } from './link.js';
|
|
5
|
+
import { header } from './media-type.js';
|
|
6
|
+
import { parameter } from './parameter.js';
|
|
7
|
+
import { pathItem } from './path-item.js';
|
|
8
|
+
import { normalRef, recursiveRef } from './reference.js';
|
|
9
|
+
import { requestBody } from './request-body.js';
|
|
10
|
+
import { response } from './response.js';
|
|
11
|
+
import { schema } from './schema.js';
|
|
12
|
+
import { securityScheme } from './security-schemes.js';
|
|
13
13
|
export const components = lazy(() => object({
|
|
14
14
|
schemas: optional(record(string(), normalRef(schema), { typeName: 'ComponentsSchemas' })),
|
|
15
15
|
responses: optional(record(string(), recursiveRef(lazy(() => response)), { typeName: 'ComponentsResponses' })),
|
|
@@ -3,14 +3,14 @@ import { XOriginalOasVersion, XScalarEnvironments, XScalarIcon, XScalarIsDirty,
|
|
|
3
3
|
import { XPostResponse, XPreRequest, XScalarActiveEnvironment, XScalarCookies, XScalarOrder, } from '../../extensions/general/index.js';
|
|
4
4
|
import { XScalarSelectedServer } from '../../extensions/server/index.js';
|
|
5
5
|
import { XTagGroups } from '../../extensions/tag/index.js';
|
|
6
|
-
import { components } from '
|
|
7
|
-
import { externalDocs } from '
|
|
8
|
-
import { info } from '
|
|
9
|
-
import { pathItem } from '
|
|
10
|
-
import { recursiveRef } from '
|
|
11
|
-
import { securityRequirement } from '
|
|
12
|
-
import { server } from '
|
|
13
|
-
import { tag } from '
|
|
6
|
+
import { components } from './components.js';
|
|
7
|
+
import { externalDocs } from './external-docs.js';
|
|
8
|
+
import { info } from './info.js';
|
|
9
|
+
import { pathItem } from './path-item.js';
|
|
10
|
+
import { recursiveRef } from './reference.js';
|
|
11
|
+
import { securityRequirement } from './security-requirement.js';
|
|
12
|
+
import { server } from './server.js';
|
|
13
|
+
import { tag } from './tag.js';
|
|
14
14
|
const openapiExtensions = intersection([
|
|
15
15
|
XOriginalOasVersion,
|
|
16
16
|
XScalarNavigation,
|
package/dist/openapi/3.1/info.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { intersection, object, optional, string } from '@scalar/validation';
|
|
2
2
|
import { XScalarLinks, XScalarSdkInstallation } from '../../extensions/document/index.js';
|
|
3
|
-
import { contact } from '
|
|
4
|
-
import { license } from '
|
|
3
|
+
import { contact } from './contact.js';
|
|
4
|
+
import { license } from './license.js';
|
|
5
5
|
export const info = intersection([
|
|
6
6
|
object({
|
|
7
7
|
title: string({ typeComment: 'REQUIRED. The title of the API.' }),
|
package/dist/openapi/3.1/link.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { any, object, optional, record, string } from '@scalar/validation';
|
|
2
|
-
import { server } from '
|
|
2
|
+
import { server } from './server.js';
|
|
3
3
|
export const link = object({
|
|
4
4
|
operationRef: optional(string({
|
|
5
5
|
typeComment: 'A URI reference to an OAS operation. This field is mutually exclusive of the operationId field, and MUST point to an Operation Object.',
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { any, boolean, intersection, lazy, object, optional, record, string, union, } from '@scalar/validation';
|
|
2
|
-
import { example } from '
|
|
3
|
-
import { normalRef, recursiveRef } from '
|
|
4
|
-
import { schema } from '
|
|
2
|
+
import { example } from './example.js';
|
|
3
|
+
import { normalRef, recursiveRef } from './reference.js';
|
|
4
|
+
import { schema } from './schema.js';
|
|
5
5
|
const headerBase = object({
|
|
6
6
|
description: optional(string({
|
|
7
7
|
typeComment: 'A brief description of the header. This could contain examples of use. CommonMark syntax MAY be used for rich text representation.',
|
|
@@ -3,14 +3,14 @@ import { XInternal, XScalarIgnore } from '../../extensions/document/index.js';
|
|
|
3
3
|
import { XPostResponse, XPreRequest } from '../../extensions/general/index.js';
|
|
4
4
|
import { XBadges, XCodeSamples, XDraftExamples, XScalarDisableParameters, XScalarStability, } from '../../extensions/operation/index.js';
|
|
5
5
|
import { XScalarSelectedServer } from '../../extensions/server/index.js';
|
|
6
|
-
import { callback } from '
|
|
7
|
-
import { externalDocs } from '
|
|
8
|
-
import { parameter } from '
|
|
9
|
-
import { recursiveRef } from '
|
|
10
|
-
import { requestBody } from '
|
|
11
|
-
import { responsesObject } from '
|
|
12
|
-
import { securityRequirement } from '
|
|
13
|
-
import { server } from '
|
|
6
|
+
import { callback } from './callback.js';
|
|
7
|
+
import { externalDocs } from './external-docs.js';
|
|
8
|
+
import { parameter } from './parameter.js';
|
|
9
|
+
import { recursiveRef } from './reference.js';
|
|
10
|
+
import { requestBody } from './request-body.js';
|
|
11
|
+
import { responsesObject } from './response.js';
|
|
12
|
+
import { securityRequirement } from './security-requirement.js';
|
|
13
|
+
import { server } from './server.js';
|
|
14
14
|
export const operation = intersection([
|
|
15
15
|
object({
|
|
16
16
|
tags: optional(array(string(), {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { any, boolean, intersection, lazy, literal, object, optional, record, string, union } from '@scalar/validation';
|
|
2
2
|
import { XInternal, XScalarIgnore } from '../../extensions/document/index.js';
|
|
3
3
|
import { XGlobal } from '../../extensions/parameter/index.js';
|
|
4
|
-
import { example } from '
|
|
5
|
-
import { mediaType } from '
|
|
6
|
-
import { normalRef, recursiveRef } from '
|
|
7
|
-
import { schema } from '
|
|
4
|
+
import { example } from './example.js';
|
|
5
|
+
import { mediaType } from './media-type.js';
|
|
6
|
+
import { normalRef, recursiveRef } from './reference.js';
|
|
7
|
+
import { schema } from './schema.js';
|
|
8
8
|
const parameterWithSchema = intersection([
|
|
9
9
|
object({
|
|
10
10
|
name: string({
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { array, lazy, object, optional, string } from '@scalar/validation';
|
|
2
|
-
import { operation } from '
|
|
3
|
-
import { parameter } from '
|
|
4
|
-
import { recursiveRef } from '
|
|
5
|
-
import { server } from '
|
|
2
|
+
import { operation } from './operation.js';
|
|
3
|
+
import { parameter } from './parameter.js';
|
|
4
|
+
import { recursiveRef } from './reference.js';
|
|
5
|
+
import { server } from './server.js';
|
|
6
6
|
export const pathItem = object({
|
|
7
7
|
$ref: optional(string({
|
|
8
8
|
typeComment: 'Allows for a referenced definition of this path item. The value MUST be in the form of a URI, and the referenced structure MUST be in the form of a Path Item Object.',
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { boolean, intersection, lazy, object, optional, record, string } from '@scalar/validation';
|
|
2
2
|
import { XScalarSelectedContentType } from '../../extensions/operation/index.js';
|
|
3
|
-
import { mediaType } from '
|
|
3
|
+
import { mediaType } from './media-type.js';
|
|
4
4
|
export const requestBody = intersection([
|
|
5
5
|
object({
|
|
6
6
|
description: optional(string({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { lazy, object, optional, record, string } from '@scalar/validation';
|
|
2
|
-
import { link } from '
|
|
3
|
-
import { header, mediaType } from '
|
|
4
|
-
import { recursiveRef } from '
|
|
2
|
+
import { link } from './link.js';
|
|
3
|
+
import { header, mediaType } from './media-type.js';
|
|
4
|
+
import { recursiveRef } from './reference.js';
|
|
5
5
|
export const response = object({
|
|
6
6
|
description: string({
|
|
7
7
|
typeComment: 'REQUIRED. A description of the response. CommonMark syntax MAY be used for rich text representation.',
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { any, array, boolean, intersection, lazy, literal, number, object, optional, record, string, union, } from '@scalar/validation';
|
|
2
2
|
import { XInternal, XScalarIgnore, XTags } from '../../extensions/document/index.js';
|
|
3
3
|
import { XAdditionalPropertiesName, XEnumDescriptions, XEnumVarNames, XExamples, XVariable } from '../../extensions/schema/index.js';
|
|
4
|
-
import { discriminatorObject } from '
|
|
5
|
-
import { externalDocs } from '
|
|
6
|
-
import { normalRef } from '
|
|
7
|
-
import { xml } from '
|
|
4
|
+
import { discriminatorObject } from './discriminator.js';
|
|
5
|
+
import { externalDocs } from './external-docs.js';
|
|
6
|
+
import { normalRef } from './reference.js';
|
|
7
|
+
import { xml } from './xml.js';
|
|
8
8
|
/**
|
|
9
9
|
* Build the shared Schema Object shape, optionally accepting boolean child schemas.
|
|
10
10
|
* AsyncAPI uses JSON Schema booleans recursively; the OpenAPI ingestion pipeline normalizes them first.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { object, optional, record, string } from '@scalar/validation';
|
|
2
|
-
import { serverVariable } from '
|
|
2
|
+
import { serverVariable } from './server-variable.js';
|
|
3
3
|
export const server = object({
|
|
4
4
|
url: string({
|
|
5
5
|
typeComment: 'REQUIRED. A URL to the target host. This URL supports Server Variables and MAY be relative, to indicate that the host location is relative to the location where the document containing the Server Object is being served. Variable substitutions will be made when a variable is named in {braces}.',
|
package/dist/openapi/3.1/tag.js
CHANGED
|
@@ -2,7 +2,7 @@ import { intersection, object, optional, string } from '@scalar/validation';
|
|
|
2
2
|
import { XInternal, XScalarIgnore } from '../../extensions/document/index.js';
|
|
3
3
|
import { XScalarOrder } from '../../extensions/general/index.js';
|
|
4
4
|
import { XDisplayName } from '../../extensions/tag/index.js';
|
|
5
|
-
import { externalDocs } from '
|
|
5
|
+
import { externalDocs } from './external-docs.js';
|
|
6
6
|
export const tag = intersection([
|
|
7
7
|
object({
|
|
8
8
|
name: string({ typeComment: 'REQUIRED. The name of the tag.' }),
|
package/package.json
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"schemas",
|
|
15
15
|
"scalar"
|
|
16
16
|
],
|
|
17
|
-
"version": "0.
|
|
17
|
+
"version": "0.16.0",
|
|
18
18
|
"engines": {
|
|
19
19
|
"node": ">=22"
|
|
20
20
|
},
|
|
@@ -42,11 +42,11 @@
|
|
|
42
42
|
],
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@scalar/helpers": "0.16.4",
|
|
45
|
+
"@scalar/types": "0.26.0",
|
|
45
46
|
"@scalar/validation": "0.6.7"
|
|
46
47
|
},
|
|
47
48
|
"devDependencies": {
|
|
48
|
-
"
|
|
49
|
-
"vitest": "4.1.10"
|
|
49
|
+
"vitest": "4.1.12"
|
|
50
50
|
},
|
|
51
51
|
"scripts": {
|
|
52
52
|
"build": "tsc -p tsconfig.build.json && tsc-alias -p tsconfig.build.json",
|