@scalar/api-client 2.1.47 → 2.1.49
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 +31 -0
- package/dist/assets/keycap.ascii.js +25 -0
- package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBar.vue.js +2 -2
- package/dist/components/AddressBar/AddressBar.vue2.js +6 -6
- package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
- package/dist/components/CodeInput/CodeInput.vue.js +2 -2
- package/dist/components/CodeInput/codeVariableWidget.js +12 -12
- package/dist/components/DataTable/DataTable.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTable.vue.js +1 -1
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +13 -13
- package/dist/components/ViewLayout/ViewLayoutSection.vue.d.ts.map +1 -1
- package/dist/components/ViewLayout/ViewLayoutSection.vue.js +2 -2
- package/dist/layouts/Modal/ApiClientModal.vue.d.ts +1 -3
- package/dist/layouts/Modal/ApiClientModal.vue.d.ts.map +1 -1
- package/dist/layouts/Modal/ApiClientModal.vue.js +2 -2
- package/dist/layouts/Modal/ApiClientModal.vue2.js +11 -11
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/requests.d.ts +40 -0
- package/dist/store/requests.d.ts.map +1 -1
- package/dist/store/requests.js +65 -55
- package/dist/store/workspace.d.ts.map +1 -1
- package/dist/store/workspace.js +24 -29
- package/dist/style.css +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts +7 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +71 -71
- package/dist/views/Request/RequestSection/RequestPathParams.vue.js +23 -23
- package/dist/views/Request/RequestSection/RequestSection.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestSection.vue2.js +1 -1
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +18 -18
- package/dist/views/Request/RequestSidebar.vue.d.ts +2 -0
- package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebar.vue.js +2 -2
- package/dist/views/Request/RequestSidebar.vue2.js +169 -133
- package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
- package/dist/views/Request/RequestSidebarItem.vue2.js +181 -155
- package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts +2 -0
- package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebarItemMenu.vue.js +3 -3
- package/dist/views/Request/RequestSidebarItemMenu.vue2.js +155 -96
- package/dist/views/Request/RequestSubpageHeader.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
- package/dist/views/Request/RequestSubpageHeader.vue2.js +26 -21
- package/dist/views/Request/ResponseSection/ResponseBody.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseBody.vue.js +5 -97
- package/dist/views/Request/ResponseSection/ResponseBody.vue2.js +97 -2
- package/dist/views/Request/ResponseSection/ResponseCookies.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseCookies.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +2 -2
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +74 -34
- package/dist/views/Request/ResponseSection/ResponseHeaders.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseHeaders.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseSection.vue.js +3 -3
- package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +15 -15
- package/package.json +7 -7
|
@@ -1,4 +1,99 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { defineComponent as L, ref as U, computed as n, openBlock as s, createBlock as u, createSlots as V, withCtx as m, createTextVNode as w, toDisplayString as g, createElementBlock as j, createElementVNode as h, createCommentVNode as c, createVNode as C } from "vue";
|
|
2
|
+
import O from "../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
|
|
3
|
+
import { extractFilename as T } from "../../../libs/extractAttachmentFilename.js";
|
|
4
|
+
import N from "whatwg-mimetype";
|
|
5
|
+
import S from "./ResponseBodyDownload.vue.js";
|
|
6
|
+
import P from "./ResponseBodyInfo.vue.js";
|
|
7
|
+
import $ from "./ResponseBodyPreview.vue.js";
|
|
8
|
+
import E from "./ResponseBodyRaw.vue.js";
|
|
9
|
+
import F from "./ResponseBodyToggle.vue.js";
|
|
10
|
+
import { mediaTypes as D } from "../consts/mediaTypes.js";
|
|
11
|
+
const I = {
|
|
12
|
+
key: 0,
|
|
13
|
+
class: "max-h-[calc(100%-32px)] border-1/2 flex flex-col rounded bg-b-1 overflow-hidden"
|
|
14
|
+
}, J = { class: "flex justify-between items-center border-b-1/2 px-3 py-1.5" }, M = { class: "text-xxs leading-3 font-code" }, Z = /* @__PURE__ */ L({
|
|
15
|
+
__name: "ResponseBody",
|
|
16
|
+
props: {
|
|
17
|
+
title: {},
|
|
18
|
+
data: {},
|
|
19
|
+
headers: {}
|
|
20
|
+
},
|
|
21
|
+
setup(b) {
|
|
22
|
+
const a = b, x = (e) => e instanceof Blob, d = U(!0), p = n(
|
|
23
|
+
() => {
|
|
24
|
+
var e;
|
|
25
|
+
return !!((e = o.value) != null && e.raw && o.value.preview);
|
|
26
|
+
}
|
|
27
|
+
), B = n(() => d.value || !p.value), R = n(() => !d.value || !p.value), r = n(() => {
|
|
28
|
+
var t;
|
|
29
|
+
const e = ((t = a.headers.find((l) => l.name.toLowerCase() === "content-type")) == null ? void 0 : t.value) ?? "";
|
|
30
|
+
return new N(e);
|
|
31
|
+
}), _ = n(() => {
|
|
32
|
+
var t;
|
|
33
|
+
const e = ((t = a.headers.find(
|
|
34
|
+
(l) => l.name.toLowerCase() === "content-disposition"
|
|
35
|
+
)) == null ? void 0 : t.value) ?? "";
|
|
36
|
+
return T(e);
|
|
37
|
+
}), o = n(() => D[r.value.essence]), i = n(() => x(a.data) ? URL.createObjectURL(a.data) : typeof a.data == "string" ? URL.createObjectURL(
|
|
38
|
+
new Blob([a.data], { type: r.value.toString() })
|
|
39
|
+
) : a.data instanceof Object && Object.keys(a.data).length ? URL.createObjectURL(
|
|
40
|
+
new Blob([JSON.stringify(a.data)], {
|
|
41
|
+
type: r.value.toString()
|
|
42
|
+
})
|
|
43
|
+
) : "");
|
|
44
|
+
return (e, t) => (s(), u(O, { class: "max-h-content overflow-x-auto" }, V({
|
|
45
|
+
title: m(() => [
|
|
46
|
+
w(g(e.title), 1)
|
|
47
|
+
]),
|
|
48
|
+
default: m(() => {
|
|
49
|
+
var l, v, f, y;
|
|
50
|
+
return [
|
|
51
|
+
e.data ? (s(), j("div", I, [
|
|
52
|
+
h("div", J, [
|
|
53
|
+
h("span", M, g(r.value.essence), 1),
|
|
54
|
+
p.value ? (s(), u(F, {
|
|
55
|
+
key: 0,
|
|
56
|
+
modelValue: d.value,
|
|
57
|
+
"onUpdate:modelValue": t[0] || (t[0] = (k) => d.value = k)
|
|
58
|
+
}, null, 8, ["modelValue"])) : c("", !0)
|
|
59
|
+
]),
|
|
60
|
+
(l = o.value) != null && l.raw && R.value ? (s(), u(E, {
|
|
61
|
+
key: i.value,
|
|
62
|
+
content: e.data,
|
|
63
|
+
language: o.value.language
|
|
64
|
+
}, null, 8, ["content", "language"])) : c("", !0),
|
|
65
|
+
(v = o.value) != null && v.preview && B.value ? (s(), u($, {
|
|
66
|
+
key: i.value,
|
|
67
|
+
alpha: o.value.alpha,
|
|
68
|
+
mode: o.value.preview,
|
|
69
|
+
src: i.value,
|
|
70
|
+
type: r.value.essence
|
|
71
|
+
}, null, 8, ["alpha", "mode", "src", "type"])) : c("", !0),
|
|
72
|
+
!((f = o.value) != null && f.raw) && !((y = o.value) != null && y.preview) ? (s(), u(P, { key: 2 }, {
|
|
73
|
+
default: m(() => t[1] || (t[1] = [
|
|
74
|
+
w(" Binary file ")
|
|
75
|
+
])),
|
|
76
|
+
_: 1
|
|
77
|
+
})) : c("", !0)
|
|
78
|
+
])) : c("", !0)
|
|
79
|
+
];
|
|
80
|
+
}),
|
|
81
|
+
_: 2
|
|
82
|
+
}, [
|
|
83
|
+
e.data && i.value ? {
|
|
84
|
+
name: "actions",
|
|
85
|
+
fn: m(() => [
|
|
86
|
+
C(S, {
|
|
87
|
+
filename: _.value,
|
|
88
|
+
href: i.value,
|
|
89
|
+
type: r.value.essence
|
|
90
|
+
}, null, 8, ["filename", "href", "type"])
|
|
91
|
+
]),
|
|
92
|
+
key: "0"
|
|
93
|
+
} : void 0
|
|
94
|
+
]), 1024));
|
|
95
|
+
}
|
|
96
|
+
});
|
|
2
97
|
export {
|
|
3
|
-
|
|
98
|
+
Z as default
|
|
4
99
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ResponseCookies.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseCookies.vue"],"names":[],"mappings":"AA2CA,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,OAAO,CAAA;KAAE,EAAE,CAAA;CAC9D,CAAC;;
|
|
1
|
+
{"version":3,"file":"ResponseCookies.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseCookies.vue"],"names":[],"mappings":"AA2CA,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,OAAO,CAAA;KAAE,EAAE,CAAA;CAC9D,CAAC;;AAoHF,wBAOG"}
|
|
@@ -5,7 +5,7 @@ import m from "../../../components/DataTable/DataTableText.vue.js";
|
|
|
5
5
|
import k from "../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
|
|
6
6
|
const x = {
|
|
7
7
|
key: 1,
|
|
8
|
-
class: "text-c-3 px-4 text-sm border border-1/2 rounded min-h-12 justify-center flex items-center bg-b-1
|
|
8
|
+
class: "text-c-3 px-4 text-sm border border-1/2 rounded min-h-12 justify-center flex items-center bg-b-1"
|
|
9
9
|
}, N = /* @__PURE__ */ f({
|
|
10
10
|
__name: "ResponseCookies",
|
|
11
11
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ResponseEmpty.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseEmpty.vue"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"ResponseEmpty.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseEmpty.vue"],"names":[],"mappings":";AA2XA,wBAMG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./ResponseEmpty.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const r = /* @__PURE__ */ t(o, [["__scopeId", "data-v-fb4e4b9a"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
r as default
|
|
7
7
|
};
|
|
@@ -1,59 +1,99 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
|
|
1
|
+
import { defineComponent as R, onMounted as b, onBeforeUnmount as C, openBlock as l, createElementBlock as n, createElementVNode as o, normalizeClass as k, unref as t, createTextVNode as c, toDisplayString as N, createCommentVNode as m, createVNode as s } from "vue";
|
|
2
|
+
import q from "../../../assets/computer.ascii.js";
|
|
3
|
+
import x from "../../../assets/keycap.ascii.js";
|
|
4
|
+
import d from "../../../components/ScalarAsciiArt.vue.js";
|
|
5
|
+
import p from "../../../components/ScalarHotkey.vue.js";
|
|
6
|
+
import { useRoute as V } from "vue-router";
|
|
7
|
+
import { useWorkspace as K } from "../../../store/store.js";
|
|
8
|
+
import { useLayout as S } from "../../../hooks/useLayout.js";
|
|
9
|
+
const B = { class: "relative col-1 flex-center gap-6 p-2 capitalize" }, w = {
|
|
9
10
|
key: 0,
|
|
10
11
|
class: "scalar-version-number"
|
|
11
|
-
},
|
|
12
|
+
}, A = { class: "scale-75 flex" }, E = { class: "relative" }, P = { class: "relative -ml-12" }, W = { class: "text-c-3 right-4 mt-auto flex w-full flex-col items-end gap-2 text-sm" }, U = /* @__PURE__ */ R({
|
|
12
13
|
__name: "ResponseEmpty",
|
|
13
|
-
setup(
|
|
14
|
-
const { isReadOnly:
|
|
15
|
-
|
|
16
|
-
},
|
|
17
|
-
|
|
18
|
-
},
|
|
19
|
-
return
|
|
20
|
-
o("div",
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
14
|
+
setup($) {
|
|
15
|
+
const { isReadOnly: j, activeWorkspace: g, events: a, activeWorkspaceRequests: u } = K(), v = V(), { layout: r } = S(), f = () => {
|
|
16
|
+
a.commandPalette.emit({ commandName: "Create Request" });
|
|
17
|
+
}, y = (i) => {
|
|
18
|
+
i != null && i.createNew && v.name === "request" && f();
|
|
19
|
+
}, h = "2.1.49";
|
|
20
|
+
return b(() => a.hotKeys.on(y)), C(() => a.hotKeys.off(y)), (i, e) => (l(), n("div", B, [
|
|
21
|
+
o("div", {
|
|
22
|
+
class: k(["flex h-[calc(100%_-_50px)] flex-col items-center justify-center", {
|
|
23
|
+
"hidden opacity-0": t(u).length <= 1 && t(r) !== "modal"
|
|
24
|
+
}])
|
|
25
|
+
}, [
|
|
26
|
+
t(g).isReadOnly ? m("", !0) : (l(), n("div", w, [
|
|
27
|
+
c(" Scalar App V" + N(t(h)) + " Beta ", 1),
|
|
28
|
+
e[2] || (e[2] = o("div", { class: "mt-2" }, [
|
|
24
29
|
o("a", {
|
|
25
30
|
href: "https://github.com/scalar/scalar/issues/2669",
|
|
26
31
|
target: "_blank"
|
|
27
32
|
}, " Roadmap ")
|
|
28
33
|
], -1))
|
|
29
34
|
])),
|
|
30
|
-
|
|
31
|
-
art: t(
|
|
35
|
+
s(d, {
|
|
36
|
+
art: t(q),
|
|
32
37
|
class: "text-c-3"
|
|
33
38
|
}, null, 8, ["art"])
|
|
34
|
-
]),
|
|
35
|
-
|
|
39
|
+
], 2),
|
|
40
|
+
t(r) !== "modal" ? (l(), n("div", {
|
|
41
|
+
key: 0,
|
|
42
|
+
class: k(["h-[calc(100%_-_50px)] items-center justify-center hidden pb-5", {
|
|
43
|
+
"!flex opacity-100": t(u).length == 1
|
|
44
|
+
}])
|
|
45
|
+
}, [
|
|
46
|
+
o("div", A, [
|
|
47
|
+
o("div", E, [
|
|
48
|
+
s(p, {
|
|
49
|
+
class: "keycap-hotkey",
|
|
50
|
+
hotkey: ""
|
|
51
|
+
}),
|
|
52
|
+
s(d, {
|
|
53
|
+
art: t(x),
|
|
54
|
+
class: "!leading-[6px] text-c-3"
|
|
55
|
+
}, null, 8, ["art"])
|
|
56
|
+
]),
|
|
57
|
+
o("div", P, [
|
|
58
|
+
e[3] || (e[3] = o("div", { class: "keycap-hotkey !right-[60px]" }, "K", -1)),
|
|
59
|
+
s(d, {
|
|
60
|
+
art: t(x),
|
|
61
|
+
class: "!leading-[6px] keycap-n"
|
|
62
|
+
}, null, 8, ["art"])
|
|
63
|
+
])
|
|
64
|
+
])
|
|
65
|
+
], 2)) : m("", !0),
|
|
66
|
+
o("div", W, [
|
|
67
|
+
t(r) !== "modal" ? (l(), n("button", {
|
|
68
|
+
key: 0,
|
|
69
|
+
class: "flex items-center gap-1.5",
|
|
70
|
+
type: "button",
|
|
71
|
+
onClick: e[0] || (e[0] = (_) => t(a).commandPalette.emit())
|
|
72
|
+
}, [
|
|
73
|
+
e[4] || (e[4] = c(" Get Started ")),
|
|
74
|
+
s(p, { hotkey: "k" })
|
|
75
|
+
])) : m("", !0),
|
|
36
76
|
o("button", {
|
|
37
77
|
class: "flex items-center gap-1.5",
|
|
38
78
|
type: "button",
|
|
39
|
-
onClick: e[
|
|
79
|
+
onClick: e[1] || (e[1] = (_) => t(a).executeRequest.emit())
|
|
40
80
|
}, [
|
|
41
|
-
e[
|
|
42
|
-
|
|
81
|
+
e[5] || (e[5] = c(" Send Request ")),
|
|
82
|
+
s(p, { hotkey: "↵" })
|
|
43
83
|
]),
|
|
44
|
-
|
|
45
|
-
key:
|
|
84
|
+
t(r) !== "modal" ? (l(), n("button", {
|
|
85
|
+
key: 1,
|
|
46
86
|
class: "flex items-center gap-1.5",
|
|
47
87
|
type: "button",
|
|
48
|
-
onClick:
|
|
88
|
+
onClick: f
|
|
49
89
|
}, [
|
|
50
|
-
e[
|
|
51
|
-
|
|
52
|
-
])) :
|
|
90
|
+
e[6] || (e[6] = c(" New Request ")),
|
|
91
|
+
s(p, { hotkey: "N" })
|
|
92
|
+
])) : m("", !0)
|
|
53
93
|
])
|
|
54
94
|
]));
|
|
55
95
|
}
|
|
56
96
|
});
|
|
57
97
|
export {
|
|
58
|
-
|
|
98
|
+
U as default
|
|
59
99
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ResponseHeaders.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseHeaders.vue"],"names":[],"mappings":"AA0EA,KAAK,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,OAAO,CAAA;CAAE,CAAA;AAEhE,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE,MAAM,EAAE,CAAA;CAClB,CAAC;;
|
|
1
|
+
{"version":3,"file":"ResponseHeaders.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseHeaders.vue"],"names":[],"mappings":"AA0EA,KAAK,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,OAAO,CAAA;CAAE,CAAA;AAEhE,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE,MAAM,EAAE,CAAA;CAClB,CAAC;;AAyJF,wBAOG"}
|
|
@@ -7,7 +7,7 @@ import b from "../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
|
|
|
7
7
|
import { httpHeaders as g } from "../../../data/httpHeaders.js";
|
|
8
8
|
const w = {
|
|
9
9
|
key: 0,
|
|
10
|
-
class: "border max-h-[calc(100%-32px)] overflow-y-auto rounded
|
|
10
|
+
class: "border max-h-[calc(100%-32px)] overflow-y-auto rounded"
|
|
11
11
|
}, C = {
|
|
12
12
|
key: 1,
|
|
13
13
|
class: "text-c-3 px-4 text-sm border rounded min-h-12 justify-center flex items-center bg-b-1 mx-1"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./ResponseSection.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
const
|
|
3
|
+
import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const r = /* @__PURE__ */ t(o, [["__scopeId", "data-v-6fdb06f8"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
r as default
|
|
7
7
|
};
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
1
|
+
import { defineComponent as _, computed as m, ref as g, openBlock as n, createBlock as i, withCtx as u, createElementVNode as l, normalizeClass as f, createCommentVNode as c, createVNode as v, createElementBlock as y, Fragment as x } from "vue";
|
|
2
|
+
import R from "../../../components/ContextBar.vue.js";
|
|
3
|
+
import S from "../../../components/ViewLayout/ViewLayoutSection.vue.js";
|
|
4
|
+
import j from "./ResponseBody.vue.js";
|
|
5
5
|
import b from "./ResponseEmpty.vue.js";
|
|
6
6
|
import H from "./ResponseLoadingOverlay.vue.js";
|
|
7
7
|
import V from "./ResponseMetaInformation.vue.js";
|
|
8
8
|
import w from "./ResponseBodyVirtual.vue.js";
|
|
9
9
|
/* empty css */
|
|
10
10
|
import L from "./ResponseCookies.vue.js";
|
|
11
|
-
import
|
|
12
|
-
const
|
|
11
|
+
import z from "./ResponseHeaders.vue.js";
|
|
12
|
+
const E = { class: "flex items-center flex-1 h-8" }, h = 2e5, X = /* @__PURE__ */ _({
|
|
13
13
|
__name: "ResponseSection",
|
|
14
14
|
props: {
|
|
15
15
|
response: {}
|
|
@@ -41,7 +41,7 @@ const z = { class: "flex items-center flex-1 h-8" }, h = 2e5, X = /* @__PURE__ *
|
|
|
41
41
|
} : [];
|
|
42
42
|
})) ?? [];
|
|
43
43
|
}
|
|
44
|
-
), C = ["All", "Cookies", "Headers", "Body"], a = g("All"),
|
|
44
|
+
), C = ["All", "Cookies", "Headers", "Body"], a = g("All"), A = m(() => {
|
|
45
45
|
var r, p;
|
|
46
46
|
if (!t.response) return !1;
|
|
47
47
|
const e = ((r = t.response.headers) == null ? void 0 : r["content-type"]) || ((p = t.response.headers) == null ? void 0 : p["Content-Type"]);
|
|
@@ -72,11 +72,11 @@ const z = { class: "flex items-center flex-1 h-8" }, h = 2e5, X = /* @__PURE__ *
|
|
|
72
72
|
"application/x-java-source",
|
|
73
73
|
// Form data
|
|
74
74
|
"application/x-www-form-urlencoded"
|
|
75
|
-
].some((
|
|
75
|
+
].some((T) => e.includes(T)) && (t.response.size ?? 0) > h;
|
|
76
76
|
});
|
|
77
|
-
return (e, s) => (n(), i(
|
|
77
|
+
return (e, s) => (n(), i(S, { "aria-label": "Response" }, {
|
|
78
78
|
title: u(() => [
|
|
79
|
-
l("div",
|
|
79
|
+
l("div", E, [
|
|
80
80
|
l("div", {
|
|
81
81
|
"aria-live": "polite",
|
|
82
82
|
class: f(["flex items-center", { "animate-response-heading": e.response }])
|
|
@@ -88,7 +88,7 @@ const z = { class: "flex items-center flex-1 h-8" }, h = 2e5, X = /* @__PURE__ *
|
|
|
88
88
|
response: e.response
|
|
89
89
|
}, null, 8, ["response"])) : c("", !0)
|
|
90
90
|
], 2),
|
|
91
|
-
v(
|
|
91
|
+
v(R, {
|
|
92
92
|
activeSection: a.value,
|
|
93
93
|
sections: C,
|
|
94
94
|
onSetActiveSection: s[0] || (s[0] = (o) => a.value = o)
|
|
@@ -99,7 +99,7 @@ const z = { class: "flex items-center flex-1 h-8" }, h = 2e5, X = /* @__PURE__ *
|
|
|
99
99
|
var o;
|
|
100
100
|
return [
|
|
101
101
|
l("div", {
|
|
102
|
-
class: f(["custom-scroll h-full relative grid gap-[.5px] px-2 xl:px-
|
|
102
|
+
class: f(["custom-scroll h-full relative grid gap-[.5px] px-2 xl:px-3 py-2.5", {
|
|
103
103
|
"content-start": e.response
|
|
104
104
|
}])
|
|
105
105
|
}, [
|
|
@@ -108,15 +108,15 @@ const z = { class: "flex items-center flex-1 h-8" }, h = 2e5, X = /* @__PURE__ *
|
|
|
108
108
|
key: 0,
|
|
109
109
|
cookies: B.value
|
|
110
110
|
}, null, 8, ["cookies"])) : c("", !0),
|
|
111
|
-
a.value === "All" || a.value === "Headers" ? (n(), i(
|
|
111
|
+
a.value === "All" || a.value === "Headers" ? (n(), i(z, {
|
|
112
112
|
key: 1,
|
|
113
113
|
headers: d.value
|
|
114
114
|
}, null, 8, ["headers"])) : c("", !0),
|
|
115
115
|
a.value === "All" || a.value === "Body" ? (n(), y(x, { key: 2 }, [
|
|
116
|
-
|
|
116
|
+
A.value ? (n(), i(w, {
|
|
117
117
|
key: 0,
|
|
118
118
|
content: t.response.data
|
|
119
|
-
}, null, 8, ["content"])) : (n(), i(
|
|
119
|
+
}, null, 8, ["content"])) : (n(), i(j, {
|
|
120
120
|
key: 1,
|
|
121
121
|
active: !0,
|
|
122
122
|
data: (o = t.response) == null ? void 0 : o.data,
|
package/package.json
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"rest",
|
|
19
19
|
"testing"
|
|
20
20
|
],
|
|
21
|
-
"version": "2.1.
|
|
21
|
+
"version": "2.1.49",
|
|
22
22
|
"engines": {
|
|
23
23
|
"node": ">=18"
|
|
24
24
|
},
|
|
@@ -155,17 +155,17 @@
|
|
|
155
155
|
"whatwg-mimetype": "^4.0.0",
|
|
156
156
|
"yaml": "^2.4.5",
|
|
157
157
|
"zod": "^3.23.8",
|
|
158
|
-
"@scalar/components": "0.12.
|
|
158
|
+
"@scalar/components": "0.12.69",
|
|
159
|
+
"@scalar/draggable": "0.1.7",
|
|
159
160
|
"@scalar/icons": "0.1.1",
|
|
160
161
|
"@scalar/import": "0.1.1",
|
|
161
|
-
"@scalar/
|
|
162
|
-
"@scalar/openapi-parser": "0.8.9",
|
|
163
|
-
"@scalar/oas-utils": "0.2.73",
|
|
162
|
+
"@scalar/oas-utils": "0.2.75",
|
|
164
163
|
"@scalar/object-utils": "1.1.12",
|
|
165
|
-
"@scalar/
|
|
164
|
+
"@scalar/openapi-parser": "0.8.9",
|
|
166
165
|
"@scalar/openapi-types": "0.1.5",
|
|
166
|
+
"@scalar/themes": "0.9.48",
|
|
167
|
+
"@scalar/use-codemirror": "0.11.36",
|
|
167
168
|
"@scalar/types": "0.0.19",
|
|
168
|
-
"@scalar/use-codemirror": "0.11.34",
|
|
169
169
|
"@scalar/use-toasts": "0.7.7",
|
|
170
170
|
"@scalar/use-tooltip": "1.0.4"
|
|
171
171
|
},
|