@scalar/api-reference 1.24.75 → 1.24.77
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 +28 -0
- package/dist/browser/standalone.js +7450 -7448
- 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/Lazy/Loading.vue.js +1 -1
- 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/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/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/style.css +1 -1
- package/package.json +6 -6
- 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 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ApiReferenceLayout.vue.d.ts","sourceRoot":"","sources":["../../src/components/ApiReferenceLayout.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ApiReferenceLayout.vue.d.ts","sourceRoot":"","sources":["../../src/components/ApiReferenceLayout.vue"],"names":[],"mappings":"AAkiBA,OAAO,EAAE,KAAK,OAAO,EAAkB,MAAM,gBAAgB,CAAA;AAuB7D,OAAO,KAAK,EACV,oBAAoB,EAEpB,kBAAkB,EACnB,MAAM,UAAU,CAAA;AA2NjB,iBAAS,cAAc;oBA/Le,kBAAkB,KAAK,GAAG;oBAA1B,kBAAkB,KAAK,GAAG;oBAA1B,kBAAkB,KAAK,GAAG;6BAA1B,kBAAkB,KAAK,GAAG;2BAA1B,kBAAkB,KAAK,GAAG;6BAA1B,kBAAkB,KAAK,GAAG;2BAA1B,kBAAkB,KAAK,GAAG;;oBAA1B,kBAAkB,KAAK,GAAG;oBAA1B,kBAAkB,KAAK,GAAG;oBAA1B,kBAAkB,KAAK,GAAG;6BAA1B,kBAAkB,KAAK,GAAG;2BAA1B,kBAAkB,KAAK,GAAG;6BAA1B,kBAAkB,KAAK,GAAG;2BAA1B,kBAAkB,KAAK,GAAG;EAoe/D;AACD,QAAA,MAAM,eAAe;;YArfqB,OAAO;eAAS,MAAM;;;;;;;;YAAtB,OAAO;eAAS,MAAM;;;;;;UA4f9D,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"}
|
|
@@ -2,7 +2,7 @@ import o from "./ApiReferenceLayout.vue2.js";
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
/* empty css */
|
|
4
4
|
import t from "../_virtual/_plugin-vue_export-helper.js";
|
|
5
|
-
const
|
|
5
|
+
const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-f9fd3db9"]]);
|
|
6
6
|
export {
|
|
7
|
-
|
|
7
|
+
m as default
|
|
8
8
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as Z, ref as
|
|
1
|
+
import { defineComponent as Z, ref as h, onMounted as B, onBeforeMount as D, computed as b, watch as _, onServerPrefetch as x, useSSRContext as ee, getCurrentInstance as oe, provide as F, openBlock as v, createElementBlock as S, Fragment as M, createElementVNode as i, normalizeClass as te, unref as u, normalizeStyle as re, renderSlot as l, normalizeProps as d, guardReactiveProps as c, createVNode as f, withCtx as g, createCommentVNode as w, withDirectives as ae, vShow as ne, createSlots as se } from "vue";
|
|
2
2
|
import { provideUseId as ie } from "@headlessui/vue";
|
|
3
3
|
import { addScalarClassesToHeadless as le } from "@scalar/components";
|
|
4
|
-
import { defaultStateFactory as
|
|
4
|
+
import { defaultStateFactory as P } from "@scalar/oas-utils/helpers";
|
|
5
5
|
import { getThemeStyles as de } from "@scalar/themes";
|
|
6
6
|
import { useToasts as ce, ScalarToasts as ue } from "@scalar/use-toasts";
|
|
7
7
|
import { useMediaQuery as pe, useResizeObserver as fe, useDebounceFn as ge } from "@vueuse/core";
|
|
@@ -15,15 +15,14 @@ import ye from "./Content/Content.vue.js";
|
|
|
15
15
|
import { useSidebar as Te } from "../hooks/useSidebar.js";
|
|
16
16
|
import { GLOBAL_SECURITY_SYMBOL as Re, HIDE_DOWNLOAD_BUTTON_SYMBOL as $e } from "../helpers/provideSymbols.js";
|
|
17
17
|
import { useNavState as Ce } from "../hooks/useNavState.js";
|
|
18
|
-
import { sleep as
|
|
19
|
-
|
|
20
|
-
const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
18
|
+
import { sleep as Le } from "../helpers/sleep.js";
|
|
19
|
+
const Ee = ["innerHTML"], Ie = { class: "references-header" }, Oe = {
|
|
21
20
|
key: 0,
|
|
22
21
|
class: "references-navigation t-doc__sidebar"
|
|
23
|
-
},
|
|
22
|
+
}, ke = { class: "references-navigation-list" }, Be = { class: "references-editor" }, De = { class: "references-editor-textarea" }, Fe = { class: "references-rendered" }, Me = {
|
|
24
23
|
key: 0,
|
|
25
24
|
class: "references-footer"
|
|
26
|
-
},
|
|
25
|
+
}, xe = /* @__PURE__ */ Z({
|
|
27
26
|
inheritAttrs: !1,
|
|
28
27
|
__name: "ApiReferenceLayout",
|
|
29
28
|
props: {
|
|
@@ -32,96 +31,97 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
32
31
|
rawSpec: {}
|
|
33
32
|
},
|
|
34
33
|
emits: ["changeTheme", "updateContent", "loadSwaggerFile", "linkSwaggerFile", "toggleDarkMode"],
|
|
35
|
-
setup(
|
|
36
|
-
const t =
|
|
37
|
-
|
|
38
|
-
const
|
|
34
|
+
setup(U) {
|
|
35
|
+
const t = U, { initializeToasts: A, toast: H } = ce();
|
|
36
|
+
A((e) => H(e));
|
|
37
|
+
const N = pe("(min-width: 1150px)"), z = h("100dvh"), p = h(null);
|
|
39
38
|
fe(p, (e) => {
|
|
40
|
-
|
|
39
|
+
z.value = e[0].contentRect.height + "px";
|
|
41
40
|
});
|
|
42
|
-
const
|
|
43
|
-
|
|
44
|
-
var
|
|
45
|
-
const e = (
|
|
41
|
+
const y = h(0);
|
|
42
|
+
B(() => {
|
|
43
|
+
var a, r, n;
|
|
44
|
+
const e = (r = (a = p.value) == null ? void 0 : a.parentElement) == null ? void 0 : r.getBoundingClientRect(), o = (n = p.value) == null ? void 0 : n.getBoundingClientRect();
|
|
46
45
|
if (e && o) {
|
|
47
|
-
const
|
|
48
|
-
|
|
46
|
+
const k = o.top - e.top;
|
|
47
|
+
y.value = k < 2 ? 0 : k;
|
|
49
48
|
}
|
|
50
49
|
});
|
|
51
50
|
const {
|
|
52
|
-
breadcrumb:
|
|
51
|
+
breadcrumb: Y,
|
|
53
52
|
collapsedSidebarItems: m,
|
|
54
|
-
isSidebarOpen:
|
|
55
|
-
setCollapsedSidebarItem:
|
|
56
|
-
hideModels:
|
|
57
|
-
defaultOpenAllTags:
|
|
58
|
-
setParsedSpec:
|
|
53
|
+
isSidebarOpen: V,
|
|
54
|
+
setCollapsedSidebarItem: T,
|
|
55
|
+
hideModels: G,
|
|
56
|
+
defaultOpenAllTags: W,
|
|
57
|
+
setParsedSpec: j,
|
|
58
|
+
scrollToOperation: K
|
|
59
59
|
} = Te(), {
|
|
60
|
-
getPathRoutingId:
|
|
61
|
-
getSectionId:
|
|
60
|
+
getPathRoutingId: R,
|
|
61
|
+
getSectionId: Q,
|
|
62
62
|
getTagId: q,
|
|
63
|
-
hash:
|
|
64
|
-
isIntersectionEnabled:
|
|
63
|
+
hash: $,
|
|
64
|
+
isIntersectionEnabled: C,
|
|
65
65
|
pathRouting: L,
|
|
66
66
|
updateHash: E
|
|
67
67
|
} = Ce();
|
|
68
|
-
L.value = t.configuration.pathRouting,
|
|
69
|
-
const
|
|
68
|
+
L.value = t.configuration.pathRouting, D(() => E());
|
|
69
|
+
const I = async (e) => {
|
|
70
70
|
var o;
|
|
71
|
-
|
|
71
|
+
C.value = !1, E(), e ? K(e) : (o = p.value) == null || o.scrollTo(0, 0), await Le(100), C.value = !0;
|
|
72
72
|
};
|
|
73
|
-
|
|
73
|
+
D(() => le()), B(() => {
|
|
74
74
|
Se.on(({ specTitle: e }) => {
|
|
75
75
|
he(t.rawSpec, e);
|
|
76
|
-
}), window.onhashchange = () =>
|
|
76
|
+
}), window.onhashchange = () => I(decodeURIComponent(window.location.hash.replace(/^#/, ""))), window.onpopstate = () => L.value && I(R(window.location.pathname));
|
|
77
77
|
});
|
|
78
|
-
const J =
|
|
79
|
-
() =>
|
|
78
|
+
const J = b(
|
|
79
|
+
() => N.value || !t.configuration.isEditable
|
|
80
80
|
), O = ge((e) => {
|
|
81
81
|
if ((e.target.scrollTop ?? 0) < 50) {
|
|
82
|
-
const
|
|
83
|
-
window.history.replaceState({}, "",
|
|
82
|
+
const a = t.configuration.pathRouting ? t.configuration.pathRouting.basePath : window.location.pathname;
|
|
83
|
+
window.history.replaceState({}, "", a + window.location.search), $.value = "";
|
|
84
84
|
}
|
|
85
|
-
}), s =
|
|
86
|
-
breadcrumb:
|
|
85
|
+
}), s = b(() => ({
|
|
86
|
+
breadcrumb: Y.value,
|
|
87
87
|
spec: t.parsedSpec
|
|
88
88
|
}));
|
|
89
|
-
_(() => t.parsedSpec,
|
|
90
|
-
var o,
|
|
89
|
+
_(() => t.parsedSpec, j, { deep: !0 }), x(() => {
|
|
90
|
+
var o, a;
|
|
91
91
|
const e = ee();
|
|
92
|
-
if (e && (e.payload || (e.payload = { data:
|
|
93
|
-
const
|
|
94
|
-
|
|
92
|
+
if (e && (e.payload || (e.payload = { data: P() }), (o = e.payload).data || (o.data = P()), t.configuration.pathRouting)) {
|
|
93
|
+
const r = R(e.url);
|
|
94
|
+
$.value = r, e.payload.data.hash = r;
|
|
95
95
|
for (const n in m)
|
|
96
96
|
Object.hasOwn(m, n) && delete m[n];
|
|
97
|
-
if (
|
|
98
|
-
|
|
97
|
+
if (r)
|
|
98
|
+
T(Q(r), !0);
|
|
99
99
|
else {
|
|
100
|
-
const n = (
|
|
101
|
-
n &&
|
|
100
|
+
const n = (a = t.parsedSpec.tags) == null ? void 0 : a[0];
|
|
101
|
+
n && T(q(n), !0);
|
|
102
102
|
}
|
|
103
103
|
e.payload.data["useSidebarContent-collapsedSidebarItems"] = m;
|
|
104
104
|
}
|
|
105
105
|
}), ie(() => {
|
|
106
|
-
var
|
|
106
|
+
var r;
|
|
107
107
|
const e = oe(), o = "scalar-instance-id";
|
|
108
108
|
if (!e) return o;
|
|
109
|
-
let
|
|
110
|
-
return typeof window > "u" ? (e.attrs || (e.attrs = {}), e.attrs[o] =
|
|
111
|
-
}),
|
|
109
|
+
let a = e.uid;
|
|
110
|
+
return typeof window > "u" ? (e.attrs || (e.attrs = {}), e.attrs[o] = a) : (r = e.vnode.el) != null && r.getAttribute && (a = e.vnode.el.getAttribute(o)), `${o}-${a}`;
|
|
111
|
+
}), F(Re, () => t.parsedSpec.security), F(
|
|
112
112
|
$e,
|
|
113
113
|
() => t.configuration.hideDownloadButton
|
|
114
|
-
),
|
|
115
|
-
const X =
|
|
114
|
+
), G.value = t.configuration.hideModels ?? !1, W.value = t.configuration.defaultOpenAllTags ?? !1, be(t.configuration);
|
|
115
|
+
const X = b(
|
|
116
116
|
() => `<style>
|
|
117
117
|
${de(t.configuration.theme, {
|
|
118
118
|
fonts: t.configuration.withDefaultFonts
|
|
119
119
|
})}</style>`
|
|
120
120
|
);
|
|
121
121
|
return (e, o) => {
|
|
122
|
-
var
|
|
123
|
-
return v(), S(
|
|
124
|
-
i("div", { innerHTML: X.value }, null, 8,
|
|
122
|
+
var a;
|
|
123
|
+
return v(), S(M, null, [
|
|
124
|
+
i("div", { innerHTML: X.value }, null, 8, Ee),
|
|
125
125
|
i("div", {
|
|
126
126
|
ref_key: "documentEl",
|
|
127
127
|
ref: p,
|
|
@@ -129,22 +129,22 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
129
129
|
{
|
|
130
130
|
"references-editable": e.configuration.isEditable,
|
|
131
131
|
"references-sidebar": e.configuration.showSidebar,
|
|
132
|
-
"references-sidebar-mobile-open": u(
|
|
132
|
+
"references-sidebar-mobile-open": u(V),
|
|
133
133
|
"references-classic": e.configuration.layout === "classic"
|
|
134
134
|
},
|
|
135
135
|
e.$attrs.class
|
|
136
136
|
]]),
|
|
137
137
|
style: re({
|
|
138
|
-
"--scalar-y-offset": `var(--scalar-custom-header-height, ${
|
|
138
|
+
"--scalar-y-offset": `var(--scalar-custom-header-height, ${y.value}px)`
|
|
139
139
|
}),
|
|
140
140
|
onScrollPassive: o[4] || (o[4] = //@ts-ignore
|
|
141
|
-
(...
|
|
141
|
+
(...r) => u(O) && u(O)(...r))
|
|
142
142
|
}, [
|
|
143
|
-
i("div",
|
|
143
|
+
i("div", Ie, [
|
|
144
144
|
l(e.$slots, "header", d(c(s.value)), void 0, !0)
|
|
145
145
|
]),
|
|
146
|
-
e.configuration.showSidebar ? (v(), S("aside",
|
|
147
|
-
i("div",
|
|
146
|
+
e.configuration.showSidebar ? (v(), S("aside", Oe, [
|
|
147
|
+
i("div", ke, [
|
|
148
148
|
f(u(we), {
|
|
149
149
|
parsedSpec: e.parsedSpec,
|
|
150
150
|
tagsSorter: e.configuration.tagsSorter
|
|
@@ -158,7 +158,7 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
158
158
|
_: 3
|
|
159
159
|
}, 8, ["parsedSpec", "tagsSorter"])
|
|
160
160
|
])
|
|
161
|
-
])) :
|
|
161
|
+
])) : w("", !0),
|
|
162
162
|
ae(i("div", Be, [
|
|
163
163
|
i("div", De, [
|
|
164
164
|
l(e.$slots, "editor", d(c(s.value)), void 0, !0)
|
|
@@ -166,7 +166,7 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
166
166
|
], 512), [
|
|
167
167
|
[ne, e.configuration.isEditable]
|
|
168
168
|
]),
|
|
169
|
-
J.value ? (v(), S(
|
|
169
|
+
J.value ? (v(), S(M, { key: 1 }, [
|
|
170
170
|
i("div", Fe, [
|
|
171
171
|
f(u(ye), {
|
|
172
172
|
baseServerURL: e.configuration.baseServerURL,
|
|
@@ -183,13 +183,13 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
183
183
|
]),
|
|
184
184
|
_: 2
|
|
185
185
|
}, [
|
|
186
|
-
(
|
|
186
|
+
(a = e.configuration) != null && a.isEditable ? {
|
|
187
187
|
name: "empty-state",
|
|
188
188
|
fn: g(() => {
|
|
189
|
-
var
|
|
189
|
+
var r;
|
|
190
190
|
return [
|
|
191
191
|
f(ve, {
|
|
192
|
-
theme: ((
|
|
192
|
+
theme: ((r = e.configuration) == null ? void 0 : r.theme) || "default",
|
|
193
193
|
onChangeTheme: o[0] || (o[0] = (n) => e.$emit("changeTheme", n)),
|
|
194
194
|
onLinkSwaggerFile: o[1] || (o[1] = (n) => e.$emit("linkSwaggerFile")),
|
|
195
195
|
onLoadSwaggerFile: o[2] || (o[2] = (n) => e.$emit("loadSwaggerFile")),
|
|
@@ -203,8 +203,8 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
203
203
|
]),
|
|
204
204
|
e.$slots.footer ? (v(), S("div", Me, [
|
|
205
205
|
l(e.$slots, "footer", d(c(s.value)), void 0, !0)
|
|
206
|
-
])) :
|
|
207
|
-
], 64)) :
|
|
206
|
+
])) : w("", !0)
|
|
207
|
+
], 64)) : w("", !0),
|
|
208
208
|
f(me, {
|
|
209
209
|
proxyUrl: e.configuration.proxy,
|
|
210
210
|
servers: e.configuration.servers,
|
|
@@ -217,5 +217,5 @@ const Le = ["innerHTML"], Ee = { class: "references-header" }, ke = {
|
|
|
217
217
|
}
|
|
218
218
|
});
|
|
219
219
|
export {
|
|
220
|
-
|
|
220
|
+
xe as default
|
|
221
221
|
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { defineComponent as E, ref as v, watch as K, onMounted as M, withDirectives as $, openBlock as n, createElementBlock as f, normalizeClass as j, Fragment as g, renderList as k, createBlock as m, unref as o, withCtx as p, createCommentVNode as w, createVNode as T, createTextVNode as A, toDisplayString as F, vShow as H } from "vue";
|
|
2
2
|
import { lazyBus as P } from "./lazyBus.js";
|
|
3
|
-
import { scrollToId as x } from "../../../helpers/scrollToId.js";
|
|
4
3
|
import q from "../Tag/Tag.vue.js";
|
|
5
4
|
import G from "../Operation/Operation.vue.js";
|
|
6
5
|
import J from "../../Section/SectionContainer.vue.js";
|
|
@@ -10,6 +9,7 @@ import U from "../../Section/SectionHeader.vue.js";
|
|
|
10
9
|
import X from "../../Anchor/Anchor.vue.js";
|
|
11
10
|
import Y from "../Schema/Schema.vue.js";
|
|
12
11
|
import { getModels as h } from "../../../helpers/getModels.js";
|
|
12
|
+
import { scrollToId as x } from "../../../helpers/scrollToId.js";
|
|
13
13
|
import { useNavState as Z } from "../../../hooks/useNavState.js";
|
|
14
14
|
const fe = /* @__PURE__ */ E({
|
|
15
15
|
__name: "Loading",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ExampleResponse.vue.d.ts","sourceRoot":"","sources":["../../../../../src/components/Content/Operation/PathResponses/ExampleResponse.vue"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"ExampleResponse.vue.d.ts","sourceRoot":"","sources":["../../../../../src/components/Content/Operation/PathResponses/ExampleResponse.vue"],"names":[],"mappings":";cAkMM,SAAS,GACT;QACE,OAAO,CAAC,EAAE,GAAG,CAAA;QACb,MAAM,CAAC,EAAE,GAAG,CAAA;KACb;;cAJD,SAAS,GACT;QACE,OAAO,CAAC,EAAE,GAAG,CAAA;QACb,MAAM,CAAC,EAAE,GAAG,CAAA;KACb;;AAuSP,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 "./ExampleResponse.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import p from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const r = /* @__PURE__ */ p(o, [["__scopeId", "data-v-
|
|
4
|
+
const r = /* @__PURE__ */ p(o, [["__scopeId", "data-v-65d90380"]]);
|
|
5
5
|
export {
|
|
6
6
|
r as default
|
|
7
7
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as D, openBlock as o, createBlock as a, unref as s, createElementBlock as t, Fragment as
|
|
1
|
+
import { defineComponent as D, openBlock as o, createBlock as a, unref as s, createElementBlock as t, Fragment as c, renderList as v, createElementVNode as C, toDisplayString as J, createVNode as L, createCommentVNode as P } from "vue";
|
|
2
2
|
import { ScalarCodeBlock as r } from "@scalar/components";
|
|
3
|
-
import { prettyPrintJson as
|
|
3
|
+
import { prettyPrintJson as V } from "@scalar/oas-utils/helpers";
|
|
4
4
|
import { getExampleFromSchema as l } from "@scalar/oas-utils/spec-getters";
|
|
5
5
|
const R = {
|
|
6
6
|
key: 0,
|
|
@@ -14,29 +14,31 @@ const R = {
|
|
|
14
14
|
response: {}
|
|
15
15
|
},
|
|
16
16
|
setup(G) {
|
|
17
|
-
const
|
|
17
|
+
const F = ["oneOf", "anyOf", "not"], p = (e) => e.reduce((i, m) => ({
|
|
18
18
|
...i,
|
|
19
19
|
...m
|
|
20
20
|
}), {});
|
|
21
21
|
return (e, i) => {
|
|
22
|
-
var m, d, h, y,
|
|
22
|
+
var m, d, g, h, y, u, f, k, b;
|
|
23
23
|
return (m = e.response) != null && m.example ? (o(), a(s(r), {
|
|
24
24
|
key: 0,
|
|
25
|
-
|
|
25
|
+
class: "bg-b-2",
|
|
26
|
+
content: s(V)((d = e.response) == null ? void 0 : d.example),
|
|
26
27
|
lang: "json"
|
|
27
|
-
}, null, 8, ["content"])) : (
|
|
28
|
-
(o(), t(
|
|
29
|
-
var j, O, B, E, N
|
|
30
|
-
return o(), t(
|
|
31
|
-
(
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
(o(!0), t(
|
|
28
|
+
}, null, 8, ["content"])) : (g = e.response) != null && g.schema ? (o(), t(c, { key: 1 }, [
|
|
29
|
+
(o(), t(c, null, v(F, (n) => {
|
|
30
|
+
var S, j, O, B, E, N;
|
|
31
|
+
return o(), t(c, { key: n }, [
|
|
32
|
+
(S = e.response) != null && S.schema[n] && (((j = e.response) == null ? void 0 : j.schema[n].length) > 1 || n === "not") ? (o(), t("div", R, [
|
|
33
|
+
C("div", q, J(n), 1),
|
|
34
|
+
C("ol", w, [
|
|
35
|
+
(o(!0), t(c, null, v((O = e.response) == null ? void 0 : O.schema[n], (_, A) => (o(), t("li", {
|
|
35
36
|
key: A,
|
|
36
37
|
class: "rule-item"
|
|
37
38
|
}, [
|
|
38
39
|
L(s(r), {
|
|
39
|
-
|
|
40
|
+
class: "bg-b-2",
|
|
41
|
+
content: s(l)(_, {
|
|
40
42
|
emptyString: "…",
|
|
41
43
|
mode: "read"
|
|
42
44
|
}),
|
|
@@ -44,9 +46,10 @@ const R = {
|
|
|
44
46
|
}, null, 8, ["content"])
|
|
45
47
|
]))), 128))
|
|
46
48
|
])
|
|
47
|
-
])) : (
|
|
49
|
+
])) : (B = e.response) != null && B.schema[n] && ((E = e.response) == null ? void 0 : E.schema[n].length) === 1 ? (o(), a(s(r), {
|
|
48
50
|
key: 1,
|
|
49
|
-
|
|
51
|
+
class: "bg-b-2",
|
|
52
|
+
content: s(l)((N = e.response) == null ? void 0 : N.schema[n][0], {
|
|
50
53
|
emptyString: "…",
|
|
51
54
|
mode: "read"
|
|
52
55
|
}),
|
|
@@ -54,10 +57,11 @@ const R = {
|
|
|
54
57
|
}, null, 8, ["content"])) : P("", !0)
|
|
55
58
|
], 64);
|
|
56
59
|
}), 64)),
|
|
57
|
-
(
|
|
60
|
+
(h = e.response) != null && h.schema.allOf ? (o(), a(s(r), {
|
|
58
61
|
key: 0,
|
|
59
|
-
|
|
60
|
-
|
|
62
|
+
class: "bg-b-2",
|
|
63
|
+
content: p(
|
|
64
|
+
(y = e.response) == null ? void 0 : y.schema.allOf.map(
|
|
61
65
|
(n) => s(l)(n, {
|
|
62
66
|
emptyString: "…",
|
|
63
67
|
mode: "read"
|
|
@@ -67,7 +71,8 @@ const R = {
|
|
|
67
71
|
lang: "json"
|
|
68
72
|
}, null, 8, ["content"])) : (f = (u = e.response) == null ? void 0 : u.schema.items) != null && f.allOf ? (o(), a(s(r), {
|
|
69
73
|
key: 1,
|
|
70
|
-
|
|
74
|
+
class: "bg-b-2",
|
|
75
|
+
content: p(
|
|
71
76
|
(k = e.response) == null ? void 0 : k.schema.items.allOf.map(
|
|
72
77
|
(n) => s(l)(n, {
|
|
73
78
|
emptyString: "…",
|
|
@@ -78,8 +83,9 @@ const R = {
|
|
|
78
83
|
lang: "json"
|
|
79
84
|
}, null, 8, ["content"])) : (o(), a(s(r), {
|
|
80
85
|
key: 2,
|
|
81
|
-
|
|
82
|
-
|
|
86
|
+
class: "bg-b-2",
|
|
87
|
+
content: s(V)(
|
|
88
|
+
s(l)((b = e.response) == null ? void 0 : b.schema, {
|
|
83
89
|
emptyString: "…",
|
|
84
90
|
mode: "read"
|
|
85
91
|
})
|
|
@@ -2,14 +2,10 @@ import type { Tag } from '@scalar/oas-utils';
|
|
|
2
2
|
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
3
3
|
id?: string;
|
|
4
4
|
tag: Tag;
|
|
5
|
-
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
6
|
-
observeAndNavigate: (value: string) => void;
|
|
7
|
-
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
5
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
8
6
|
id?: string;
|
|
9
7
|
tag: Tag;
|
|
10
|
-
}
|
|
11
|
-
onObserveAndNavigate?: ((value: string) => any) | undefined;
|
|
12
|
-
}, {}, {}>;
|
|
8
|
+
}>>>, {}, {}>;
|
|
13
9
|
export default _default;
|
|
14
10
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
15
11
|
type __VLS_TypePropsToOption<T> = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Endpoints.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Content/Tag/Endpoints.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Endpoints.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Content/Tag/Endpoints.vue"],"names":[],"mappings":"AAuHA,OAAO,KAAK,EAAE,GAAG,EAAwB,MAAM,mBAAmB,CAAA;;SAgBrC,MAAM;SAAO,GAAG;;SAAhB,MAAM;SAAO,GAAG;;AA2Q7C,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 "./Endpoints.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-416f90b1"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|
|
@@ -1,97 +1,94 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ScalarMarkdown as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import { useSidebar as
|
|
14
|
-
import { useNavState as
|
|
15
|
-
const
|
|
1
|
+
import { defineComponent as v, openBlock as n, createBlock as s, unref as e, withCtx as o, createVNode as a, createTextVNode as c, toDisplayString as p, createElementVNode as u, createElementBlock as f, Fragment as y, renderList as N, normalizeClass as V, createCommentVNode as b } from "vue";
|
|
2
|
+
import { ScalarMarkdown as E } from "@scalar/components";
|
|
3
|
+
import I from "../../Section/Section.vue.js";
|
|
4
|
+
import w from "../../Section/SectionContent.vue.js";
|
|
5
|
+
import B from "../../Section/SectionColumns.vue.js";
|
|
6
|
+
import g from "../../Section/SectionColumn.vue.js";
|
|
7
|
+
import H from "../../Section/SectionHeader.vue.js";
|
|
8
|
+
import T from "../../Anchor/Anchor.vue.js";
|
|
9
|
+
import O from "../../Card/Card.vue.js";
|
|
10
|
+
import $ from "../../Card/CardHeader.vue.js";
|
|
11
|
+
import z from "../../Card/CardContent.vue.js";
|
|
12
|
+
import A from "../../HttpMethod/HttpMethod.vue.js";
|
|
13
|
+
import { useSidebar as D } from "../../../hooks/useSidebar.js";
|
|
14
|
+
import { useNavState as F } from "../../../hooks/useNavState.js";
|
|
15
|
+
const L = { class: "endpoints" }, M = ["onClick"], te = /* @__PURE__ */ v({
|
|
16
16
|
__name: "Endpoints",
|
|
17
17
|
props: {
|
|
18
18
|
id: {},
|
|
19
19
|
tag: {}
|
|
20
20
|
},
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
setup(C) {
|
|
22
|
+
const _ = C, { getOperationId: l, getTagId: h } = F(), { scrollToOperation: k } = D(), S = async (t) => {
|
|
23
|
+
const d = l(t, _.tag);
|
|
24
|
+
k(d);
|
|
25
25
|
};
|
|
26
|
-
|
|
27
|
-
k(i(t, l.tag)), S(d(l.tag), !0);
|
|
28
|
-
}
|
|
29
|
-
return (t, q) => (n(), c(e(A), {
|
|
26
|
+
return (t, d) => (n(), s(e(I), {
|
|
30
27
|
id: t.id,
|
|
31
28
|
label: t.tag.name.toUpperCase()
|
|
32
29
|
}, {
|
|
33
|
-
default:
|
|
34
|
-
|
|
35
|
-
default:
|
|
36
|
-
|
|
37
|
-
default:
|
|
38
|
-
|
|
39
|
-
default:
|
|
40
|
-
|
|
41
|
-
default:
|
|
42
|
-
|
|
43
|
-
id: e(
|
|
30
|
+
default: o(() => [
|
|
31
|
+
a(e(w), null, {
|
|
32
|
+
default: o(() => [
|
|
33
|
+
a(e(B), null, {
|
|
34
|
+
default: o(() => [
|
|
35
|
+
a(e(g), null, {
|
|
36
|
+
default: o(() => [
|
|
37
|
+
a(e(H), { level: 2 }, {
|
|
38
|
+
default: o(() => [
|
|
39
|
+
a(e(T), {
|
|
40
|
+
id: e(h)(t.tag)
|
|
44
41
|
}, {
|
|
45
|
-
default:
|
|
46
|
-
p(
|
|
42
|
+
default: o(() => [
|
|
43
|
+
c(p(t.tag["x-displayName"] ?? t.tag.name), 1)
|
|
47
44
|
]),
|
|
48
45
|
_: 1
|
|
49
46
|
}, 8, ["id"])
|
|
50
47
|
]),
|
|
51
48
|
_: 1
|
|
52
49
|
}),
|
|
53
|
-
|
|
50
|
+
a(e(E), {
|
|
54
51
|
value: t.tag.description,
|
|
55
52
|
withImages: ""
|
|
56
53
|
}, null, 8, ["value"])
|
|
57
54
|
]),
|
|
58
55
|
_: 1
|
|
59
56
|
}),
|
|
60
|
-
|
|
61
|
-
default:
|
|
62
|
-
var
|
|
57
|
+
a(e(g), null, {
|
|
58
|
+
default: o(() => {
|
|
59
|
+
var i;
|
|
63
60
|
return [
|
|
64
|
-
((
|
|
61
|
+
((i = t.tag.operations) == null ? void 0 : i.length) > 0 ? (n(), s(e(O), {
|
|
65
62
|
key: 0,
|
|
66
63
|
class: "scalar-card-sticky"
|
|
67
64
|
}, {
|
|
68
|
-
default:
|
|
69
|
-
|
|
70
|
-
default:
|
|
71
|
-
|
|
65
|
+
default: o(() => [
|
|
66
|
+
a(e($), { muted: "" }, {
|
|
67
|
+
default: o(() => [
|
|
68
|
+
c("Endpoints")
|
|
72
69
|
]),
|
|
73
70
|
_: 1
|
|
74
71
|
}),
|
|
75
|
-
|
|
72
|
+
a(e(z), {
|
|
76
73
|
class: "custom-scroll",
|
|
77
74
|
muted: ""
|
|
78
75
|
}, {
|
|
79
|
-
default:
|
|
80
|
-
|
|
81
|
-
(n(!0),
|
|
82
|
-
var
|
|
83
|
-
return n(),
|
|
84
|
-
key: e(
|
|
76
|
+
default: o(() => [
|
|
77
|
+
u("div", L, [
|
|
78
|
+
(n(!0), f(y, null, N(t.tag.operations, (r) => {
|
|
79
|
+
var m;
|
|
80
|
+
return n(), f("a", {
|
|
81
|
+
key: e(l)(r, t.tag),
|
|
85
82
|
class: "endpoint",
|
|
86
|
-
onClick: (
|
|
83
|
+
onClick: (U) => S(r)
|
|
87
84
|
}, [
|
|
88
|
-
|
|
85
|
+
a(e(A), {
|
|
89
86
|
method: r.httpVerb
|
|
90
87
|
}, null, 8, ["method"]),
|
|
91
|
-
|
|
92
|
-
class:
|
|
93
|
-
},
|
|
94
|
-
], 8,
|
|
88
|
+
u("span", {
|
|
89
|
+
class: V({ deprecated: (m = r.information) == null ? void 0 : m.deprecated })
|
|
90
|
+
}, p(r.path), 3)
|
|
91
|
+
], 8, M);
|
|
95
92
|
}), 128))
|
|
96
93
|
])
|
|
97
94
|
]),
|
|
@@ -99,7 +96,7 @@ const U = { class: "endpoints" }, j = ["onClick"], re = /* @__PURE__ */ b({
|
|
|
99
96
|
})
|
|
100
97
|
]),
|
|
101
98
|
_: 1
|
|
102
|
-
})) :
|
|
99
|
+
})) : b("", !0)
|
|
103
100
|
];
|
|
104
101
|
}),
|
|
105
102
|
_: 1
|
|
@@ -116,5 +113,5 @@ const U = { class: "endpoints" }, j = ["onClick"], re = /* @__PURE__ */ b({
|
|
|
116
113
|
}
|
|
117
114
|
});
|
|
118
115
|
export {
|
|
119
|
-
|
|
116
|
+
te as default
|
|
120
117
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tag.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Content/Tag/Tag.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Tag.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Content/Tag/Tag.vue"],"names":[],"mappings":"AAqDA,OAAO,KAAK,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAA;AAkClD,iBAAS,cAAc;qBA6DO,GAAG;EAqBhC;AACD,QAAA,MAAM,eAAe;SA1Gd,MAAM;SACN,GAAG;UACF,IAAI;;SAFL,MAAM;SACN,GAAG;UACF,IAAI;aA8GV,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"}
|