@scalar/workspace-store 0.57.1 → 0.59.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 +53 -0
- package/dist/entities/auth/schema.d.ts +25 -0
- package/dist/entities/auth/schema.d.ts.map +1 -1
- package/dist/helpers/for-each-path-item-operation.d.ts +10 -0
- package/dist/helpers/for-each-path-item-operation.d.ts.map +1 -1
- package/dist/helpers/for-each-path-item-operation.js +67 -10
- package/dist/helpers/get-resolved-ref.d.ts.map +1 -1
- package/dist/helpers/get-resolved-ref.js +9 -0
- package/dist/mutators/operation/parameters.d.ts.map +1 -1
- package/dist/mutators/operation/parameters.js +6 -1
- package/dist/navigation/get-navigation-options.d.ts.map +1 -1
- package/dist/navigation/get-navigation-options.js +9 -6
- package/dist/navigation/helpers/traverse-tags.d.ts +3 -2
- package/dist/navigation/helpers/traverse-tags.d.ts.map +1 -1
- package/dist/navigation/helpers/traverse-tags.js +140 -18
- package/dist/request-example/builder/body/get-request-body-example.d.ts +12 -0
- package/dist/request-example/builder/body/get-request-body-example.d.ts.map +1 -1
- package/dist/request-example/builder/body/get-request-body-example.js +25 -12
- package/dist/request-example/builder/index.d.ts +1 -1
- package/dist/request-example/builder/index.d.ts.map +1 -1
- package/dist/request-example/builder/index.js +1 -1
- package/dist/request-example/context/get-request-example-context.d.ts.map +1 -1
- package/dist/request-example/context/get-request-example-context.js +12 -7
- package/dist/request-example/index.d.ts +1 -1
- package/dist/request-example/index.d.ts.map +1 -1
- package/dist/request-example/index.js +1 -1
- package/dist/request-example/types.d.ts +3 -0
- package/dist/request-example/types.d.ts.map +1 -1
- package/dist/schemas/navigation.d.ts +16 -2
- package/dist/schemas/navigation.d.ts.map +1 -1
- package/dist/schemas/navigation.js +1 -0
- package/dist/schemas/reference-config/index.d.ts +6 -1
- package/dist/schemas/reference-config/index.d.ts.map +1 -1
- package/dist/schemas/reference-config/settings.d.ts +5 -0
- package/dist/schemas/reference-config/settings.d.ts.map +1 -1
- package/dist/schemas/v3.1/openapi/index.d.ts +3 -0
- package/dist/schemas/v3.1/openapi/index.d.ts.map +1 -1
- package/dist/schemas/v3.1/openapi/index.js +7 -0
- package/dist/schemas/v3.1/strict/openapi-document.d.ts +175 -0
- package/dist/schemas/v3.1/strict/openapi-document.d.ts.map +1 -1
- package/dist/schemas/v3.1/strict/tag.d.ts +12 -0
- package/dist/schemas/v3.1/strict/tag.d.ts.map +1 -1
- package/dist/schemas/v3.1/strict/tag.js +6 -0
- package/dist/schemas/v3.2/strict/openapi-document.d.ts +70 -0
- package/dist/schemas/v3.2/strict/openapi-document.d.ts.map +1 -1
- package/dist/schemas/workspace-specification/index.d.ts +1 -1
- package/dist/schemas/workspace.d.ts +1 -1
- package/dist/server.d.ts +3 -3
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +177 -16
- package/package.json +14 -14
|
@@ -12,14 +12,16 @@ import { getTag } from './get-tag.js';
|
|
|
12
12
|
* @param isGroup - Whether this tag represents a group of tags
|
|
13
13
|
* @returns A traversed tag entry with ID, title, name and children
|
|
14
14
|
*/
|
|
15
|
-
const createTagEntry = ({ tag, generateId, children, isGroup = false, parentId, }) => {
|
|
15
|
+
const createTagEntry = ({ tag, generateId, children, isGroup = false, isTagGroup = false, parentId, }) => {
|
|
16
16
|
const id = generateId({
|
|
17
17
|
type: 'tag',
|
|
18
18
|
tag,
|
|
19
19
|
parentId,
|
|
20
20
|
isGroup,
|
|
21
|
+
isTagGroup,
|
|
21
22
|
});
|
|
22
|
-
|
|
23
|
+
// `summary` is the OpenAPI 3.2 display label; `x-displayName` keeps precedence for backwards compatibility.
|
|
24
|
+
const title = tag['x-displayName'] ?? tag.summary ?? tag.name ?? 'Untitled Tag';
|
|
23
25
|
// Update the order of the children based on the items
|
|
24
26
|
// This will ensure that the sort order is always in sync with the items
|
|
25
27
|
tag['x-scalar-order'] = children.map((child) => child.id);
|
|
@@ -30,6 +32,9 @@ const createTagEntry = ({ tag, generateId, children, isGroup = false, parentId,
|
|
|
30
32
|
description: tag.description,
|
|
31
33
|
children,
|
|
32
34
|
isGroup,
|
|
35
|
+
// Only tag on legacy `x-tagGroups` wrappers so the renderer can flatten them without a header.
|
|
36
|
+
// Real OpenAPI 3.2 nested-tag sections keep this unset and render their summary heading.
|
|
37
|
+
...(isTagGroup ? { isTagGroup: true } : {}),
|
|
33
38
|
isWebhooks: false,
|
|
34
39
|
type: 'tag',
|
|
35
40
|
xKeys: getXKeysFromObject(unpackProxyObject(tag)),
|
|
@@ -101,20 +106,11 @@ const getSortedTagEntries = ({ _keys, tagsMap, options: { tagsSorter, operations
|
|
|
101
106
|
if (sortOrder) {
|
|
102
107
|
return sortByOrder(entries, sortOrder, (item) => item.id);
|
|
103
108
|
}
|
|
104
|
-
// Alpha sort
|
|
109
|
+
// Alpha sort. `title` already resolves the display label (`x-displayName` first, then the
|
|
110
|
+
// OpenAPI 3.2 `summary`, then `name`), so we compare it directly instead of looking the tag up
|
|
111
|
+
// again by title, which would miss real tags and insert stray `tagsMap` entries.
|
|
105
112
|
if (tagsSorter === 'alpha') {
|
|
106
|
-
entries.sort((a, b) =>
|
|
107
|
-
const nameA = getTag({
|
|
108
|
-
tagsMap,
|
|
109
|
-
name: a.title,
|
|
110
|
-
documentId,
|
|
111
|
-
generateId,
|
|
112
|
-
}).tag['x-displayName'] ||
|
|
113
|
-
a.title ||
|
|
114
|
-
'Untitled Tag';
|
|
115
|
-
const nameB = getTag({ tagsMap, name: b.title, documentId, generateId }).tag['x-displayName'] || b.title || 'Untitled Tag';
|
|
116
|
-
return nameA.localeCompare(nameB);
|
|
117
|
-
});
|
|
113
|
+
entries.sort((a, b) => (a.title || 'Untitled Tag').localeCompare(b.title || 'Untitled Tag'));
|
|
118
114
|
}
|
|
119
115
|
// Custom sort
|
|
120
116
|
else if (typeof tagsSorter === 'function') {
|
|
@@ -123,15 +119,140 @@ const getSortedTagEntries = ({ _keys, tagsMap, options: { tagsSorter, operations
|
|
|
123
119
|
return entries;
|
|
124
120
|
};
|
|
125
121
|
/**
|
|
126
|
-
*
|
|
122
|
+
* Maps each tag name to its OpenAPI 3.2 `parent` when that parent resolves to another
|
|
123
|
+
* declared tag. Self-references and parents without a matching tag are ignored.
|
|
124
|
+
*/
|
|
125
|
+
const getParentMap = (tags) => {
|
|
126
|
+
const names = new Set(tags.flatMap((tag) => (typeof tag.name === 'string' ? tag.name : [])));
|
|
127
|
+
const parentOf = new Map();
|
|
128
|
+
for (const tag of tags) {
|
|
129
|
+
if (tag.name && tag.parent && tag.parent !== tag.name && names.has(tag.parent)) {
|
|
130
|
+
parentOf.set(tag.name, tag.parent);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
return parentOf;
|
|
134
|
+
};
|
|
135
|
+
/** A tag is part of a cycle when walking up its parent chain returns to a tag already seen. */
|
|
136
|
+
const isCyclic = (parentOf, name) => {
|
|
137
|
+
const seen = new Set([name]);
|
|
138
|
+
let current = parentOf.get(name);
|
|
139
|
+
while (current) {
|
|
140
|
+
if (seen.has(current)) {
|
|
141
|
+
return true;
|
|
142
|
+
}
|
|
143
|
+
seen.add(current);
|
|
144
|
+
current = parentOf.get(current);
|
|
145
|
+
}
|
|
146
|
+
return false;
|
|
147
|
+
};
|
|
148
|
+
/**
|
|
149
|
+
* Nests tag entries according to the OpenAPI 3.2 `parent` field.
|
|
150
|
+
*
|
|
151
|
+
* Each tag may declare the `name` of another tag it is nested under. We build the flat
|
|
152
|
+
* tag entries first (so operation sorting, hidden-tag filtering and IDs stay identical to
|
|
153
|
+
* the ungrouped path) and then re-parent them by reference. A tag that nests other tags
|
|
154
|
+
* but has no operations of its own is marked as a group so the renderer presents it as a
|
|
155
|
+
* section rather than a leaf.
|
|
156
|
+
*
|
|
157
|
+
* Tags whose `parent` does not resolve to an existing tag, and tags caught in a circular
|
|
158
|
+
* reference (which the spec forbids), are kept at the top level.
|
|
159
|
+
*/
|
|
160
|
+
const nestTagsByParent = ({ flatEntries, document, originalOrders, }) => {
|
|
161
|
+
// Index real tag entries by name and remember which ones owned operations before nesting.
|
|
162
|
+
const entriesByName = new Map();
|
|
163
|
+
const hadOwnOperations = new Map();
|
|
164
|
+
for (const entry of flatEntries) {
|
|
165
|
+
if (entry.type === 'tag') {
|
|
166
|
+
entriesByName.set(entry.name, entry);
|
|
167
|
+
hadOwnOperations.set(entry.name, (entry.children?.length ?? 0) > 0);
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
const parentOf = getParentMap(document.tags ?? []);
|
|
171
|
+
// Re-parent entries by reference, tracking which ones leave the top level.
|
|
172
|
+
const nested = new Set();
|
|
173
|
+
const gainedNestedTags = new Set();
|
|
174
|
+
for (const [name, entry] of entriesByName) {
|
|
175
|
+
const parentName = parentOf.get(name);
|
|
176
|
+
if (parentName === undefined || isCyclic(parentOf, name)) {
|
|
177
|
+
continue;
|
|
178
|
+
}
|
|
179
|
+
const parent = entriesByName.get(parentName);
|
|
180
|
+
if (!parent) {
|
|
181
|
+
continue;
|
|
182
|
+
}
|
|
183
|
+
// Append in place: rebuilding the array on every child is quadratic for wide parents.
|
|
184
|
+
parent.children = parent.children ?? [];
|
|
185
|
+
parent.children.push(entry);
|
|
186
|
+
nested.add(name);
|
|
187
|
+
gainedNestedTags.add(parentName);
|
|
188
|
+
}
|
|
189
|
+
// Nested tags were appended after the parent's own operations, but the parent's persisted
|
|
190
|
+
// `x-scalar-order` was written before nesting and knows nothing about them. Restore any
|
|
191
|
+
// custom order that already references the nested tag ids, then sync the persisted order
|
|
192
|
+
// with the final children so the nested ids are never dropped.
|
|
193
|
+
const tagsByName = new Map();
|
|
194
|
+
for (const tag of document.tags ?? []) {
|
|
195
|
+
if (tag.name) {
|
|
196
|
+
tagsByName.set(tag.name, tag);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
for (const parentName of gainedNestedTags) {
|
|
200
|
+
const parent = entriesByName.get(parentName);
|
|
201
|
+
if (!parent) {
|
|
202
|
+
continue;
|
|
203
|
+
}
|
|
204
|
+
const originalOrder = originalOrders.get(parentName);
|
|
205
|
+
if (originalOrder) {
|
|
206
|
+
parent.children = sortByOrder(parent.children ?? [], originalOrder, (item) => item.id);
|
|
207
|
+
}
|
|
208
|
+
const tag = tagsByName.get(parentName);
|
|
209
|
+
if (tag) {
|
|
210
|
+
tag['x-scalar-order'] = (parent.children ?? []).map((child) => child.id);
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
// A tag that nests other tags but owns no operations is a section, not a leaf.
|
|
214
|
+
for (const [name, entry] of entriesByName) {
|
|
215
|
+
const hasChildTags = (entry.children ?? []).some((child) => child.type === 'tag');
|
|
216
|
+
if (hasChildTags && !hadOwnOperations.get(name)) {
|
|
217
|
+
entry.isGroup = true;
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
return flatEntries.filter((entry) => !(entry.type === 'tag' && nested.has(entry.name)));
|
|
221
|
+
};
|
|
222
|
+
/**
|
|
223
|
+
* Traverses the tags map to create navigation entries, handling nested, grouped and ungrouped tags.
|
|
127
224
|
*
|
|
128
225
|
* This function processes the OpenAPI document's tags to:
|
|
129
|
-
* -
|
|
226
|
+
* - Nest tags via the OpenAPI 3.2 `parent` field (takes precedence)
|
|
227
|
+
* - Otherwise handle tag groups if specified via x-tagGroups
|
|
130
228
|
* - Sort tags and their operations according to provided sorters
|
|
131
229
|
* - Create navigation entries for each tag or tag group
|
|
132
230
|
*/
|
|
133
231
|
export const traverseTags = ({ document, tagsMap, documentId, options: { generateId, tagsSorter, operationsSorter }, }) => {
|
|
134
|
-
// x-tagGroups
|
|
232
|
+
// Native OpenAPI 3.2 tag nesting via `parent` takes precedence over x-tagGroups, but only
|
|
233
|
+
// when at least one `parent` resolves to another declared tag outside a circular reference.
|
|
234
|
+
// A stray or misspelled `parent` value must not disable the legacy `x-tagGroups` handling.
|
|
235
|
+
const parentOf = getParentMap(document.tags ?? []);
|
|
236
|
+
const hasNestedTags = Array.from(parentOf.keys()).some((name) => !isCyclic(parentOf, name));
|
|
237
|
+
if (hasNestedTags) {
|
|
238
|
+
// The flat traversal rewrites tag-level `x-scalar-order`, so capture the original values
|
|
239
|
+
// first to keep any custom order that already references nested tag ids.
|
|
240
|
+
const originalOrders = new Map();
|
|
241
|
+
for (const tag of document.tags ?? []) {
|
|
242
|
+
if (tag.name && tag['x-scalar-order']) {
|
|
243
|
+
originalOrders.set(tag.name, tag['x-scalar-order']);
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
const flatEntries = getSortedTagEntries({
|
|
247
|
+
_keys: Array.from(tagsMap.keys()),
|
|
248
|
+
tagsMap,
|
|
249
|
+
options: { generateId, tagsSorter, operationsSorter },
|
|
250
|
+
documentId,
|
|
251
|
+
sortOrder: document['x-scalar-order'],
|
|
252
|
+
});
|
|
253
|
+
return nestTagsByParent({ flatEntries, document, originalOrders });
|
|
254
|
+
}
|
|
255
|
+
// x-tagGroups (legacy)
|
|
135
256
|
if (document['x-tagGroups']) {
|
|
136
257
|
const tagGroups = document['x-tagGroups'];
|
|
137
258
|
return tagGroups.flatMap((tagGroup) => {
|
|
@@ -151,6 +272,7 @@ export const traverseTags = ({ document, tagsMap, documentId, options: { generat
|
|
|
151
272
|
children: entries,
|
|
152
273
|
parentId: documentId,
|
|
153
274
|
isGroup: true,
|
|
275
|
+
isTagGroup: true,
|
|
154
276
|
})
|
|
155
277
|
: [];
|
|
156
278
|
});
|
|
@@ -1,4 +1,16 @@
|
|
|
1
1
|
import type { ExampleObject, RequestBodyObject } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document';
|
|
2
|
+
/**
|
|
3
|
+
* Generate a write-mode example directly from a request body's schema, ignoring any stored example.
|
|
4
|
+
*
|
|
5
|
+
* This is the schema-generation half of {@link getExampleFromBody}. It is exposed on its own so
|
|
6
|
+
* callers that need to regenerate a body for a freshly selected composition branch (rather than the
|
|
7
|
+
* edited example that would otherwise shadow it) produce the exact same value the initial example
|
|
8
|
+
* does. The schema is deep-resolved first so nested `$ref` members (common for composition branches)
|
|
9
|
+
* are materialized instead of emitting `null` for referenced sub-objects.
|
|
10
|
+
*
|
|
11
|
+
* Returns `undefined` when there is no schema for the content type.
|
|
12
|
+
*/
|
|
13
|
+
export declare const getSchemaExampleFromBody: (requestBody: RequestBodyObject, contentType: string, requestBodyCompositionSelection?: Record<string, number>) => unknown;
|
|
2
14
|
/**
|
|
3
15
|
* Basically getExample + we generate an example from the schema if no example is found
|
|
4
16
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-request-body-example.d.ts","sourceRoot":"","sources":["../../../../src/request-example/builder/body/get-request-body-example.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,aAAa,EACb,iBAAiB,EAElB,MAAM,8DAA8D,CAAA;AAMrE;;GAEG;AACH,eAAO,MAAM,kBAAkB,GAC7B,aAAa,iBAAiB,EAC9B,aAAa,MAAM,EACnB,aAAa,MAAM,EACnB,kCAAkC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KACvD,aAAa,GAAG,
|
|
1
|
+
{"version":3,"file":"get-request-body-example.d.ts","sourceRoot":"","sources":["../../../../src/request-example/builder/body/get-request-body-example.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,aAAa,EACb,iBAAiB,EAElB,MAAM,8DAA8D,CAAA;AAMrE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,wBAAwB,GACnC,aAAa,iBAAiB,EAC9B,aAAa,MAAM,EACnB,kCAAkC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KACvD,OAkBF,CAAA;AAED;;GAEG;AACH,eAAO,MAAM,kBAAkB,GAC7B,aAAa,iBAAiB,EAC9B,aAAa,MAAM,EACnB,aAAa,MAAM,EACnB,kCAAkC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KACvD,aAAa,GAAG,IAgBlB,CAAA"}
|
|
@@ -2,11 +2,34 @@ import { getResolvedRef } from '@scalar/workspace-store/helpers/get-resolved-ref
|
|
|
2
2
|
import { getResolvedRefDeep } from '../../../helpers/get-resolved-ref-deep.js';
|
|
3
3
|
import { getExample } from '../../../request-example/builder/helpers/get-example.js';
|
|
4
4
|
import { getExampleFromSchema } from '../../../request-example/builder/helpers/get-example-from-schema.js';
|
|
5
|
+
/**
|
|
6
|
+
* Generate a write-mode example directly from a request body's schema, ignoring any stored example.
|
|
7
|
+
*
|
|
8
|
+
* This is the schema-generation half of {@link getExampleFromBody}. It is exposed on its own so
|
|
9
|
+
* callers that need to regenerate a body for a freshly selected composition branch (rather than the
|
|
10
|
+
* edited example that would otherwise shadow it) produce the exact same value the initial example
|
|
11
|
+
* does. The schema is deep-resolved first so nested `$ref` members (common for composition branches)
|
|
12
|
+
* are materialized instead of emitting `null` for referenced sub-objects.
|
|
13
|
+
*
|
|
14
|
+
* Returns `undefined` when there is no schema for the content type.
|
|
15
|
+
*/
|
|
16
|
+
export const getSchemaExampleFromBody = (requestBody, contentType, requestBodyCompositionSelection) => {
|
|
17
|
+
const schema = getResolvedRef(requestBody.content?.[contentType]?.schema);
|
|
18
|
+
if (!schema) {
|
|
19
|
+
return undefined;
|
|
20
|
+
}
|
|
21
|
+
const resolvedSchema = getResolvedRefDeep(schema);
|
|
22
|
+
return getExampleFromSchema(resolvedSchema, {
|
|
23
|
+
mode: 'write',
|
|
24
|
+
compositionSelection: requestBodyCompositionSelection,
|
|
25
|
+
}, {
|
|
26
|
+
schemaPath: ['requestBody'],
|
|
27
|
+
});
|
|
28
|
+
};
|
|
5
29
|
/**
|
|
6
30
|
* Basically getExample + we generate an example from the schema if no example is found
|
|
7
31
|
*/
|
|
8
32
|
export const getExampleFromBody = (requestBody, contentType, exampleName, requestBodyCompositionSelection) => {
|
|
9
|
-
const content = requestBody.content?.[contentType];
|
|
10
33
|
// Return the existing example when it carries a usable value. An example that only has an
|
|
11
34
|
// `externalValue` (not yet resolved to a `value`) is treated as missing, so we fall back to a
|
|
12
35
|
// schema-generated example instead of building an empty request body.
|
|
@@ -14,18 +37,8 @@ export const getExampleFromBody = (requestBody, contentType, exampleName, reques
|
|
|
14
37
|
if (example && example.value !== undefined) {
|
|
15
38
|
return example;
|
|
16
39
|
}
|
|
17
|
-
const schema = getResolvedRef(content?.schema);
|
|
18
|
-
if (!schema) {
|
|
19
|
-
return null;
|
|
20
|
-
}
|
|
21
|
-
const resolvedSchema = getResolvedRefDeep(schema);
|
|
22
40
|
// Generate an example from the schema
|
|
23
|
-
const schemaExample =
|
|
24
|
-
mode: 'write',
|
|
25
|
-
compositionSelection: requestBodyCompositionSelection,
|
|
26
|
-
}, {
|
|
27
|
-
schemaPath: ['requestBody'],
|
|
28
|
-
});
|
|
41
|
+
const schemaExample = getSchemaExampleFromBody(requestBody, contentType, requestBodyCompositionSelection);
|
|
29
42
|
if (!schemaExample) {
|
|
30
43
|
return null;
|
|
31
44
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { getExampleFromBody } from './body/get-request-body-example.js';
|
|
1
|
+
export { getExampleFromBody, getSchemaExampleFromBody } from './body/get-request-body-example.js';
|
|
2
2
|
export { getSelectedBodyContentType } from './body/get-selected-body-content-type.js';
|
|
3
3
|
export { buildDottedNestedRowPredicate, coerceLeafValueToSchemaType, coerceUntypedValue, resolveLeafSchema, } from './body/schema-value-coercion.js';
|
|
4
4
|
export { type SerializedFormProperty, serializeFormPropertyWithEncoding } from './body/serialize-form-property.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/request-example/builder/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/request-example/builder/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAA;AAC9F,OAAO,EAAE,0BAA0B,EAAE,MAAM,uCAAuC,CAAA;AAClF,OAAO,EACL,6BAA6B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ACxE,YAAY,EACV,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,gCAAgC,EAChC,gCAAgC,EAChC,uBAAuB,EACvB,uBAAuB,EACvB,sBAAsB,EACtB,yBAAyB,EACzB,gBAAgB,EAChB,0BAA0B,EAC1B,gBAAgB,GACjB,MAAM,yBAAyB,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { getExampleFromBody } from './body/get-request-body-example.js';
|
|
1
|
+
export { getExampleFromBody, getSchemaExampleFromBody } from './body/get-request-body-example.js';
|
|
2
2
|
export { getSelectedBodyContentType } from './body/get-selected-body-content-type.js';
|
|
3
3
|
export { buildDottedNestedRowPredicate, coerceLeafValueToSchemaType, coerceUntypedValue, resolveLeafSchema, } from './body/schema-value-coercion.js';
|
|
4
4
|
export { serializeFormPropertyWithEncoding } from './body/serialize-form-property.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-request-example-context.d.ts","sourceRoot":"","sources":["../../../src/request-example/context/get-request-example-context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,6BAA6B,CAAA;AAE9E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAC9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAA;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAGpD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iDAAiD,CAAA;AAIjG,OAAO,EAAE,KAAK,MAAM,EAAqB,MAAM,iCAAiC,CAAA;AAIhF,OAAO,EAAE,KAAK,qBAAqB,EAAiB,MAAM,mDAAmD,CAAA;AAE7G,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAA;AACzE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,qDAAqD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B,aAAa,EAAE,MAAM,CAAA;IACrB,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,EAAE,MAAM,CAAA;IAClB,UAAU,EAAE,OAAO,CAAA;IACnB,+CAA+C;IAC/C,cAAc,EAAE,2BAA2B,CAAA;IAC3C;;;;OAIG;IACH,gBAAgB,EAAE,iBAAiB,GAAG,IAAI,CAAA;CAC3C,CAAM,KACN,MAAM,CAAC,0BAA0B,
|
|
1
|
+
{"version":3,"file":"get-request-example-context.d.ts","sourceRoot":"","sources":["../../../src/request-example/context/get-request-example-context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,6BAA6B,CAAA;AAE9E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAC9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAA;AACvD,OAAO,KAAK,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,UAAU,CAAA;AAGpD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,iDAAiD,CAAA;AAIjG,OAAO,EAAE,KAAK,MAAM,EAAqB,MAAM,iCAAiC,CAAA;AAIhF,OAAO,EAAE,KAAK,qBAAqB,EAAiB,MAAM,mDAAmD,CAAA;AAE7G,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAA;AACzE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,qDAAqD,CAAA;AAC7F,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,+CAA+C,CAAA;AAElF,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAA;AACtE,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,4CAA4C,CAAA;AAC3F,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAChE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAA;AAE5D,MAAM,MAAM,0BAA0B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-example/context/security/merge-secu
|
|
|
11
11
|
import { getSelectedServer, getServers } from '../../request-example/context/servers.js';
|
|
12
12
|
import { isOpenApiDocument } from '../../schemas/type-guards.js';
|
|
13
13
|
export const getRequestExampleContext = (workspaceStore, documentName, requestExampleMeta, options = {}) => {
|
|
14
|
-
const { path, method, exampleName } = requestExampleMeta;
|
|
14
|
+
const { path, method, exampleName, isWebhook = false } = requestExampleMeta;
|
|
15
15
|
const document = workspaceStore.workspace.documents[documentName] ?? options.fallbackDocument ?? undefined;
|
|
16
16
|
if (!document) {
|
|
17
17
|
return {
|
|
@@ -25,18 +25,18 @@ export const getRequestExampleContext = (workspaceStore, documentName, requestEx
|
|
|
25
25
|
error: `Document ${documentName} is not an OpenAPI document`,
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
|
-
const pathItem = getResolvedPathItem(document.paths?.[path]);
|
|
28
|
+
const pathItem = getResolvedPathItem(isWebhook ? document.webhooks?.[path] : document.paths?.[path]);
|
|
29
29
|
if (!pathItem) {
|
|
30
30
|
return {
|
|
31
31
|
ok: false,
|
|
32
|
-
error: `Path ${path} not found`,
|
|
32
|
+
error: isWebhook ? `Webhook ${path} not found` : `Path ${path} not found`,
|
|
33
33
|
};
|
|
34
34
|
}
|
|
35
|
-
const resolvedOperation = getResolvedRef(getPathItemOperation(
|
|
35
|
+
const resolvedOperation = getResolvedRef(getPathItemOperation(pathItem, method));
|
|
36
36
|
if (!resolvedOperation) {
|
|
37
37
|
return {
|
|
38
38
|
ok: false,
|
|
39
|
-
error: `Method ${method} not found on path ${path}`,
|
|
39
|
+
error: isWebhook ? `Method ${method} not found on webhook ${path}` : `Method ${method} not found on path ${path}`,
|
|
40
40
|
};
|
|
41
41
|
}
|
|
42
42
|
// Combine the path item and operation parameters
|
|
@@ -53,7 +53,10 @@ export const getRequestExampleContext = (workspaceStore, documentName, requestEx
|
|
|
53
53
|
// SERVER CONTEXT
|
|
54
54
|
//------------------------------------------------------------------------------------------------
|
|
55
55
|
// Get server context for the request example
|
|
56
|
-
const
|
|
56
|
+
const configuredServers = isWebhook
|
|
57
|
+
? (options.servers ?? operation.servers)
|
|
58
|
+
: (options.servers ?? operation.servers ?? document.servers);
|
|
59
|
+
const serverList = getServers(configuredServers, {
|
|
57
60
|
baseServerUrl: options.baseServerUrl,
|
|
58
61
|
documentUrl: document['x-scalar-original-source-url'],
|
|
59
62
|
});
|
|
@@ -76,7 +79,9 @@ export const getRequestExampleContext = (workspaceStore, documentName, requestEx
|
|
|
76
79
|
const selectedSecurity = getSelectedSecurity(documentSelectedSecurity, operationSelectedSecurity, securityRequirements, securitySchemes, options.authentication?.preferredSecurityScheme);
|
|
77
80
|
/** The above selected requirements in scheme form */
|
|
78
81
|
const selectedSecuritySchemes = getSecuritySchemes(securitySchemes, selectedSecurity.selectedSchemes[selectedSecurity.selectedIndex] ?? {});
|
|
79
|
-
const serverMeta = operation.servers != null
|
|
82
|
+
const serverMeta = !isWebhook && operation.servers != null
|
|
83
|
+
? { type: 'operation', path: path ?? '', method: method ?? 'get' }
|
|
84
|
+
: { type: 'document' };
|
|
80
85
|
const authMeta = operationSelectedSecurity !== undefined
|
|
81
86
|
? { type: 'operation', path: path ?? '', method: method ?? 'get' }
|
|
82
87
|
: { type: 'document' };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type { ApiKeyObjectSecret, BuildRequestData, BuildRequestFailureCode, BuildRequestResult, EncryptionObjectSecret, GssapiObjectSecret, HttpObjectSecret, OAuth2ObjectSecret, OAuthFlowAuthorizationCodeSecret, OAuthFlowClientCredentialsSecret, OAuthFlowImplicitSecret, OAuthFlowPasswordSecret, OAuthFlowsObjectSecret, OpenIdConnectObjectSecret, RequestPayload, ResolveRequestFactoryUrlError, ResolveRequestFactoryUrlResult, SaslObjectSecret, SecuritySchemeObjectSecret, X509ObjectSecret, } from './builder/index.js';
|
|
2
|
-
export { BUILD_REQUEST_FAILED, INVALID_REQUEST_FACTORY_URL, MISSING_REQUEST_SERVER_BASE, type RequestFactory, type SerializedFormProperty, buildDottedNestedRowPredicate, buildRequest, buildRequestSecurity, coerceLeafValueToSchemaType, coerceUntypedValue, deSerializeParameter, deSerializeSchemaValue, filterGlobalCookie, getEnvironmentVariables, getExample, getExampleFromBody, getExampleFromSchema, getResolvedUrl, getSelectedBodyContentType, getServerVariables, isEncryptionSchemeType, isParamDisabled, isSaslSchemeType, requestFactory, resolveExecutableRequestUrl, resolveLeafSchema, resolveRequestFactoryUrl, serializeContentValue, serializeDeepObjectStyle, serializeFormPropertyWithEncoding, serializeFormStyle, serializeFormStyleForCookies, serializePipeDelimitedStyle, serializeSimpleStyle, serializeSpaceDelimitedStyle, } from './builder/index.js';
|
|
2
|
+
export { BUILD_REQUEST_FAILED, INVALID_REQUEST_FACTORY_URL, MISSING_REQUEST_SERVER_BASE, type RequestFactory, type SerializedFormProperty, buildDottedNestedRowPredicate, buildRequest, buildRequestSecurity, coerceLeafValueToSchemaType, coerceUntypedValue, deSerializeParameter, deSerializeSchemaValue, filterGlobalCookie, getEnvironmentVariables, getExample, getExampleFromBody, getExampleFromSchema, getResolvedUrl, getSchemaExampleFromBody, getSelectedBodyContentType, getServerVariables, isEncryptionSchemeType, isParamDisabled, isSaslSchemeType, requestFactory, resolveExecutableRequestUrl, resolveLeafSchema, resolveRequestFactoryUrl, serializeContentValue, serializeDeepObjectStyle, serializeFormPropertyWithEncoding, serializeFormStyle, serializeFormStyleForCookies, serializePipeDelimitedStyle, serializeSimpleStyle, serializeSpaceDelimitedStyle, } from './builder/index.js';
|
|
3
3
|
export type { MergedSecuritySchemes } from './context/index.js';
|
|
4
4
|
export { type BuildRequestExampleContext, combineParams, filterDisabledDefaultHeaders, getActiveEnvironment, getActiveProxyUrl, getDefaultHeaders, getRequestExampleContext, getSecurityRequirements, getSecuritySchemes, getSelectedSecurity, getSelectedServer, getServers, isAuthOptional, mergeSecurity, restoreConventionalDefaultHeaderNames, restoreConventionalHeaderName, } from './context/index.js';
|
|
5
5
|
export { CONTEXT_FUNCTION_NAMES, type ContextFunctionEntry, type ContextFunctionName, POPULAR_CONTEXT_FUNCTION_KEYS, contextFunctions, getContextFunctionComment, isContextFunctionName, } from './functions.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/request-example/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,kBAAkB,EAClB,gBAAgB,EAChB,uBAAuB,EACvB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,gCAAgC,EAChC,gCAAgC,EAChC,uBAAuB,EACvB,uBAAuB,EACvB,sBAAsB,EACtB,yBAAyB,EACzB,cAAc,EACd,6BAA6B,EAC7B,8BAA8B,EAC9B,gBAAgB,EAChB,0BAA0B,EAC1B,gBAAgB,GACjB,MAAM,WAAW,CAAA;AAClB,OAAO,EACL,oBAAoB,EACpB,2BAA2B,EAC3B,2BAA2B,EAC3B,KAAK,cAAc,EACnB,KAAK,sBAAsB,EAC3B,6BAA6B,EAC7B,YAAY,EACZ,oBAAoB,EACpB,2BAA2B,EAC3B,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,uBAAuB,EACvB,UAAU,EACV,kBAAkB,EAClB,oBAAoB,EACpB,cAAc,EACd,0BAA0B,EAC1B,kBAAkB,EAClB,sBAAsB,EACtB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,2BAA2B,EAC3B,iBAAiB,EACjB,wBAAwB,EACxB,qBAAqB,EACrB,wBAAwB,EACxB,iCAAiC,EACjC,kBAAkB,EAClB,4BAA4B,EAC5B,2BAA2B,EAC3B,oBAAoB,EACpB,4BAA4B,GAC7B,MAAM,WAAW,CAAA;AAClB,YAAY,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAA;AACtD,OAAO,EACL,KAAK,0BAA0B,EAC/B,aAAa,EACb,4BAA4B,EAC5B,oBAAoB,EACpB,iBAAiB,EACjB,iBAAiB,EACjB,wBAAwB,EACxB,uBAAuB,EACvB,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,UAAU,EACV,cAAc,EACd,aAAa,EACb,qCAAqC,EACrC,6BAA6B,GAC9B,MAAM,WAAW,CAAA;AAClB,OAAO,EACL,sBAAsB,EACtB,KAAK,oBAAoB,EACzB,KAAK,mBAAmB,EACxB,6BAA6B,EAC7B,gBAAgB,EAChB,yBAAyB,EACzB,qBAAqB,GACtB,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,8BAA8B,EAAE,MAAM,kBAAkB,CAAA;AACjE,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/request-example/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,kBAAkB,EAClB,gBAAgB,EAChB,uBAAuB,EACvB,kBAAkB,EAClB,sBAAsB,EACtB,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,gCAAgC,EAChC,gCAAgC,EAChC,uBAAuB,EACvB,uBAAuB,EACvB,sBAAsB,EACtB,yBAAyB,EACzB,cAAc,EACd,6BAA6B,EAC7B,8BAA8B,EAC9B,gBAAgB,EAChB,0BAA0B,EAC1B,gBAAgB,GACjB,MAAM,WAAW,CAAA;AAClB,OAAO,EACL,oBAAoB,EACpB,2BAA2B,EAC3B,2BAA2B,EAC3B,KAAK,cAAc,EACnB,KAAK,sBAAsB,EAC3B,6BAA6B,EAC7B,YAAY,EACZ,oBAAoB,EACpB,2BAA2B,EAC3B,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,uBAAuB,EACvB,UAAU,EACV,kBAAkB,EAClB,oBAAoB,EACpB,cAAc,EACd,wBAAwB,EACxB,0BAA0B,EAC1B,kBAAkB,EAClB,sBAAsB,EACtB,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,2BAA2B,EAC3B,iBAAiB,EACjB,wBAAwB,EACxB,qBAAqB,EACrB,wBAAwB,EACxB,iCAAiC,EACjC,kBAAkB,EAClB,4BAA4B,EAC5B,2BAA2B,EAC3B,oBAAoB,EACpB,4BAA4B,GAC7B,MAAM,WAAW,CAAA;AAClB,YAAY,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAA;AACtD,OAAO,EACL,KAAK,0BAA0B,EAC/B,aAAa,EACb,4BAA4B,EAC5B,oBAAoB,EACpB,iBAAiB,EACjB,iBAAiB,EACjB,wBAAwB,EACxB,uBAAuB,EACvB,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,UAAU,EACV,cAAc,EACd,aAAa,EACb,qCAAqC,EACrC,6BAA6B,GAC9B,MAAM,WAAW,CAAA;AAClB,OAAO,EACL,sBAAsB,EACtB,KAAK,oBAAoB,EACzB,KAAK,mBAAmB,EACxB,6BAA6B,EAC7B,gBAAgB,EAChB,yBAAyB,EACzB,qBAAqB,GACtB,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,8BAA8B,EAAE,MAAM,kBAAkB,CAAA;AACjE,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { BUILD_REQUEST_FAILED, INVALID_REQUEST_FACTORY_URL, MISSING_REQUEST_SERVER_BASE, buildDottedNestedRowPredicate, buildRequest, buildRequestSecurity, coerceLeafValueToSchemaType, coerceUntypedValue, deSerializeParameter, deSerializeSchemaValue, filterGlobalCookie, getEnvironmentVariables, getExample, getExampleFromBody, getExampleFromSchema, getResolvedUrl, getSelectedBodyContentType, getServerVariables, isEncryptionSchemeType, isParamDisabled, isSaslSchemeType, requestFactory, resolveExecutableRequestUrl, resolveLeafSchema, resolveRequestFactoryUrl, serializeContentValue, serializeDeepObjectStyle, serializeFormPropertyWithEncoding, serializeFormStyle, serializeFormStyleForCookies, serializePipeDelimitedStyle, serializeSimpleStyle, serializeSpaceDelimitedStyle, } from './builder/index.js';
|
|
1
|
+
export { BUILD_REQUEST_FAILED, INVALID_REQUEST_FACTORY_URL, MISSING_REQUEST_SERVER_BASE, buildDottedNestedRowPredicate, buildRequest, buildRequestSecurity, coerceLeafValueToSchemaType, coerceUntypedValue, deSerializeParameter, deSerializeSchemaValue, filterGlobalCookie, getEnvironmentVariables, getExample, getExampleFromBody, getExampleFromSchema, getResolvedUrl, getSchemaExampleFromBody, getSelectedBodyContentType, getServerVariables, isEncryptionSchemeType, isParamDisabled, isSaslSchemeType, requestFactory, resolveExecutableRequestUrl, resolveLeafSchema, resolveRequestFactoryUrl, serializeContentValue, serializeDeepObjectStyle, serializeFormPropertyWithEncoding, serializeFormStyle, serializeFormStyleForCookies, serializePipeDelimitedStyle, serializeSimpleStyle, serializeSpaceDelimitedStyle, } from './builder/index.js';
|
|
2
2
|
export { combineParams, filterDisabledDefaultHeaders, getActiveEnvironment, getActiveProxyUrl, getDefaultHeaders, getRequestExampleContext, getSecurityRequirements, getSecuritySchemes, getSelectedSecurity, getSelectedServer, getServers, isAuthOptional, mergeSecurity, restoreConventionalDefaultHeaderNames, restoreConventionalHeaderName, } from './context/index.js';
|
|
3
3
|
export { CONTEXT_FUNCTION_NAMES, POPULAR_CONTEXT_FUNCTION_KEYS, contextFunctions, getContextFunctionComment, isContextFunctionName, } from './functions.js';
|
|
4
4
|
export { createVariablesStoreForRequest } from './variable-store/index.js';
|
|
@@ -6,8 +6,11 @@ import type { HttpMethod } from '@scalar/helpers/http/http-methods';
|
|
|
6
6
|
*/
|
|
7
7
|
export type { Result } from '@scalar/helpers/types/result';
|
|
8
8
|
export type RequestExampleMeta = {
|
|
9
|
+
/** API path, or webhook name when `isWebhook` is true. */
|
|
9
10
|
path: string;
|
|
10
11
|
method: HttpMethod;
|
|
11
12
|
exampleName: string;
|
|
13
|
+
/** Resolve the operation from `document.webhooks` instead of `document.paths`. */
|
|
14
|
+
isWebhook?: boolean;
|
|
12
15
|
};
|
|
13
16
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/request-example/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAA;AAEnE;;;;GAIG;AACH,YAAY,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAE1D,MAAM,MAAM,kBAAkB,GAAG;IAC/B,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,UAAU,CAAA;IAClB,WAAW,EAAE,MAAM,CAAA;CACpB,CAAA"}
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/request-example/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAA;AAEnE;;;;GAIG;AACH,YAAY,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAA;AAE1D,MAAM,MAAM,kBAAkB,GAAG;IAC/B,0DAA0D;IAC1D,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,UAAU,CAAA;IAClB,WAAW,EAAE,MAAM,CAAA;IACnB,kFAAkF;IAClF,SAAS,CAAC,EAAE,OAAO,CAAA;CACpB,CAAA"}
|
|
@@ -201,6 +201,7 @@ export declare const TraversedTagSchemaDefinition: import("@scalar/typebox").TIn
|
|
|
201
201
|
description: import("@scalar/typebox").TOptional<import("@scalar/typebox").TString>;
|
|
202
202
|
children: import("@scalar/typebox").TOptional<import("@scalar/typebox").TArray<import("@scalar/typebox").TRef<"TraversedEntryObject">>>;
|
|
203
203
|
isGroup: import("@scalar/typebox").TBoolean;
|
|
204
|
+
isTagGroup: import("@scalar/typebox").TOptional<import("@scalar/typebox").TBoolean>;
|
|
204
205
|
isWebhooks: import("@scalar/typebox").TOptional<import("@scalar/typebox").TBoolean>;
|
|
205
206
|
xKeys: import("@scalar/typebox").TOptional<import("@scalar/typebox").TRecord<import("@scalar/typebox").TString, import("@scalar/typebox").TUnknown>>;
|
|
206
207
|
}>]>;
|
|
@@ -215,6 +216,12 @@ export type TraversedTag = BaseSchema & {
|
|
|
215
216
|
description?: string;
|
|
216
217
|
children?: TraversedEntry[];
|
|
217
218
|
isGroup: boolean;
|
|
219
|
+
/**
|
|
220
|
+
* True only for legacy `x-tagGroups` wrapper entries, which are not real tags and render
|
|
221
|
+
* without a header of their own. Real OpenAPI 3.2 nested-tag sections keep this unset so the
|
|
222
|
+
* renderer still shows their summary and description.
|
|
223
|
+
*/
|
|
224
|
+
isTagGroup?: boolean;
|
|
218
225
|
isWebhooks?: boolean;
|
|
219
226
|
xKeys?: Record<string, unknown>;
|
|
220
227
|
};
|
|
@@ -291,6 +298,7 @@ export declare const TraversedEntrySchemaDefinition: import("@scalar/typebox").T
|
|
|
291
298
|
description: import("@scalar/typebox").TOptional<import("@scalar/typebox").TString>;
|
|
292
299
|
children: import("@scalar/typebox").TOptional<import("@scalar/typebox").TArray<import("@scalar/typebox").TRef<"TraversedEntryObject">>>;
|
|
293
300
|
isGroup: import("@scalar/typebox").TBoolean;
|
|
301
|
+
isTagGroup: import("@scalar/typebox").TOptional<import("@scalar/typebox").TBoolean>;
|
|
294
302
|
isWebhooks: import("@scalar/typebox").TOptional<import("@scalar/typebox").TBoolean>;
|
|
295
303
|
xKeys: import("@scalar/typebox").TOptional<import("@scalar/typebox").TRecord<import("@scalar/typebox").TString, import("@scalar/typebox").TUnknown>>;
|
|
296
304
|
}>]>, import("@scalar/typebox").TIntersect<[import("@scalar/typebox").TObject<{
|
|
@@ -355,10 +363,16 @@ type TagProps = {
|
|
|
355
363
|
tag: TagObject;
|
|
356
364
|
type: 'tag';
|
|
357
365
|
/**
|
|
358
|
-
* Set when
|
|
359
|
-
*
|
|
366
|
+
* Set when this tag has no operations of its own and only nests other tags,
|
|
367
|
+
* so the renderer can present it as a section rather than a leaf.
|
|
360
368
|
*/
|
|
361
369
|
isGroup?: boolean;
|
|
370
|
+
/**
|
|
371
|
+
* Set when `tag` is an `x-tagGroups` wrapper entry (not a real OpenAPI tag),
|
|
372
|
+
* so its ID stays distinct from same-named OpenAPI tags and from other groups.
|
|
373
|
+
* Native OpenAPI 3.2 nested tags are real tags and keep the regular `tag` prefix.
|
|
374
|
+
*/
|
|
375
|
+
isTagGroup?: boolean;
|
|
362
376
|
};
|
|
363
377
|
type OperationProps = {
|
|
364
378
|
parentId: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"navigation.d.ts","sourceRoot":"","sources":["../../src/schemas/navigation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,KAAK,UAAU,EAAE,MAAM,mCAAmC,CAAA;AACjF,OAAO,EAAE,KAAK,QAAQ,EAAQ,MAAM,iBAAiB,CAAA;AACrD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAA;AAGpE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAA;AAC5D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAA;AAEtE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAChE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAA;AAE1D,eAAO,MAAM,8BAA8B;;;EAGzC,CAAA;AAEF,KAAK,UAAU,GAAG;IAChB;;;;OAIG;IACH,EAAE,EAAE,MAAM,CAAA;IACV,2CAA2C;IAC3C,KAAK,EAAE,MAAM,CAAA;CACd,CAAA;AAED,eAAO,MAAM,iCAAiC;;;;;;;;IAQ7C,CAAA;AAED;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG;IAC3C,IAAI,EAAE,UAAU,CAAA;IAChB,oBAAoB;IACpB,IAAI,EAAE,MAAM,CAAA;IACZ,uCAAuC;IACvC,QAAQ,CAAC,EAAE,cAAc,EAAE,CAAA;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAA;CACd,CAAA;AAED,eAAO,MAAM,oCA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AAM,CAAA"}
|
|
@@ -65,6 +65,7 @@ export const TraversedTagSchemaDefinition = compose(NavigationBaseSchemaDefiniti
|
|
|
65
65
|
description: Type.Optional(Type.String()),
|
|
66
66
|
children: Type.Optional(Type.Array(TraversedEntryObjectRef)),
|
|
67
67
|
isGroup: Type.Boolean(),
|
|
68
|
+
isTagGroup: Type.Optional(Type.Boolean()),
|
|
68
69
|
isWebhooks: Type.Optional(Type.Boolean()),
|
|
69
70
|
xKeys: Type.Optional(Type.Record(Type.String(), Type.Unknown())),
|
|
70
71
|
}));
|