@scalar/api-reference 1.24.74 → 1.24.76
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 +26 -0
- package/dist/browser/standalone.js +7481 -7449
- package/dist/browser/webpack-stats.json +1 -1
- package/dist/components/ApiReferenceLayout.vue.d.ts.map +1 -1
- package/dist/components/ApiReferenceLayout.vue.js +2 -2
- package/dist/components/ApiReferenceLayout.vue2.js +71 -71
- package/dist/components/Content/Content.vue2.js +11 -11
- package/dist/components/Content/Lazy/Loading.vue.js +1 -1
- package/dist/components/Content/Operation/ContentTypeSelect.vue.d.ts +27 -0
- package/dist/components/Content/Operation/ContentTypeSelect.vue.d.ts.map +1 -0
- package/dist/components/Content/Operation/ContentTypeSelect.vue.js +7 -0
- package/dist/components/Content/Operation/ContentTypeSelect.vue2.js +41 -0
- package/dist/components/Content/Operation/EndpointDetails.vue.d.ts.map +1 -1
- package/dist/components/Content/Operation/EndpointDetails.vue.js +10 -7
- package/dist/components/Content/Operation/ParameterItem.vue.d.ts +5 -0
- package/dist/components/Content/Operation/ParameterItem.vue.d.ts.map +1 -1
- package/dist/components/Content/Operation/ParameterItem.vue.js +2 -2
- package/dist/components/Content/Operation/ParameterItem.vue2.js +54 -19
- package/dist/components/Content/Operation/Parameters.vue.d.ts +5 -0
- package/dist/components/Content/Operation/Parameters.vue.d.ts.map +1 -1
- package/dist/components/Content/Operation/Parameters.vue.js +2 -2
- package/dist/components/Content/Operation/Parameters.vue2.js +16 -14
- package/dist/components/Content/Operation/PathResponses/ExampleResponse.vue.d.ts.map +1 -1
- package/dist/components/Content/Operation/PathResponses/ExampleResponse.vue.js +1 -1
- package/dist/components/Content/Operation/PathResponses/ExampleResponse.vue2.js +28 -22
- package/dist/components/Content/Tag/Endpoints.vue.d.ts +2 -6
- package/dist/components/Content/Tag/Endpoints.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/Endpoints.vue.js +2 -2
- package/dist/components/Content/Tag/Endpoints.vue2.js +57 -60
- package/dist/components/Content/Tag/Tag.vue.d.ts.map +1 -1
- package/dist/components/Content/Tag/Tag.vue.js +2 -2
- package/dist/components/Content/Tag/Tag.vue2.js +21 -33
- package/dist/components/Content/Webhooks/Webhooks.vue.d.ts.map +1 -1
- package/dist/components/Content/Webhooks/Webhooks.vue.js +5 -76
- package/dist/components/Content/Webhooks/Webhooks.vue2.js +76 -2
- package/dist/components/Section/SectionContainer.vue.js +1 -1
- package/dist/components/ShowMoreButton.vue.d.ts.map +1 -1
- package/dist/components/ShowMoreButton.vue.js +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts.map +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue.js +4 -4
- package/dist/features/ExampleRequest/ExampleRequest.vue2.js +11 -10
- package/dist/hooks/useReactiveSpec.d.ts +2 -0
- package/dist/hooks/useReactiveSpec.d.ts.map +1 -1
- package/dist/hooks/useResponses.d.ts +2 -1
- package/dist/hooks/useResponses.d.ts.map +1 -1
- package/dist/hooks/useResponses.js +12 -11
- package/dist/hooks/useSidebar.d.ts +9 -0
- package/dist/hooks/useSidebar.d.ts.map +1 -1
- package/dist/hooks/useSidebar.js +123 -108
- package/dist/index.js +20 -19
- package/dist/legacy/stores/useOpenApiStore.d.ts +2 -0
- package/dist/legacy/stores/useOpenApiStore.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/package.json +5 -5
- package/dist/components/Content/Tag/mutationObserver.d.ts +0 -3
- package/dist/components/Content/Tag/mutationObserver.d.ts.map +0 -1
- package/dist/components/Content/Tag/mutationObserver.js +0 -7
|
@@ -1,4 +1,78 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { defineComponent as y, computed as v, openBlock as r, createBlock as s, unref as o, withCtx as n, createElementBlock as d, Fragment as u, renderList as S, createVNode as c, createTextVNode as g, toDisplayString as C, createCommentVNode as a, pushScopeId as I, popScopeId as N, createElementVNode as B } from "vue";
|
|
2
|
+
import { ScalarMarkdown as j } from "@scalar/components";
|
|
3
|
+
import E from "./Webhook.vue.js";
|
|
4
|
+
import O from "../../Section/SectionContainer.vue.js";
|
|
5
|
+
import W from "../../Section/Section.vue.js";
|
|
6
|
+
import A from "../../Section/SectionContent.vue.js";
|
|
7
|
+
import D from "../../Section/SectionHeader.vue.js";
|
|
8
|
+
import F from "../../Anchor/Anchor.vue.js";
|
|
9
|
+
import { useNavState as H } from "../../../hooks/useNavState.js";
|
|
10
|
+
const K = (l) => (I("data-v-f1eb04ed"), l = l(), N(), l), L = /* @__PURE__ */ K(() => /* @__PURE__ */ B("div", { id: "webhooks" }, null, -1)), U = /* @__PURE__ */ y({
|
|
11
|
+
__name: "Webhooks",
|
|
12
|
+
props: {
|
|
13
|
+
webhooks: {}
|
|
14
|
+
},
|
|
15
|
+
setup(l) {
|
|
16
|
+
const _ = l, k = v(() => Object.keys(_.webhooks ?? {})), { getWebhookId: m } = H();
|
|
17
|
+
return (i, M) => k.value.length ? (r(), s(o(O), { key: 0 }, {
|
|
18
|
+
default: n(() => [
|
|
19
|
+
L,
|
|
20
|
+
(r(!0), d(u, null, S(k.value, (e) => {
|
|
21
|
+
var p;
|
|
22
|
+
return r(), d(u, { key: e }, [
|
|
23
|
+
(r(!0), d(u, null, S(Object.keys(
|
|
24
|
+
(p = i.webhooks) == null ? void 0 : p[e]
|
|
25
|
+
), (t) => (r(), s(o(W), {
|
|
26
|
+
id: o(m)(e, t),
|
|
27
|
+
key: t,
|
|
28
|
+
label: e
|
|
29
|
+
}, {
|
|
30
|
+
default: n(() => {
|
|
31
|
+
var f;
|
|
32
|
+
return [
|
|
33
|
+
(f = i.webhooks) != null && f[e] ? (r(), s(o(A), { key: 0 }, {
|
|
34
|
+
default: n(() => {
|
|
35
|
+
var h, w;
|
|
36
|
+
return [
|
|
37
|
+
c(o(D), { level: 2 }, {
|
|
38
|
+
default: n(() => [
|
|
39
|
+
c(o(F), {
|
|
40
|
+
id: o(m)(e, t)
|
|
41
|
+
}, {
|
|
42
|
+
default: n(() => {
|
|
43
|
+
var b;
|
|
44
|
+
return [
|
|
45
|
+
g(C((b = i.webhooks[e][t]) == null ? void 0 : b.name), 1)
|
|
46
|
+
];
|
|
47
|
+
}),
|
|
48
|
+
_: 2
|
|
49
|
+
}, 1032, ["id"])
|
|
50
|
+
]),
|
|
51
|
+
_: 2
|
|
52
|
+
}, 1024),
|
|
53
|
+
(h = i.webhooks[e][t]) != null && h.description ? (r(), s(o(j), {
|
|
54
|
+
key: 0,
|
|
55
|
+
value: (w = i.webhooks[e][t]) == null ? void 0 : w.description,
|
|
56
|
+
withImages: ""
|
|
57
|
+
}, null, 8, ["value"])) : a("", !0),
|
|
58
|
+
c(E, {
|
|
59
|
+
webhook: i.webhooks[e][t]
|
|
60
|
+
}, null, 8, ["webhook"])
|
|
61
|
+
];
|
|
62
|
+
}),
|
|
63
|
+
_: 2
|
|
64
|
+
}, 1024)) : a("", !0)
|
|
65
|
+
];
|
|
66
|
+
}),
|
|
67
|
+
_: 2
|
|
68
|
+
}, 1032, ["id", "label"]))), 128))
|
|
69
|
+
], 64);
|
|
70
|
+
}), 128))
|
|
71
|
+
]),
|
|
72
|
+
_: 1
|
|
73
|
+
})) : a("", !0);
|
|
74
|
+
}
|
|
75
|
+
});
|
|
2
76
|
export {
|
|
3
|
-
|
|
77
|
+
U as default
|
|
4
78
|
};
|
|
@@ -7,7 +7,7 @@ function i(e, a) {
|
|
|
7
7
|
n(e.$slots, "default", {}, void 0, !0)
|
|
8
8
|
]);
|
|
9
9
|
}
|
|
10
|
-
const l = /* @__PURE__ */ r(c, [["render", i], ["__scopeId", "data-v-
|
|
10
|
+
const l = /* @__PURE__ */ r(c, [["render", i], ["__scopeId", "data-v-823b8471"]]);
|
|
11
11
|
export {
|
|
12
12
|
l as default
|
|
13
13
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ShowMoreButton.vue.d.ts","sourceRoot":"","sources":["../../src/components/ShowMoreButton.vue"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"ShowMoreButton.vue.d.ts","sourceRoot":"","sources":["../../src/components/ShowMoreButton.vue"],"names":[],"mappings":";QAsEM,MAAM;;QAAN,MAAM;;AAmEZ,wBAMG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./ShowMoreButton.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-
|
|
4
|
+
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-b1ddf847"]]);
|
|
5
5
|
export {
|
|
6
6
|
p as default
|
|
7
7
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExampleRequest.vue.d.ts","sourceRoot":"","sources":["../../../src/features/ExampleRequest/ExampleRequest.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ExampleRequest.vue.d.ts","sourceRoot":"","sources":["../../../src/features/ExampleRequest/ExampleRequest.vue"],"names":[],"mappings":"AAoXA,OAAO,KAAK,EACV,oBAAoB,EAGpB,oBAAoB,EACrB,MAAM,mBAAmB,CAAA;AA2P1B,iBAAS,cAAc;oBA+MM,GAAG;oBACH,GAAG;EAiC/B;AACD,QAAA,MAAM,eAAe;qBA3cF,oBAAoB,EAAE,GAAG,IAAI;eACnC,oBAAoB;;qBADd,oBAAoB,EAAE,GAAG,IAAI;eACnC,oBAAoB;aAgd/B,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAAvG,wBAAwG;AAOxG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACpC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC;AAEN,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import o from "./ExampleRequest.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
const
|
|
3
|
+
import t from "../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-b5a8fcbc"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as U, ref as _, watch as L, computed as y, inject as I, onServerPrefetch as M, useSSRContext as Y, openBlock as d, createBlock as b, unref as s, withCtx as c, createVNode as p, createElementBlock as
|
|
1
|
+
import { defineComponent as U, ref as _, watch as L, computed as y, inject as I, onServerPrefetch as M, useSSRContext as Y, openBlock as d, createBlock as b, unref as s, withCtx as c, createVNode as p, createElementBlock as h, Fragment as V, createTextVNode as H, toDisplayString as v, createElementVNode as O, renderSlot as j, createCommentVNode as N } from "vue";
|
|
2
2
|
import { ScalarCodeBlock as z } from "@scalar/components";
|
|
3
3
|
import { createHash as D, ssrState as Q } from "@scalar/oas-utils/helpers";
|
|
4
4
|
import { getRequestFromOperation as W } from "@scalar/oas-utils/spec-getters";
|
|
@@ -21,7 +21,7 @@ import { useServerStore as me } from "../../legacy/stores/useServerStore.js";
|
|
|
21
21
|
import { useAuthenticationStore as ue } from "../../legacy/stores/useAuthenticationStore.js";
|
|
22
22
|
import { getHarRequest as de } from "../../helpers/getHarRequest.js";
|
|
23
23
|
import { getUrlFromServerState as fe } from "../../legacy/helpers/getUrlFromServerState.js";
|
|
24
|
-
const ye = { class: "request-header" },
|
|
24
|
+
const ye = { class: "request-header" }, ge = { class: "code-snippet" }, he = {
|
|
25
25
|
key: 0,
|
|
26
26
|
class: "request-card-footer-addon"
|
|
27
27
|
}, Ue = /* @__PURE__ */ U({
|
|
@@ -40,7 +40,7 @@ const ye = { class: "request-header" }, he = { class: "code-snippet" }, ge = {
|
|
|
40
40
|
availableTargets: $,
|
|
41
41
|
httpTargetTitle: w,
|
|
42
42
|
httpClientTitle: F
|
|
43
|
-
} = ce(), { server: E } = me(), { authentication:
|
|
43
|
+
} = ce(), { server: E } = me(), { authentication: g } = ue(), l = _(
|
|
44
44
|
// Default to first custom example
|
|
45
45
|
(k = a.customExamples) != null && k.length ? {
|
|
46
46
|
targetKey: "customExamples",
|
|
@@ -83,7 +83,7 @@ const ye = { class: "request-header" }, he = { class: "code-snippet" }, ge = {
|
|
|
83
83
|
x.value
|
|
84
84
|
),
|
|
85
85
|
le(
|
|
86
|
-
|
|
86
|
+
g,
|
|
87
87
|
((u = a.operation.information) == null ? void 0 : u.security) ?? (i == null ? void 0 : i())
|
|
88
88
|
)
|
|
89
89
|
), o = n.clientKey === "undici" || n.clientKey === "fetch" || n.clientKey === "ofetch" ? n.clientKey : null, t = n.targetKey.replace("javascript", "js");
|
|
@@ -110,7 +110,7 @@ const ye = { class: "request-header" }, he = { class: "code-snippet" }, ge = {
|
|
|
110
110
|
e.payload.data[K] = await S();
|
|
111
111
|
}), y(() => pe({
|
|
112
112
|
serverState: E,
|
|
113
|
-
authenticationState:
|
|
113
|
+
authenticationState: g,
|
|
114
114
|
operation: a.operation,
|
|
115
115
|
globalSecurity: i == null ? void 0 : i()
|
|
116
116
|
}));
|
|
@@ -166,9 +166,9 @@ const ye = { class: "request-header" }, he = { class: "code-snippet" }, ge = {
|
|
|
166
166
|
default: c(() => {
|
|
167
167
|
var t;
|
|
168
168
|
return [
|
|
169
|
-
l.value.targetKey === "customExamples" ? (d(),
|
|
169
|
+
l.value.targetKey === "customExamples" ? (d(), h(V, { key: 0 }, [
|
|
170
170
|
H(v(((t = a.customExamples) == null ? void 0 : t[l.value.clientKey].label) ?? "Example"), 1)
|
|
171
|
-
], 64)) : (d(),
|
|
171
|
+
], 64)) : (d(), h(V, { key: 1 }, [
|
|
172
172
|
H(v(s(w)) + " " + v(s(F)), 1)
|
|
173
173
|
], 64))
|
|
174
174
|
];
|
|
@@ -194,10 +194,11 @@ const ye = { class: "request-header" }, he = { class: "code-snippet" }, ge = {
|
|
|
194
194
|
frameless: ""
|
|
195
195
|
}, {
|
|
196
196
|
default: c(() => [
|
|
197
|
-
O("div",
|
|
197
|
+
O("div", ge, [
|
|
198
198
|
p(s(z), {
|
|
199
|
+
class: "bg-b-2",
|
|
199
200
|
content: s(q),
|
|
200
|
-
hideCredentials: s(se)(s(
|
|
201
|
+
hideCredentials: s(se)(s(g)),
|
|
201
202
|
lang: A.value,
|
|
202
203
|
lineNumbers: ""
|
|
203
204
|
}, null, 8, ["content", "hideCredentials", "lang"])
|
|
@@ -213,7 +214,7 @@ const ye = { class: "request-header" }, he = { class: "code-snippet" }, ge = {
|
|
|
213
214
|
default: c(() => {
|
|
214
215
|
var t, r, m, u;
|
|
215
216
|
return [
|
|
216
|
-
C.value ? (d(),
|
|
217
|
+
C.value ? (d(), h("div", he, [
|
|
217
218
|
p(G, {
|
|
218
219
|
class: "request-example-selector",
|
|
219
220
|
examples: ((u = (m = (r = (t = e.operation.information) == null ? void 0 : t.requestBody) == null ? void 0 : r.content) == null ? void 0 : m["application/json"]) == null ? void 0 : u.examples) ?? [],
|
|
@@ -42,6 +42,7 @@ export declare function useReactiveSpec({ specConfig, proxy, }: {
|
|
|
42
42
|
} | undefined;
|
|
43
43
|
example?: any;
|
|
44
44
|
examples?: (Map<string, any> & Omit<Map<string, any>, keyof Map<any, any>>) | undefined;
|
|
45
|
+
content?: import("@scalar/oas-utils").RequestBodyMimeTypes;
|
|
45
46
|
}[] | undefined;
|
|
46
47
|
responses?: Record<string, import("@scalar/oas-utils").ScalarResponse>;
|
|
47
48
|
security?: import("@scalar/openapi-parser").OpenAPIV3.SecurityRequirementObject[];
|
|
@@ -90,6 +91,7 @@ export declare function useReactiveSpec({ specConfig, proxy, }: {
|
|
|
90
91
|
} | undefined;
|
|
91
92
|
example?: any;
|
|
92
93
|
examples?: (Map<string, any> & Omit<Map<string, any>, keyof Map<any, any>>) | undefined;
|
|
94
|
+
content?: import("@scalar/oas-utils").RequestBodyMimeTypes;
|
|
93
95
|
}[] | undefined;
|
|
94
96
|
}[];
|
|
95
97
|
'x-displayName'?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useReactiveSpec.d.ts","sourceRoot":"","sources":["../../src/hooks/useReactiveSpec.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAM1D,OAAO,EAAE,KAAK,gBAAgB,EAAiC,MAAM,KAAK,CAAA;AAmD1E;;GAEG;AACH,wBAAgB,eAAe,CAAC,EAC9B,UAAU,EACV,KAAK,GACN,EAAE;IACD,UAAU,CAAC,EAAE,gBAAgB,CAAC,iBAAiB,CAAC,CAAA;IAChD,KAAK,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;CACjC
|
|
1
|
+
{"version":3,"file":"useReactiveSpec.d.ts","sourceRoot":"","sources":["../../src/hooks/useReactiveSpec.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAM1D,OAAO,EAAE,KAAK,gBAAgB,EAAiC,MAAM,KAAK,CAAA;AAmD1E;;GAEG;AACH,wBAAgB,eAAe,CAAC,EAC9B,UAAU,EACV,KAAK,GACN,EAAE;IACD,UAAU,CAAC,EAAE,gBAAgB,CAAC,iBAAiB,CAAC,CAAA;IAChD,KAAK,CAAC,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAA;CACjC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwDA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { TransformedOperation } from '@scalar/oas-utils';
|
|
1
|
+
import type { RequestBodyMimeTypes, TransformedOperation } from '@scalar/oas-utils';
|
|
2
2
|
/**
|
|
3
3
|
* This hook is used to generate the responses for the request from the parameters in the swagger file
|
|
4
4
|
*/
|
|
@@ -6,6 +6,7 @@ export declare function useResponses(operation: TransformedOperation): {
|
|
|
6
6
|
responses: import("vue").ComputedRef<{
|
|
7
7
|
name: string;
|
|
8
8
|
description: string;
|
|
9
|
+
content: RequestBodyMimeTypes;
|
|
9
10
|
}[]>;
|
|
10
11
|
};
|
|
11
12
|
//# sourceMappingURL=useResponses.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useResponses.d.ts","sourceRoot":"","sources":["../../src/hooks/useResponses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"useResponses.d.ts","sourceRoot":"","sources":["../../src/hooks/useResponses.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,oBAAoB,EACpB,oBAAoB,EACrB,MAAM,mBAAmB,CAAA;AAG1B;;GAEG;AACH,wBAAgB,YAAY,CAAC,SAAS,EAAE,oBAAoB;;cAOhD,MAAM;qBACC,MAAM;iBACV,oBAAoB;;EAiBlC"}
|
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
function
|
|
3
|
-
return { responses:
|
|
4
|
-
if (!
|
|
5
|
-
const { responses:
|
|
6
|
-
return
|
|
7
|
-
|
|
8
|
-
name:
|
|
9
|
-
description: r
|
|
1
|
+
import { computed as s } from "vue";
|
|
2
|
+
function i(e) {
|
|
3
|
+
return { responses: s(() => {
|
|
4
|
+
if (!e.information) return [];
|
|
5
|
+
const { responses: n } = e.information, o = [];
|
|
6
|
+
return n && Object.keys(n).forEach((r) => {
|
|
7
|
+
o.push({
|
|
8
|
+
name: r,
|
|
9
|
+
description: n[r].description,
|
|
10
|
+
content: n[r].content
|
|
10
11
|
});
|
|
11
|
-
}),
|
|
12
|
+
}), o;
|
|
12
13
|
}) };
|
|
13
14
|
}
|
|
14
15
|
export {
|
|
15
|
-
|
|
16
|
+
i as useResponses
|
|
16
17
|
};
|
|
@@ -21,6 +21,14 @@ export type ParsedSpecOption = {
|
|
|
21
21
|
export type TagsSorterOption = {
|
|
22
22
|
tagsSorter?: 'alpha' | ((a: Tag, b: Tag) => number);
|
|
23
23
|
};
|
|
24
|
+
/**
|
|
25
|
+
* Scroll to operation
|
|
26
|
+
*
|
|
27
|
+
* Similar to scrollToId BUT in the case of a section not being open,
|
|
28
|
+
* it uses the lazyBus to ensure the section is open before scrolling to it
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
export declare const scrollToOperation: (operationId: string) => void;
|
|
24
32
|
/**
|
|
25
33
|
* Provides the sidebar state and methods to control it.
|
|
26
34
|
*/
|
|
@@ -37,6 +45,7 @@ export declare function useSidebar(options?: ParsedSpecOption & TagsSorterOption
|
|
|
37
45
|
hideModels: import("vue").Ref<boolean>;
|
|
38
46
|
setParsedSpec: typeof setParsedSpec;
|
|
39
47
|
defaultOpenAllTags: import("vue").Ref<boolean>;
|
|
48
|
+
scrollToOperation: (operationId: string) => void;
|
|
40
49
|
};
|
|
41
50
|
export {};
|
|
42
51
|
//# sourceMappingURL=useSidebar.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSidebar.d.ts","sourceRoot":"","sources":["../../src/hooks/useSidebar.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,GAAG,EAAwB,MAAM,mBAAmB,CAAA;
|
|
1
|
+
{"version":3,"file":"useSidebar.d.ts","sourceRoot":"","sources":["../../src/hooks/useSidebar.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,GAAG,EAAwB,MAAM,mBAAmB,CAAA;AAiBxE,MAAM,MAAM,YAAY,GAAG;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,KAAK,EAAE,MAAM,CAAA;IACb,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,YAAY,EAAE,CAAA;IACzB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAA;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,IAAI,EAAE,OAAO,CAAA;IACb,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB,CAAA;AAkBD,uDAAuD;AACvD,iBAAS,aAAa,CAAC,IAAI,EAAE,IAAI,QAWhC;AAMD,KAAK,qBAAqB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;AAMpD,iBAAS,0BAA0B,CAAC,GAAG,EAAE,MAAM,QAE9C;AAED,iBAAS,uBAAuB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,QAE3D;AA2OD,MAAM,MAAM,gBAAgB,GAAG;IAC7B,UAAU,EAAE,IAAI,CAAA;CACjB,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,UAAU,CAAC,EAAE,OAAO,GAAG,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,KAAK,MAAM,CAAC,CAAA;CACpD,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,iBAAiB,gBAAiB,MAAM,SAepD,CAAA;AAED;;GAEG;AACH,wBAAgB,UAAU,CAAC,OAAO,CAAC,EAAE,gBAAgB,GAAG,gBAAgB;;;;;;;;;;;;;qCApBzB,MAAM;EAsEpD"}
|