@scalar/api-reference 1.25.127 → 1.25.128
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 +29 -0
- package/dist/browser/standalone.js +16046 -15965
- package/dist/browser/webpack-stats.json +1 -1
- package/dist/components/ApiReference.vue.d.ts.map +1 -1
- package/dist/components/ApiReference.vue.js +40 -64
- package/dist/components/ApiReferenceLayout.vue.d.ts +2 -2
- package/dist/components/ApiReferenceLayout.vue.d.ts.map +1 -1
- package/dist/components/ApiReferenceLayout.vue.js +2 -2
- package/dist/components/ApiReferenceLayout.vue2.js +158 -159
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue.d.ts.map +1 -1
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue.js +1 -1
- package/dist/components/Content/ClientLibraries/ClientLibraries.vue2.js +69 -17
- package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts +5 -1
- package/dist/components/Content/ClientLibraries/ClientSelector.vue.d.ts.map +1 -1
- package/dist/components/Content/ClientLibraries/ClientSelector.vue.js +2 -2
- package/dist/components/Content/ClientLibraries/ClientSelector.vue2.js +73 -94
- package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts +16 -0
- package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.d.ts.map +1 -0
- package/dist/components/Content/ClientLibraries/useFeaturedHttpClients.js +36 -0
- package/dist/components/Content/Schema/Schema.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/Schema.vue.js +2 -2
- package/dist/components/Content/Schema/Schema.vue2.js +4 -1
- package/dist/components/Content/Schema/SchemaProperty.vue.d.ts +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue.js +1 -1
- package/dist/components/Content/Schema/SchemaProperty.vue2.js +1 -1
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.d.ts.map +1 -1
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue.js +2 -2
- package/dist/components/Content/Schema/SchemaPropertyHeading.vue2.js +143 -124
- package/dist/components/GettingStarted.vue.d.ts.map +1 -1
- package/dist/components/GettingStarted.vue.js +1 -1
- package/dist/components/GettingStarted.vue2.js +13 -13
- package/dist/components/Layouts/ClassicLayout.vue.d.ts +3 -3
- package/dist/components/Layouts/ClassicLayout.vue.d.ts.map +1 -1
- package/dist/components/Layouts/Layouts.vue.d.ts +3 -3
- package/dist/components/Layouts/Layouts.vue.d.ts.map +1 -1
- package/dist/components/Layouts/ModernLayout.vue.d.ts +3 -3
- package/dist/components/Layouts/ModernLayout.vue.d.ts.map +1 -1
- package/dist/components/Layouts/ModernLayout.vue.js +2 -2
- package/dist/components/Section/CompactSection.vue.d.ts.map +1 -1
- package/dist/components/Section/CompactSection.vue.js +2 -2
- package/dist/components/Section/CompactSection.vue2.js +30 -29
- package/dist/esm.d.ts +5 -3
- package/dist/esm.d.ts.map +1 -1
- package/dist/features/ApiClientModal/ApiClientModal.vue.d.ts +2 -2
- package/dist/features/ApiClientModal/ApiClientModal.vue.d.ts.map +1 -1
- package/dist/features/ApiClientModal/useApiClient.d.ts +362 -342
- package/dist/features/ApiClientModal/useApiClient.d.ts.map +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue.d.ts.map +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue.js +1 -1
- package/dist/features/ExampleRequest/ExampleRequest.vue2.js +82 -74
- package/dist/features/ExampleResponses/ExampleResponse.vue.d.ts.map +1 -1
- package/dist/features/ExampleResponses/ExampleResponse.vue.js +2 -2
- package/dist/features/ExampleResponses/ExampleResponse.vue2.js +11 -11
- package/dist/features/ExampleResponses/ExampleResponses.vue.d.ts.map +1 -1
- package/dist/features/ExampleResponses/ExampleResponses.vue.js +2 -2
- package/dist/features/ExampleResponses/ExampleResponses.vue2.js +90 -78
- package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts +1 -1
- package/dist/features/Operation/components/ContentTypeSelect.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/ContentTypeSelect.vue.js +1 -1
- package/dist/features/Operation/components/ContentTypeSelect.vue2.js +29 -25
- package/dist/features/Operation/components/ParameterListItem.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/ParameterListItem.vue.js +1 -1
- package/dist/features/Operation/components/ParameterListItem.vue2.js +40 -47
- package/dist/features/Operation/components/RequestBody.vue.d.ts.map +1 -1
- package/dist/features/Operation/components/RequestBody.vue.js +2 -2
- package/dist/features/Operation/layouts/ModernLayout.vue.js +2 -2
- package/dist/helpers/get-request.d.ts +1 -1
- package/dist/helpers/get-request.d.ts.map +1 -1
- package/dist/hooks/index.d.ts +0 -1
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/useConfig.d.ts +3 -3
- package/dist/hooks/useConfig.d.ts.map +1 -1
- package/dist/hooks/useConfig.js +5 -4
- package/dist/index.js +17 -19
- package/dist/standalone/lib/html-api.d.ts +3 -3
- package/dist/standalone/lib/html-api.d.ts.map +1 -1
- package/dist/standalone/lib/html-rendering.d.ts +23 -24
- package/dist/standalone/lib/html-rendering.d.ts.map +1 -1
- package/dist/standalone/lib/html-rendering.js +39 -29
- package/dist/stores/useHttpClientStore.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types.d.ts +19 -2
- package/dist/types.d.ts.map +1 -1
- package/package.json +11 -10
- package/dist/hooks/useDeprecationWarnings.d.ts +0 -6
- package/dist/hooks/useDeprecationWarnings.d.ts.map +0 -1
- package/dist/hooks/useDeprecationWarnings.js +0 -20
|
@@ -1,33 +1,34 @@
|
|
|
1
|
-
import { defineComponent as M, useId as N, ref as
|
|
1
|
+
import { defineComponent as M, useId as N, ref as S, computed as d, openBlock as o, createBlock as t, unref as l, withCtx as u, createVNode as v, createElementBlock as x, createCommentVNode as f, createTextVNode as E, withDirectives as F, createElementVNode as R, vModelCheckbox as I, Fragment as T, renderList as O, toDisplayString as A } from "vue";
|
|
2
2
|
import { ScalarIcon as D, ScalarCodeBlock as P, ScalarMarkdown as U } from "@scalar/components";
|
|
3
3
|
import { normalizeMimeTypeObject as H } from "@scalar/oas-utils/helpers";
|
|
4
4
|
import { useClipboard as J } from "@scalar/use-hooks/useClipboard";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import L from "../../components/Card/
|
|
8
|
-
import W from "../../components/Card/
|
|
9
|
-
import q from "../../components/Card/
|
|
10
|
-
import G from "../../components/Card/
|
|
11
|
-
import Q from "
|
|
12
|
-
|
|
5
|
+
import K from "../../components/ScreenReader.vue.js";
|
|
6
|
+
import V from "./ExampleResponse.vue.js";
|
|
7
|
+
import L from "../../components/Card/Card.vue.js";
|
|
8
|
+
import W from "../../components/Card/CardTabHeader.vue.js";
|
|
9
|
+
import q from "../../components/Card/CardTab.vue.js";
|
|
10
|
+
import G from "../../components/Card/CardContent.vue.js";
|
|
11
|
+
import Q from "../../components/Card/CardFooter.vue.js";
|
|
12
|
+
import X from "../ExampleRequest/ExamplePicker.vue.js";
|
|
13
|
+
const Y = {
|
|
13
14
|
key: 1,
|
|
14
15
|
class: "scalar-card-checkbox"
|
|
15
|
-
},
|
|
16
|
+
}, Z = ["aria-controls"], $ = { class: "scalar-card-container custom-scroll" }, z = {
|
|
16
17
|
key: 1,
|
|
17
18
|
class: "response-description"
|
|
18
|
-
},
|
|
19
|
+
}, me = /* @__PURE__ */ M({
|
|
19
20
|
__name: "ExampleResponses",
|
|
20
21
|
props: {
|
|
21
22
|
responses: {}
|
|
22
23
|
},
|
|
23
|
-
setup(
|
|
24
|
-
const
|
|
25
|
-
() => !!
|
|
26
|
-
),
|
|
24
|
+
setup(g) {
|
|
25
|
+
const c = N(), { copyToClipboard: _ } = J(), p = S(), b = d(() => Object.keys(g.responses ?? {}).sort()), k = d(
|
|
26
|
+
() => !!s.value.examples
|
|
27
|
+
), C = S(0), i = d(() => {
|
|
27
28
|
var a;
|
|
28
|
-
const e = b.value[
|
|
29
|
-
return (a =
|
|
30
|
-
}),
|
|
29
|
+
const e = b.value[C.value];
|
|
30
|
+
return (a = g.responses) == null ? void 0 : a[e];
|
|
31
|
+
}), s = d(() => {
|
|
31
32
|
var a;
|
|
32
33
|
const e = H(
|
|
33
34
|
(a = i.value) == null ? void 0 : a.content
|
|
@@ -39,127 +40,138 @@ const X = {
|
|
|
39
40
|
);
|
|
40
41
|
}), j = () => {
|
|
41
42
|
if (k.value) {
|
|
42
|
-
if (Array.isArray(
|
|
43
|
-
return
|
|
43
|
+
if (Array.isArray(s.value.examples))
|
|
44
|
+
return s.value.examples[0];
|
|
44
45
|
{
|
|
45
|
-
const e = Object.keys(
|
|
46
|
-
return
|
|
46
|
+
const e = Object.keys(s.value.examples)[0];
|
|
47
|
+
return s.value.examples[e];
|
|
47
48
|
}
|
|
48
|
-
} else return
|
|
49
|
-
},
|
|
50
|
-
...
|
|
51
|
-
example: k.value && p.value ?
|
|
49
|
+
} else return s.value.example;
|
|
50
|
+
}, y = d(() => ({
|
|
51
|
+
...s.value,
|
|
52
|
+
example: k.value && p.value ? s.value.examples[p.value].value ?? s.value.examples[p.value] : j()
|
|
52
53
|
})), B = (e) => {
|
|
53
|
-
|
|
54
|
-
}, h =
|
|
55
|
-
return (e, a) => b.value.length ? (o(),
|
|
56
|
-
|
|
54
|
+
C.value = e, p.value = void 0;
|
|
55
|
+
}, h = S(!1);
|
|
56
|
+
return (e, a) => b.value.length ? (o(), t(l(L), {
|
|
57
|
+
key: 0,
|
|
58
|
+
"aria-label": "Example Responses",
|
|
59
|
+
role: "region"
|
|
60
|
+
}, {
|
|
61
|
+
default: u(() => {
|
|
57
62
|
var w;
|
|
58
63
|
return [
|
|
59
|
-
|
|
64
|
+
v(l(W), {
|
|
60
65
|
muted: "",
|
|
61
66
|
x: "as",
|
|
62
67
|
onChange: B
|
|
63
68
|
}, {
|
|
64
|
-
actions:
|
|
65
|
-
var
|
|
69
|
+
actions: u(() => {
|
|
70
|
+
var r, m;
|
|
66
71
|
return [
|
|
67
|
-
(
|
|
72
|
+
(r = s.value) != null && r.example ? (o(), x("button", {
|
|
68
73
|
key: 0,
|
|
69
74
|
class: "code-copy",
|
|
70
75
|
type: "button",
|
|
71
76
|
onClick: a[0] || (a[0] = () => {
|
|
72
|
-
var
|
|
73
|
-
return
|
|
77
|
+
var n;
|
|
78
|
+
return l(_)((n = s.value) == null ? void 0 : n.example);
|
|
74
79
|
})
|
|
75
80
|
}, [
|
|
76
|
-
|
|
81
|
+
v(l(D), {
|
|
77
82
|
icon: "Clipboard",
|
|
78
83
|
width: "12px"
|
|
79
84
|
})
|
|
80
|
-
])) :
|
|
81
|
-
(m =
|
|
82
|
-
a[
|
|
83
|
-
F(
|
|
84
|
-
"onUpdate:modelValue": a[1] || (a[1] = (
|
|
85
|
-
"aria-controls":
|
|
85
|
+
])) : f("", !0),
|
|
86
|
+
(m = s.value) != null && m.schema ? (o(), x("label", Y, [
|
|
87
|
+
a[4] || (a[4] = E(" Show Schema ")),
|
|
88
|
+
F(R("input", {
|
|
89
|
+
"onUpdate:modelValue": a[1] || (a[1] = (n) => h.value = n),
|
|
90
|
+
"aria-controls": l(c),
|
|
86
91
|
class: "scalar-card-checkbox-input",
|
|
87
92
|
type: "checkbox"
|
|
88
|
-
}, null, 8,
|
|
93
|
+
}, null, 8, Z), [
|
|
89
94
|
[I, h.value]
|
|
90
95
|
]),
|
|
91
|
-
a[
|
|
92
|
-
])) :
|
|
96
|
+
a[5] || (a[5] = R("span", { class: "scalar-card-checkbox-checkmark" }, null, -1))
|
|
97
|
+
])) : f("", !0)
|
|
93
98
|
];
|
|
94
99
|
}),
|
|
95
|
-
default:
|
|
96
|
-
(o(!0),
|
|
97
|
-
key:
|
|
98
|
-
"aria-controls":
|
|
100
|
+
default: u(() => [
|
|
101
|
+
(o(!0), x(T, null, O(b.value, (r) => (o(), t(l(q), {
|
|
102
|
+
key: r,
|
|
103
|
+
"aria-controls": l(c)
|
|
99
104
|
}, {
|
|
100
|
-
default:
|
|
101
|
-
|
|
105
|
+
default: u(() => [
|
|
106
|
+
v(K, null, {
|
|
107
|
+
default: u(() => a[3] || (a[3] = [
|
|
108
|
+
E("Status:")
|
|
109
|
+
])),
|
|
110
|
+
_: 1
|
|
111
|
+
}),
|
|
112
|
+
E(" " + A(r), 1)
|
|
102
113
|
]),
|
|
103
114
|
_: 2
|
|
104
115
|
}, 1032, ["aria-controls"]))), 128))
|
|
105
116
|
]),
|
|
106
117
|
_: 1
|
|
107
118
|
}),
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
default:
|
|
111
|
-
var
|
|
119
|
+
R("div", $, [
|
|
120
|
+
v(l(G), { muted: "" }, {
|
|
121
|
+
default: u(() => {
|
|
122
|
+
var r;
|
|
112
123
|
return [
|
|
113
|
-
(
|
|
114
|
-
h.value &&
|
|
124
|
+
(r = s.value) != null && r.schema ? (o(), x(T, { key: 0 }, [
|
|
125
|
+
h.value && y.value ? (o(), t(l(P), {
|
|
115
126
|
key: 0,
|
|
116
|
-
id:
|
|
117
|
-
|
|
127
|
+
id: l(c),
|
|
128
|
+
class: "-outline-offset-2",
|
|
129
|
+
content: y.value,
|
|
118
130
|
lang: "json"
|
|
119
|
-
}, null, 8, ["id", "content"])) : (o(),
|
|
131
|
+
}, null, 8, ["id", "content"])) : (o(), t(V, {
|
|
120
132
|
key: 1,
|
|
121
|
-
id:
|
|
122
|
-
response:
|
|
133
|
+
id: l(c),
|
|
134
|
+
response: y.value
|
|
123
135
|
}, null, 8, ["id", "response"]))
|
|
124
|
-
], 64)) : (o(),
|
|
136
|
+
], 64)) : (o(), t(V, {
|
|
125
137
|
key: 1,
|
|
126
|
-
id:
|
|
127
|
-
response:
|
|
138
|
+
id: l(c),
|
|
139
|
+
response: y.value
|
|
128
140
|
}, null, 8, ["id", "response"]))
|
|
129
141
|
];
|
|
130
142
|
}),
|
|
131
143
|
_: 1
|
|
132
144
|
})
|
|
133
145
|
]),
|
|
134
|
-
(w = i.value) != null && w.description || k.value ? (o(),
|
|
146
|
+
(w = i.value) != null && w.description || k.value ? (o(), t(l(Q), {
|
|
135
147
|
key: 0,
|
|
136
148
|
class: "response-card-footer",
|
|
137
149
|
muted: ""
|
|
138
150
|
}, {
|
|
139
|
-
default:
|
|
140
|
-
var
|
|
151
|
+
default: u(() => {
|
|
152
|
+
var r, m;
|
|
141
153
|
return [
|
|
142
|
-
k.value ? (o(),
|
|
154
|
+
k.value ? (o(), t(l(X), {
|
|
143
155
|
key: 0,
|
|
144
156
|
class: "response-example-selector",
|
|
145
|
-
examples: (
|
|
146
|
-
"onUpdate:modelValue": a[2] || (a[2] = (
|
|
147
|
-
}, null, 8, ["examples"])) : (m = i.value) != null && m.description ? (o(),
|
|
148
|
-
|
|
157
|
+
examples: (r = s.value) == null ? void 0 : r.examples,
|
|
158
|
+
"onUpdate:modelValue": a[2] || (a[2] = (n) => p.value = n)
|
|
159
|
+
}, null, 8, ["examples"])) : (m = i.value) != null && m.description ? (o(), x("div", z, [
|
|
160
|
+
v(l(U), {
|
|
149
161
|
class: "markdown",
|
|
150
162
|
value: i.value.description
|
|
151
163
|
}, null, 8, ["value"])
|
|
152
|
-
])) :
|
|
164
|
+
])) : f("", !0)
|
|
153
165
|
];
|
|
154
166
|
}),
|
|
155
167
|
_: 1
|
|
156
|
-
})) :
|
|
168
|
+
})) : f("", !0)
|
|
157
169
|
];
|
|
158
170
|
}),
|
|
159
171
|
_: 1
|
|
160
|
-
})) :
|
|
172
|
+
})) : f("", !0);
|
|
161
173
|
}
|
|
162
174
|
});
|
|
163
175
|
export {
|
|
164
|
-
|
|
176
|
+
me as default
|
|
165
177
|
};
|
|
@@ -11,6 +11,6 @@ declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {
|
|
|
11
11
|
onSelectContentType?: ((payload: {
|
|
12
12
|
contentType: ContentType;
|
|
13
13
|
}) => any) | undefined;
|
|
14
|
-
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {},
|
|
14
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, HTMLLabelElement>;
|
|
15
15
|
export default _default;
|
|
16
16
|
//# sourceMappingURL=ContentTypeSelect.vue.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ContentTypeSelect.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ContentTypeSelect.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ContentTypeSelect.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ContentTypeSelect.vue"],"names":[],"mappings":"AAoIA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAA;AAKpE,KAAK,WAAW,GAAG;IACjB,WAAW,CAAC,EAAE,WAAW,CAAA;IACzB,YAAY,CAAC,EAAE,WAAW,CAAA;CAC3B,CAAC;;;qBAIiD,WAAW;;;;qBAAX,WAAW;;;AA4G9D,wBAQG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import t from "./ContentTypeSelect.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import o from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const r = /* @__PURE__ */ o(t, [["__scopeId", "data-v-
|
|
4
|
+
const r = /* @__PURE__ */ o(t, [["__scopeId", "data-v-3c443fc4"]]);
|
|
5
5
|
export {
|
|
6
6
|
r as default
|
|
7
7
|
};
|
|
@@ -1,41 +1,45 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as f, computed as g, ref as C, openBlock as l, createElementBlock as s, normalizeClass as B, createElementVNode as T, toDisplayString as d, withModifiers as p, Fragment as q, renderList as _, createCommentVNode as V } from "vue";
|
|
2
|
+
const h = ["value"], w = ["value"], b = /* @__PURE__ */ f({
|
|
3
3
|
__name: "ContentTypeSelect",
|
|
4
4
|
props: {
|
|
5
5
|
requestBody: {},
|
|
6
6
|
defaultValue: {}
|
|
7
7
|
},
|
|
8
8
|
emits: ["selectContentType"],
|
|
9
|
-
setup(
|
|
10
|
-
const e =
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
},
|
|
14
|
-
var t;
|
|
15
|
-
return (t = e.requestBody) != null && t.content ? Object.keys(e.requestBody.content) : [];
|
|
16
|
-
}), a = C(
|
|
17
|
-
e.defaultValue || s.value[0]
|
|
18
|
-
);
|
|
19
|
-
return (t, c) => {
|
|
9
|
+
setup(i, { emit: y }) {
|
|
10
|
+
const e = i, m = y, v = (n) => {
|
|
11
|
+
const o = n.target.value;
|
|
12
|
+
u.value = o, m("selectContentType", { contentType: o });
|
|
13
|
+
}, r = g(() => {
|
|
20
14
|
var n;
|
|
21
|
-
return
|
|
22
|
-
|
|
15
|
+
return (n = e.requestBody) != null && n.content ? Object.keys(e.requestBody.content) : [];
|
|
16
|
+
}), u = C(
|
|
17
|
+
e.defaultValue || r.value[0]
|
|
18
|
+
);
|
|
19
|
+
return (n, t) => {
|
|
20
|
+
var o;
|
|
21
|
+
return l(), s("label", {
|
|
22
|
+
class: B(["content-type-select", { "content-type-no-select": r.value.length <= 1 }])
|
|
23
23
|
}, [
|
|
24
|
-
|
|
25
|
-
e != null && e.requestBody &&
|
|
24
|
+
T("span", null, d(u.value), 1),
|
|
25
|
+
e != null && e.requestBody && r.value.length > 1 ? (l(), s("select", {
|
|
26
26
|
key: 0,
|
|
27
|
-
value:
|
|
28
|
-
onChange:
|
|
27
|
+
value: u.value,
|
|
28
|
+
onChange: t[1] || (t[1] = (c) => v(c)),
|
|
29
|
+
onKeydown: t[2] || (t[2] = p(() => {
|
|
30
|
+
}, ["stop"]))
|
|
29
31
|
}, [
|
|
30
|
-
(
|
|
31
|
-
key:
|
|
32
|
-
value:
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
(l(!0), s(q, null, _((o = e.requestBody) == null ? void 0 : o.content, (c, a) => (l(), s("option", {
|
|
33
|
+
key: a,
|
|
34
|
+
value: a,
|
|
35
|
+
onKeydown: t[0] || (t[0] = p(() => {
|
|
36
|
+
}, ["stop"]))
|
|
37
|
+
}, d(a), 41, w))), 128))
|
|
38
|
+
], 40, h)) : V("", !0)
|
|
35
39
|
], 2);
|
|
36
40
|
};
|
|
37
41
|
}
|
|
38
42
|
});
|
|
39
43
|
export {
|
|
40
|
-
|
|
44
|
+
b as default
|
|
41
45
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ParameterListItem.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ParameterListItem.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ParameterListItem.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/ParameterListItem.vue"],"names":[],"mappings":"AAwOA,OAAO,KAAK,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,iCAAiC,CAAA;AAY/E,KAAK,WAAW,GAAG;IACf,SAAS,EACL,WAAW,CAAC,aAAa,CAAC,YAAY,CAAC,CAAC,CAAC,MAAM,CAAC,GAChD,WAAW,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC,CAAA;IACnD,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,YAAY,CAAC,EAAE,OAAO,CAAA;CACvB,CAAC;;kBADe,OAAO;kBAFP,OAAO;sBACH,OAAO;;AA+P9B,wBAOG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import t from "./ParameterListItem.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import o from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const e = /* @__PURE__ */ o(t, [["__scopeId", "data-v-
|
|
4
|
+
const e = /* @__PURE__ */ o(t, [["__scopeId", "data-v-18974874"]]);
|
|
5
5
|
export {
|
|
6
6
|
e as default
|
|
7
7
|
};
|
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { Disclosure as b, DisclosureButton as
|
|
1
|
+
import { defineComponent as k, computed as i, ref as w, openBlock as o, createElementBlock as C, createVNode as m, unref as a, withCtx as u, createBlock as p, normalizeClass as B, createElementVNode as c, toDisplayString as S, createCommentVNode as n } from "vue";
|
|
2
|
+
import { Disclosure as b, DisclosureButton as E, DisclosurePanel as q } from "@headlessui/vue";
|
|
3
3
|
import { ScalarIcon as D, ScalarMarkdown as P } from "@scalar/components";
|
|
4
|
-
import
|
|
5
|
-
import I from "./
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
const _ = {
|
|
4
|
+
import V from "./ContentTypeSelect.vue.js";
|
|
5
|
+
import I from "./ParameterHeaders.vue.js";
|
|
6
|
+
import T from "../../../components/Content/Schema/SchemaProperty.vue.js";
|
|
7
|
+
const j = {
|
|
9
8
|
key: 0,
|
|
10
9
|
class: "parameter-item"
|
|
11
|
-
},
|
|
10
|
+
}, N = { class: "parameter-item-name" }, O = { class: "parameter-item-type" }, _ = { class: "absolute right-0 top-2.5 opacity-0 group-focus-within/parameter-item-trigger:opacity-100 group-hover/parameter-item-trigger:opacity-100" }, F = /* @__PURE__ */ k({
|
|
12
11
|
__name: "ParameterListItem",
|
|
13
12
|
props: {
|
|
14
13
|
parameter: {},
|
|
@@ -16,69 +15,63 @@ const _ = {
|
|
|
16
15
|
collapsableItems: { type: Boolean, default: !1 },
|
|
17
16
|
withExamples: { type: Boolean, default: !0 }
|
|
18
17
|
},
|
|
19
|
-
setup(
|
|
20
|
-
const
|
|
21
|
-
|
|
18
|
+
setup(y) {
|
|
19
|
+
const t = y, v = i(() => t.parameter.content ? Object.keys(t.parameter.content) : []), l = w(
|
|
20
|
+
v.value[0]
|
|
22
21
|
);
|
|
23
|
-
|
|
24
|
-
const r =
|
|
25
|
-
return (e,
|
|
26
|
-
|
|
27
|
-
default:
|
|
28
|
-
r.value ? (o(),
|
|
22
|
+
t.parameter.content && "application/json" in t.parameter.content && (l.value = "application/json");
|
|
23
|
+
const r = i(() => !!(t.collapsableItems && t.parameter.content)), g = i(() => t.parameter.readOnly !== !0);
|
|
24
|
+
return (e, d) => g.value ? (o(), C("li", j, [
|
|
25
|
+
m(a(b), null, {
|
|
26
|
+
default: u(({ open: h }) => [
|
|
27
|
+
r.value ? (o(), p(a(E), {
|
|
29
28
|
key: 0,
|
|
30
|
-
class:
|
|
29
|
+
class: B(["parameter-item-trigger group/parameter-item-trigger flex", { "parameter-item-trigger-open": h }])
|
|
31
30
|
}, {
|
|
32
|
-
default:
|
|
33
|
-
|
|
31
|
+
default: u(() => [
|
|
32
|
+
m(a(D), {
|
|
34
33
|
class: "parameter-item-icon",
|
|
35
|
-
icon:
|
|
34
|
+
icon: h ? "ChevronDown" : "ChevronRight",
|
|
36
35
|
thickness: "1.5"
|
|
37
36
|
}, null, 8, ["icon"]),
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
]),
|
|
42
|
-
_: 2
|
|
43
|
-
}, 1024),
|
|
44
|
-
d("span", O, y(e.parameter.name), 1),
|
|
45
|
-
d("span", R, [
|
|
46
|
-
e.parameter.description ? (o(), i(t(P), {
|
|
37
|
+
c("span", N, S(e.parameter.name), 1),
|
|
38
|
+
c("span", O, [
|
|
39
|
+
e.parameter.description ? (o(), p(a(P), {
|
|
47
40
|
key: 0,
|
|
48
41
|
class: "markdown",
|
|
49
42
|
value: e.parameter.description
|
|
50
|
-
}, null, 8, ["value"])) :
|
|
43
|
+
}, null, 8, ["value"])) : n("", !0)
|
|
51
44
|
]),
|
|
52
|
-
|
|
53
|
-
r.value &&
|
|
45
|
+
c("div", _, [
|
|
46
|
+
r.value && t.parameter.content ? (o(), p(V, {
|
|
54
47
|
key: 0,
|
|
55
48
|
class: "parameter-item-content-type",
|
|
56
|
-
defaultValue:
|
|
57
|
-
requestBody:
|
|
58
|
-
onSelectContentType:
|
|
59
|
-
}, null, 8, ["defaultValue", "requestBody"])) :
|
|
49
|
+
defaultValue: l.value,
|
|
50
|
+
requestBody: t.parameter,
|
|
51
|
+
onSelectContentType: d[0] || (d[0] = ({ contentType: s }) => l.value = s)
|
|
52
|
+
}, null, 8, ["defaultValue", "requestBody"])) : n("", !0)
|
|
60
53
|
])
|
|
61
54
|
]),
|
|
62
55
|
_: 2
|
|
63
|
-
}, 1032, ["class"])) :
|
|
64
|
-
|
|
56
|
+
}, 1032, ["class"])) : n("", !0),
|
|
57
|
+
m(a(q), {
|
|
65
58
|
class: "parameter-item-container parameter-item-container-markdown",
|
|
66
59
|
static: !r.value
|
|
67
60
|
}, {
|
|
68
|
-
default:
|
|
69
|
-
var
|
|
61
|
+
default: u(() => {
|
|
62
|
+
var s, f;
|
|
70
63
|
return [
|
|
71
|
-
e.parameter.headers ? (o(),
|
|
64
|
+
e.parameter.headers ? (o(), p(I, {
|
|
72
65
|
key: 0,
|
|
73
66
|
headers: e.parameter.headers
|
|
74
|
-
}, null, 8, ["headers"])) :
|
|
75
|
-
|
|
67
|
+
}, null, 8, ["headers"])) : n("", !0),
|
|
68
|
+
m(a(T), {
|
|
76
69
|
compact: "",
|
|
77
70
|
description: r.value ? "" : e.parameter.description,
|
|
78
71
|
name: r.value ? "" : e.parameter.name,
|
|
79
72
|
noncollapsible: e.showChildren,
|
|
80
73
|
required: e.parameter.required,
|
|
81
|
-
value: e.parameter.content ? (
|
|
74
|
+
value: e.parameter.content ? (f = (s = e.parameter.content) == null ? void 0 : s[l.value]) == null ? void 0 : f.schema : e.parameter.schema,
|
|
82
75
|
withExamples: e.withExamples
|
|
83
76
|
}, null, 8, ["description", "name", "noncollapsible", "required", "value", "withExamples"])
|
|
84
77
|
];
|
|
@@ -88,9 +81,9 @@ const _ = {
|
|
|
88
81
|
]),
|
|
89
82
|
_: 1
|
|
90
83
|
})
|
|
91
|
-
])) :
|
|
84
|
+
])) : n("", !0);
|
|
92
85
|
}
|
|
93
86
|
});
|
|
94
87
|
export {
|
|
95
|
-
|
|
88
|
+
F as default
|
|
96
89
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RequestBody.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/RequestBody.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RequestBody.vue.d.ts","sourceRoot":"","sources":["../../../../src/features/Operation/components/RequestBody.vue"],"names":[],"mappings":"AAkIA,OAAO,KAAK,EAAe,WAAW,EAAE,MAAM,sBAAsB,CAAA;AASpE,KAAK,WAAW,GAAG;IAAE,WAAW,CAAC,EAAE,WAAW,CAAA;CAAE,CAAC;AAqBjD,iBAAS,cAAc;WAyFT,OAAO,IAA6B;;uBARvB,GAAG;;;;EAa7B;AAWD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe,kSAMnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAWpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./RequestBody.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-7637dd89"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./ModernLayout.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const f = /* @__PURE__ */ t(o, [["__scopeId", "data-v-2f5e19c3"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
f as default
|
|
7
7
|
};
|
|
@@ -31,7 +31,7 @@ export declare const getRequest: (requests: WorkspaceStore["requests"], path: st
|
|
|
31
31
|
schema?: unknown;
|
|
32
32
|
content?: unknown;
|
|
33
33
|
style?: "matrix" | "simple" | "form" | "label" | "spaceDelimited" | "pipeDelimited" | "deepObject" | undefined;
|
|
34
|
-
examples?: Record<string, {
|
|
34
|
+
examples?: unknown[] | Record<string, {
|
|
35
35
|
value?: unknown;
|
|
36
36
|
summary?: string | undefined;
|
|
37
37
|
}> | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-request.d.ts","sourceRoot":"","sources":["../../src/helpers/get-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AAE9D,6CAA6C;AAC7C,eAAO,MAAM,UAAU,aAAc,cAAc,CAAC,UAAU,CAAC,QAAQ,MAAM,UAAU,MAAM;;;
|
|
1
|
+
{"version":3,"file":"get-request.d.ts","sourceRoot":"","sources":["../../src/helpers/get-request.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AAE9D,6CAA6C;AAC7C,eAAO,MAAM,UAAU,aAAc,cAAc,CAAC,UAAU,CAAC,QAAQ,MAAM,UAAU,MAAM;;;yBAEoyT,KAAK;kDAA4E,KAAK,8CAA8C,KAAK;wCAA6E,KAAK;8BAA6D,KAAK;+BAAyD,KAAK;;;;;;mBAAwR,CAAC;;;;;;;;;;;;;eAA0f,CAAC;mBAAkC,CAAC;cAAwC,CAAC;eAA8B,CAAC;aAA4B,CAAC;gBAA8H,CAAC;iBAAoD,CAAC;mBAAkC,CAAC;;;;;aADtuW,CAAA"}
|
package/dist/hooks/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAA;AAChC,cAAc,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAA;AAChC,cAAc,eAAe,CAAA;AAC7B,cAAc,gBAAgB,CAAA;AAC9B,cAAc,mBAAmB,CAAA;AACjC,cAAc,iBAAiB,CAAA;AAC/B,cAAc,cAAc,CAAA"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import { type ApiReferenceConfiguration } from '@scalar/types/api-reference';
|
|
2
2
|
import { type InjectionKey } from 'vue';
|
|
3
|
-
export declare const CONFIGURATION_SYMBOL: InjectionKey<
|
|
3
|
+
export declare const CONFIGURATION_SYMBOL: InjectionKey<ApiReferenceConfiguration>;
|
|
4
4
|
/** Hook for easy access to the reference configuration */
|
|
5
|
-
export declare const useConfig: () =>
|
|
5
|
+
export declare const useConfig: () => ApiReferenceConfiguration;
|
|
6
6
|
//# sourceMappingURL=useConfig.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useConfig.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"useConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAmC,KAAK,yBAAyB,EAAE,MAAM,6BAA6B,CAAA;AAC7G,OAAO,EAAE,KAAK,YAAY,EAAU,MAAM,KAAK,CAAA;AAE/C,eAAO,MAAM,oBAAoB,EAAe,YAAY,CAAC,yBAAyB,CAAC,CAAA;AAEvF,0DAA0D;AAC1D,eAAO,MAAM,SAAS,iCAGrB,CAAA"}
|
package/dist/hooks/useConfig.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { apiReferenceConfigurationSchema as o } from "@scalar/types/api-reference";
|
|
2
|
+
import { inject as n } from "vue";
|
|
3
|
+
const e = Symbol(), c = () => n(e, o.parse({}));
|
|
3
4
|
export {
|
|
4
|
-
|
|
5
|
-
|
|
5
|
+
e as CONFIGURATION_SYMBOL,
|
|
6
|
+
c as useConfig
|
|
6
7
|
};
|