@scalar/api-client 2.2.38 → 2.2.39
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 +6 -0
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +24 -24
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.js +20 -17
- package/dist/style.css +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +34 -33
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
- package/package.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RequestAuth.vue.d.ts","sourceRoot":"","sources":["../../../../../src/views/Request/RequestSection/RequestAuth/RequestAuth.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RequestAuth.vue.d.ts","sourceRoot":"","sources":["../../../../../src/views/Request/RequestSection/RequestAuth/RequestAuth.vue"],"names":[],"mappings":"AAyVA,KAAK,WAAW,GAAG;IACjB,0BAA0B,EAAE,MAAM,EAAE,CAAA;IACpC,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,QAAQ,GAAG,WAAW,CAAA;CAChC,CAAC;;;;;;AA8YF,wBAQG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import t from "./RequestAuth.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import o from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const p = /* @__PURE__ */ o(t, [["__scopeId", "data-v-
|
|
4
|
+
const p = /* @__PURE__ */ o(t, [["__scopeId", "data-v-603916cb"]]);
|
|
5
5
|
export {
|
|
6
6
|
p as default
|
|
7
7
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as K, ref as C, computed as m, openBlock as M, createBlock as L, withCtx as d, createElementVNode as
|
|
1
|
+
import { defineComponent as K, ref as C, computed as m, openBlock as M, createBlock as L, withCtx as d, createElementVNode as y, toDisplayString as q, createElementBlock as N, normalizeClass as z, createCommentVNode as W, createVNode as h, unref as a } from "vue";
|
|
2
2
|
import H from "../../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
|
|
3
3
|
import { useActiveEntities as P } from "../../../../store/active-entities.js";
|
|
4
4
|
import { useModal as G, ScalarComboboxMultiselect as J, ScalarButton as Q, ScalarIcon as X } from "@scalar/components";
|
|
@@ -17,15 +17,15 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
17
17
|
layout: {}
|
|
18
18
|
},
|
|
19
19
|
emits: ["update:selectedSecuritySchemeUids"],
|
|
20
|
-
setup(
|
|
21
|
-
const
|
|
22
|
-
securitySchemes:
|
|
20
|
+
setup(f, { emit: O }) {
|
|
21
|
+
const k = O, { layout: $ } = te(), c = f.layout || $, { activeCollection: n, activeRequest: p } = P(), {
|
|
22
|
+
securitySchemes: R,
|
|
23
23
|
securitySchemeMutators: B,
|
|
24
24
|
requestMutators: V,
|
|
25
25
|
collectionMutators: w
|
|
26
|
-
} = le(),
|
|
26
|
+
} = le(), _ = C(null), v = G(), S = C(null), A = m(() => {
|
|
27
27
|
var l, i;
|
|
28
|
-
const e = ((l =
|
|
28
|
+
const e = ((l = p.value) == null ? void 0 : l.security) ?? ((i = n.value) == null ? void 0 : i.security) ?? [];
|
|
29
29
|
return { filteredRequirements: e.filter(
|
|
30
30
|
(s) => Object.keys(s).length
|
|
31
31
|
), requirements: e };
|
|
@@ -35,48 +35,48 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
35
35
|
const l = e.length < t.length, i = l ? "Unlock" : "Lock", s = l ? "Optional" : "Required", r = `${e.length === 1 ? Object.keys(e[0] || {})[0] : ""} ${s}`;
|
|
36
36
|
return { icon: i, text: r };
|
|
37
37
|
}), u = m(
|
|
38
|
-
() =>
|
|
39
|
-
const t =
|
|
38
|
+
() => f.selectedSecuritySchemeUids.map((e) => {
|
|
39
|
+
const t = R[e ?? ""];
|
|
40
40
|
if (t)
|
|
41
41
|
return g(t);
|
|
42
42
|
}).filter(U)
|
|
43
43
|
);
|
|
44
44
|
function T(e) {
|
|
45
45
|
var i, s;
|
|
46
|
-
if (!((i =
|
|
46
|
+
if (!((i = n.value) != null && i.uid) || !((s = p.value) != null && s.uid)) return;
|
|
47
47
|
const t = e.find((o) => o.payload), l = e.filter((o) => !o.payload).map(({ id: o }) => o);
|
|
48
48
|
if (t != null && t.payload) {
|
|
49
49
|
const o = B.add(
|
|
50
50
|
t.payload,
|
|
51
|
-
|
|
51
|
+
n.value.uid
|
|
52
52
|
);
|
|
53
53
|
o && l.push(o.uid);
|
|
54
54
|
}
|
|
55
|
-
D(l),
|
|
55
|
+
D(l), k("update:selectedSecuritySchemeUids", l);
|
|
56
56
|
}
|
|
57
57
|
const D = (e) => {
|
|
58
|
-
!
|
|
59
|
-
|
|
58
|
+
!n.value || !p.value || (c === "modal" || c === "reference" ? w.edit(
|
|
59
|
+
n.value.uid,
|
|
60
60
|
"selectedSecuritySchemeUids",
|
|
61
61
|
e
|
|
62
62
|
) : V.edit(
|
|
63
|
-
|
|
63
|
+
p.value.uid,
|
|
64
64
|
"selectedSecuritySchemeUids",
|
|
65
65
|
e
|
|
66
66
|
));
|
|
67
67
|
};
|
|
68
68
|
function E(e) {
|
|
69
|
-
S.value = e,
|
|
69
|
+
S.value = e, v.show();
|
|
70
70
|
}
|
|
71
71
|
const I = (e) => {
|
|
72
72
|
var l;
|
|
73
|
-
const t =
|
|
73
|
+
const t = f.selectedSecuritySchemeUids.filter(
|
|
74
74
|
(i) => i !== e
|
|
75
75
|
);
|
|
76
|
-
D(t),
|
|
76
|
+
D(t), k("update:selectedSecuritySchemeUids", t), (l = _.value) == null || l.$el.focus(), v.hide();
|
|
77
77
|
}, j = m(() => {
|
|
78
78
|
var t;
|
|
79
|
-
return (((t =
|
|
79
|
+
return (((t = n.value) == null ? void 0 : t.securitySchemes) ?? []).map((l) => R[l]).filter((l) => l);
|
|
80
80
|
}), F = m(
|
|
81
81
|
() => {
|
|
82
82
|
const e = [...j.value], t = [];
|
|
@@ -90,7 +90,7 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
90
90
|
{ label: "Required authentication", options: i },
|
|
91
91
|
{ label: "Available authentication", options: l }
|
|
92
92
|
];
|
|
93
|
-
return
|
|
93
|
+
return c === "modal" || c === "reference" ? i.length ? s : l : (s.push({
|
|
94
94
|
label: "Add new authentication",
|
|
95
95
|
options: ee
|
|
96
96
|
}), s);
|
|
@@ -98,11 +98,12 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
98
98
|
);
|
|
99
99
|
return (e, t) => (M(), L(H, {
|
|
100
100
|
class: "group/params",
|
|
101
|
-
itemCount: u.value.length
|
|
101
|
+
itemCount: u.value.length,
|
|
102
|
+
layout: f.layout
|
|
102
103
|
}, {
|
|
103
104
|
title: d(() => [
|
|
104
|
-
|
|
105
|
-
|
|
105
|
+
y("div", oe, [
|
|
106
|
+
y("span", null, q(e.title), 1),
|
|
106
107
|
b.value ? (M(), N("span", {
|
|
107
108
|
key: 0,
|
|
108
109
|
class: z(["text-c-3 text-xs leading-[normal]", { "text-c-1": b.value.text === "Required" }])
|
|
@@ -110,10 +111,10 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
110
111
|
])
|
|
111
112
|
]),
|
|
112
113
|
actions: d(() => [
|
|
113
|
-
|
|
114
|
-
h(
|
|
114
|
+
y("div", ie, [
|
|
115
|
+
h(a(J), {
|
|
115
116
|
class: "text-xs w-72",
|
|
116
|
-
isDeletable: c
|
|
117
|
+
isDeletable: a(c) !== "modal" && a(c) !== "reference",
|
|
117
118
|
modelValue: u.value,
|
|
118
119
|
multiple: "",
|
|
119
120
|
options: F.value,
|
|
@@ -121,9 +122,9 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
121
122
|
"onUpdate:modelValue": T
|
|
122
123
|
}, {
|
|
123
124
|
default: d(() => [
|
|
124
|
-
h(
|
|
125
|
+
h(a(Q), {
|
|
125
126
|
ref_key: "comboboxButtonRef",
|
|
126
|
-
ref:
|
|
127
|
+
ref: _,
|
|
127
128
|
class: "h-auto px-1.5 py-0.75 hover:bg-b-3 text-c-1 hover:text-c-1 font-normal",
|
|
128
129
|
fullWidth: "",
|
|
129
130
|
variant: "ghost"
|
|
@@ -131,8 +132,8 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
131
132
|
default: d(() => {
|
|
132
133
|
var l;
|
|
133
134
|
return [
|
|
134
|
-
|
|
135
|
-
h(
|
|
135
|
+
y("div", se, q(u.value.length === 0 ? "Auth Type" : u.value.length === 1 ? (l = u.value[0]) == null ? void 0 : l.label : "Multiple"), 1),
|
|
136
|
+
h(a(X), {
|
|
136
137
|
class: "ml-1 shrink-0",
|
|
137
138
|
icon: "ChevronDown",
|
|
138
139
|
size: "sm"
|
|
@@ -148,13 +149,13 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
148
149
|
]),
|
|
149
150
|
default: d(() => [
|
|
150
151
|
h(Z, {
|
|
151
|
-
layout: c
|
|
152
|
+
layout: a(c),
|
|
152
153
|
selectedSecuritySchemeUids: e.selectedSecuritySchemeUids
|
|
153
154
|
}, null, 8, ["layout", "selectedSecuritySchemeUids"]),
|
|
154
155
|
h(Y, {
|
|
155
156
|
scheme: S.value,
|
|
156
|
-
state:
|
|
157
|
-
onClose: t[0] || (t[0] = (l) =>
|
|
157
|
+
state: a(v),
|
|
158
|
+
onClose: t[0] || (t[0] = (l) => a(v).hide()),
|
|
158
159
|
onDelete: t[1] || (t[1] = (l) => {
|
|
159
160
|
var i;
|
|
160
161
|
return I((i = S.value) == null ? void 0 : i.id);
|
|
@@ -162,7 +163,7 @@ const oe = { class: "inline-flex gap-1 items-center" }, ie = { class: "flex flex
|
|
|
162
163
|
}, null, 8, ["scheme", "state"])
|
|
163
164
|
]),
|
|
164
165
|
_: 1
|
|
165
|
-
}, 8, ["itemCount"]));
|
|
166
|
+
}, 8, ["itemCount", "layout"]));
|
|
166
167
|
}
|
|
167
168
|
});
|
|
168
169
|
export {
|
|
@@ -17,7 +17,7 @@ const B = { class: "border-t relative col-1 flex-center gap-6 p-2 capitalize" },
|
|
|
17
17
|
a.commandPalette.emit({ commandName: "Create Request" });
|
|
18
18
|
}, y = (i) => {
|
|
19
19
|
i != null && i.createNew && g.name === "request" && f();
|
|
20
|
-
}, v = "2.2.
|
|
20
|
+
}, v = "2.2.39";
|
|
21
21
|
return _(() => a.hotKeys.on(y)), C(() => a.hotKeys.off(y)), (i, e) => (l(), n("div", B, [
|
|
22
22
|
o("div", {
|
|
23
23
|
class: k(["flex h-[calc(100%_-_50px)] flex-col items-center justify-center", {
|
package/package.json
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"rest",
|
|
19
19
|
"testing"
|
|
20
20
|
],
|
|
21
|
-
"version": "2.2.
|
|
21
|
+
"version": "2.2.39",
|
|
22
22
|
"engines": {
|
|
23
23
|
"node": ">=18"
|
|
24
24
|
},
|
|
@@ -178,17 +178,17 @@
|
|
|
178
178
|
"whatwg-mimetype": "^4.0.0",
|
|
179
179
|
"yaml": "^2.4.5",
|
|
180
180
|
"zod": "^3.23.8",
|
|
181
|
-
"@scalar/draggable": "0.1.8",
|
|
182
181
|
"@scalar/components": "0.13.17",
|
|
182
|
+
"@scalar/draggable": "0.1.8",
|
|
183
183
|
"@scalar/icons": "0.1.2",
|
|
184
184
|
"@scalar/import": "0.2.20",
|
|
185
185
|
"@scalar/oas-utils": "0.2.100",
|
|
186
186
|
"@scalar/object-utils": "1.1.12",
|
|
187
187
|
"@scalar/openapi-parser": "0.10.4",
|
|
188
|
-
"@scalar/openapi-types": "0.1.6",
|
|
189
188
|
"@scalar/postman-to-openapi": "0.1.23",
|
|
190
189
|
"@scalar/themes": "0.9.62",
|
|
191
190
|
"@scalar/types": "0.0.28",
|
|
191
|
+
"@scalar/openapi-types": "0.1.6",
|
|
192
192
|
"@scalar/use-hooks": "0.1.16",
|
|
193
193
|
"@scalar/use-codemirror": "0.11.62",
|
|
194
194
|
"@scalar/use-toasts": "0.7.8",
|