@scalar/api-client 2.10.0 → 2.11.0
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 +25 -0
- package/dist/components/ImportCollection/IntegrationLogo.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/IntegrationLogo.vue.js +1 -0
- package/dist/components/Server/ServerVariablesForm.vue.d.ts.map +1 -1
- package/dist/components/Server/ServerVariablesForm.vue.js +6 -6
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +1 -1
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue2.js +14 -13
- package/dist/hooks/useClientConfig.d.ts +3 -3
- package/dist/layouts/App/create-api-client-app.d.ts +1 -1
- package/dist/layouts/Web/create-api-client-web.d.ts +1 -1
- package/dist/libs/create-client.d.ts +1 -1
- package/dist/store/store.d.ts +1 -1
- package/dist/style.css +1 -1
- package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts +4 -6
- package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/OperationBlock.vue.js +24 -27
- package/dist/v2/blocks/operation-block/components/Header.vue.d.ts +3 -6
- package/dist/v2/blocks/operation-block/components/Header.vue.d.ts.map +1 -1
- package/dist/v2/blocks/operation-block/components/Header.vue.js +2 -2
- package/dist/v2/blocks/operation-block/components/Header.vue2.js +10 -12
- package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.vue.d.ts.map +1 -1
- package/dist/v2/blocks/operation-code-sample/components/ExamplePicker.vue.js +11 -10
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts +2 -5
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.js +2 -2
- package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue2.js +45 -47
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts +11 -9
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.js +179 -5
- package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue2.js +2 -179
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +201 -198
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.d.ts +11 -6
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue.js +82 -5
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTable.vue2.js +2 -85
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue.d.ts +3 -13
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthDataTableInput.vue.js +16 -18
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.js +133 -142
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.js +1 -1
- package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue.d.ts +2 -16
- package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue.js +2 -2
- package/dist/v2/blocks/scalar-operation-block/components/OperationBlock.vue2.js +202 -229
- package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue.d.ts +3 -5
- package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue.js +2 -2
- package/dist/v2/blocks/scalar-operation-block/components/OperationBody.vue2.js +81 -85
- package/dist/v2/blocks/scalar-operation-block/components/OperationParams.vue.d.ts +2 -5
- package/dist/v2/blocks/scalar-operation-block/components/OperationParams.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-operation-block/components/OperationParams.vue.js +32 -34
- package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue.d.ts +2 -5
- package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue.js +2 -2
- package/dist/v2/blocks/scalar-operation-block/components/OperationTable.vue2.js +31 -33
- package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.vue.d.ts +2 -5
- package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-operation-block/components/OperationTableRow.vue.js +42 -45
- package/dist/v2/blocks/scalar-response-block/components/Headers.vue.d.ts +2 -2
- package/dist/v2/blocks/scalar-response-block/components/Headers.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-response-block/components/Headers.vue.js +9 -9
- package/dist/v2/blocks/scalar-response-block/components/ResponseBody.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-response-block/components/ResponseBody.vue.js +2 -2
- package/dist/v2/blocks/scalar-response-block/components/ResponseBody.vue2.js +18 -18
- package/dist/v2/blocks/scalar-response-block/components/ResponseBodyStreaming.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-response-block/components/ResponseBodyStreaming.vue.js +14 -14
- package/dist/v2/blocks/scalar-response-block/components/ResponseBodyVirtual.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-response-block/components/ResponseBodyVirtual.vue.js +12 -12
- package/dist/v2/blocks/scalar-response-block/components/ResponseCookies.vue.d.ts.map +1 -1
- package/dist/v2/blocks/scalar-response-block/components/ResponseCookies.vue.js +13 -13
- package/dist/v2/components/data-table/DataTable.vue.d.ts.map +1 -1
- package/dist/v2/components/data-table/DataTable.vue.js +4 -4
- package/dist/v2/components/data-table/DataTableInput.vue.d.ts +5 -7
- package/dist/v2/components/data-table/DataTableInput.vue.d.ts.map +1 -1
- package/dist/v2/components/data-table/DataTableInput.vue.js +2 -2
- package/dist/v2/components/data-table/DataTableInput.vue2.js +32 -36
- package/dist/v2/components/forms/ConfirmationForm.vue.d.ts +25 -0
- package/dist/v2/components/forms/ConfirmationForm.vue.d.ts.map +1 -0
- package/dist/v2/components/forms/ConfirmationForm.vue.js +7 -0
- package/dist/v2/components/forms/ConfirmationForm.vue2.js +45 -0
- package/dist/v2/components/forms/index.d.ts +2 -0
- package/dist/v2/components/forms/index.d.ts.map +1 -0
- package/dist/v2/components/forms/index.js +4 -0
- package/dist/v2/components/layout/CollapsibleSection.vue.d.ts +43 -0
- package/dist/v2/components/layout/CollapsibleSection.vue.d.ts.map +1 -0
- package/dist/v2/components/layout/CollapsibleSection.vue.js +89 -0
- package/dist/v2/components/layout/CollapsibleSection.vue2.js +4 -0
- package/dist/v2/components/layout/ValueEmitter.vue.d.ts +23 -0
- package/dist/v2/components/layout/ValueEmitter.vue.d.ts.map +1 -0
- package/dist/v2/components/layout/ValueEmitter.vue.js +21 -0
- package/dist/v2/components/layout/ValueEmitter.vue2.js +4 -0
- package/dist/v2/components/layout/index.d.ts +2 -0
- package/dist/v2/components/layout/index.d.ts.map +1 -0
- package/dist/v2/components/layout/index.js +4 -0
- package/dist/v2/components/modals/DeleteModal.vue.d.ts +15 -0
- package/dist/v2/components/modals/DeleteModal.vue.d.ts.map +1 -0
- package/dist/v2/components/modals/DeleteModal.vue.js +31 -0
- package/dist/v2/components/modals/DeleteModal.vue2.js +4 -0
- package/dist/v2/components/modals/index.d.ts +2 -0
- package/dist/v2/components/modals/index.d.ts.map +1 -0
- package/dist/v2/components/modals/index.js +4 -0
- package/dist/v2/components/server/ServerDropdown.vue.d.ts +4 -2
- package/dist/v2/components/server/ServerDropdown.vue.d.ts.map +1 -1
- package/dist/v2/components/server/ServerDropdown.vue.js +31 -31
- package/dist/v2/components/server/ServerDropdownItem.vue.d.ts +2 -6
- package/dist/v2/components/server/ServerDropdownItem.vue.d.ts.map +1 -1
- package/dist/v2/components/server/ServerDropdownItem.vue.js +1 -1
- package/dist/v2/components/server/ServerDropdownItem.vue2.js +16 -16
- package/dist/v2/components/server/index.d.ts.map +1 -1
- package/dist/v2/components/sidebar/Sidebar.vue.d.ts +6 -2
- package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
- package/dist/v2/components/sidebar/Sidebar.vue.js +45 -55
- package/dist/v2/features/app/App.vue.d.ts +2 -2
- package/dist/v2/features/app/App.vue.d.ts.map +1 -1
- package/dist/v2/features/app/App.vue.js +89 -74
- package/dist/v2/features/app/components/AppSidebar.vue.d.ts +6 -2
- package/dist/v2/features/app/components/AppSidebar.vue.d.ts.map +1 -1
- package/dist/v2/features/app/components/AppSidebar.vue.js +1 -1
- package/dist/v2/features/app/components/AppSidebar.vue2.js +50 -47
- package/dist/v2/features/app/helpers/routes.d.ts +0 -10
- package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
- package/dist/v2/features/collection/DocumentCollection.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/DocumentCollection.vue2.js +75 -73
- package/dist/v2/features/collection/components/Authentication.vue.d.ts +13 -25
- package/dist/v2/features/collection/components/Authentication.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/components/Authentication.vue.js +2 -2
- package/dist/v2/features/collection/components/Authentication.vue2.js +47 -35
- package/dist/v2/features/collection/components/Form.vue.d.ts +3 -7
- package/dist/v2/features/collection/components/Form.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/components/Form.vue.js +28 -33
- package/dist/v2/features/collection/components/Servers.vue.d.ts +13 -31
- package/dist/v2/features/collection/components/Servers.vue.d.ts.map +1 -1
- package/dist/v2/features/collection/components/Servers.vue2.js +103 -82
- package/dist/v2/features/environments/components/EnvironmentVariablesTable.vue.d.ts.map +1 -1
- package/dist/v2/features/environments/components/EnvironmentVariablesTable.vue.js +3 -3
- package/dist/v2/features/modal/Modal.vue.d.ts.map +1 -1
- package/dist/v2/features/modal/Modal.vue.js +3 -3
- package/dist/v2/features/modal/Modal.vue2.js +40 -32
- package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
- package/dist/v2/features/operation/Operation.vue.js +22 -28
- package/dist/v2/hooks/use-sidebar-state.d.ts +47 -0
- package/dist/v2/hooks/use-sidebar-state.d.ts.map +1 -0
- package/dist/v2/hooks/use-sidebar-state.js +112 -0
- package/dist/v2/hooks/use-workspace-client-events.d.ts.map +1 -1
- package/dist/v2/hooks/use-workspace-client-events.js +75 -107
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
- package/package.json +17 -17
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts +0 -45
- package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts.map +0 -1
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts +0 -29
- package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts.map +0 -1
- package/dist/v2/blocks/scalar-auth-selector-block/event-types.d.ts +0 -29
- package/dist/v2/blocks/scalar-auth-selector-block/event-types.d.ts.map +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./OperationBlock.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const c = /* @__PURE__ */ t(o, [["__scopeId", "data-v-5b361e3c"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
c as default
|
|
7
7
|
};
|
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ScalarErrorBoundary as
|
|
3
|
-
import { canMethodHaveBody as
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
|
|
1
|
+
import { defineComponent as L, computed as v, ref as G, useId as V, watch as X, createBlock as U, openBlock as u, unref as t, withCtx as q, withDirectives as h, createElementBlock as x, createVNode as s, vShow as f, Fragment as J, renderList as W, createCommentVNode as K, resolveDynamicComponent as Y, createElementVNode as Z, toDisplayString as ee } from "vue";
|
|
2
|
+
import { ScalarErrorBoundary as te } from "@scalar/components";
|
|
3
|
+
import { canMethodHaveBody as w } from "@scalar/helpers/http/can-method-have-body";
|
|
4
|
+
import { REGEX as oe } from "@scalar/helpers/regex/regex-helpers";
|
|
5
|
+
import { getResolvedRef as C } from "@scalar/workspace-store/helpers/get-resolved-ref";
|
|
6
|
+
import ae from "../../../../components/SectionFilter.vue.js";
|
|
7
|
+
import le from "../../../../components/ViewLayout/ViewLayoutSection.vue.js";
|
|
8
|
+
import ne from "./OperationBody.vue.js";
|
|
9
|
+
import B from "./OperationParams.vue.js";
|
|
10
|
+
import { groupBy as re } from "../helpers/group-by.js";
|
|
11
|
+
import de from "../../scalar-auth-selector-block/components/AuthSelector.vue.js";
|
|
12
|
+
const ie = { class: "group pointer-events-none flex flex-1 items-center gap-1 lg:pr-24" }, ue = ["for"], se = ["id", "placeholder", "value"], me = {
|
|
12
13
|
key: 2,
|
|
13
14
|
class: "text-c-1 flex h-8 items-center"
|
|
14
|
-
},
|
|
15
|
+
}, Ue = /* @__PURE__ */ L({
|
|
15
16
|
__name: "OperationBlock",
|
|
16
17
|
props: {
|
|
17
18
|
method: {},
|
|
18
19
|
path: {},
|
|
19
20
|
operation: {},
|
|
20
|
-
authMeta: {
|
|
21
|
+
authMeta: {},
|
|
21
22
|
exampleKey: {},
|
|
22
23
|
securitySchemes: {},
|
|
23
24
|
selectedSecurity: {},
|
|
@@ -26,256 +27,228 @@ const z = { class: "group pointer-events-none flex flex-1 items-center gap-1 lg:
|
|
|
26
27
|
layout: {},
|
|
27
28
|
plugins: {},
|
|
28
29
|
eventBus: {},
|
|
29
|
-
environment: {}
|
|
30
|
-
envVariables: {}
|
|
30
|
+
environment: {}
|
|
31
31
|
},
|
|
32
|
-
setup(
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
32
|
+
setup(E) {
|
|
33
|
+
const R = E, {
|
|
34
|
+
operation: r,
|
|
35
|
+
method: A,
|
|
36
|
+
layout: k,
|
|
37
|
+
securitySchemes: S,
|
|
38
|
+
path: _,
|
|
39
|
+
exampleKey: d,
|
|
40
|
+
security: P,
|
|
41
|
+
eventBus: l,
|
|
42
|
+
environment: m
|
|
43
|
+
} = R, H = R.authMeta ?? { type: "document" }, n = v(() => ({
|
|
44
|
+
method: A,
|
|
45
|
+
path: _,
|
|
46
|
+
exampleKey: d
|
|
47
|
+
})), p = v(
|
|
48
|
+
() => re(r.parameters?.map((e) => C(e)) ?? [], "in")
|
|
49
|
+
), O = [
|
|
40
50
|
"Auth",
|
|
41
51
|
"Variables",
|
|
42
52
|
"Cookies",
|
|
43
53
|
"Headers",
|
|
44
54
|
"Query",
|
|
45
55
|
"Body"
|
|
46
|
-
],
|
|
47
|
-
const e = /* @__PURE__ */ new Set(["All", ...
|
|
48
|
-
return
|
|
49
|
-
}),
|
|
56
|
+
], c = G("All"), b = v(() => {
|
|
57
|
+
const e = /* @__PURE__ */ new Set(["All", ...O]);
|
|
58
|
+
return p.value.path?.length || e.delete("Variables"), w(A) || e.delete("Body"), g.value && e.delete("Auth"), [...e];
|
|
59
|
+
}), i = v(
|
|
50
60
|
() => Object.fromEntries(
|
|
51
|
-
|
|
61
|
+
b.value.map((e) => [e, V()])
|
|
52
62
|
)
|
|
53
63
|
);
|
|
54
|
-
|
|
55
|
-
() =>
|
|
64
|
+
X(
|
|
65
|
+
() => A,
|
|
56
66
|
(e) => {
|
|
57
|
-
|
|
67
|
+
c.value === "Body" && !w(e) && (c.value = "All");
|
|
58
68
|
}
|
|
59
69
|
);
|
|
60
|
-
const
|
|
61
|
-
() =>
|
|
62
|
-
),
|
|
63
|
-
|
|
64
|
-
"
|
|
70
|
+
const g = v(
|
|
71
|
+
() => k === "modal" && !r.security && !Object.keys(S ?? {}).length
|
|
72
|
+
), F = v(() => r.summary ? r.summary : _.replace(oe.PROTOCOL, "") || "Request Name"), y = (e) => c.value === "All" || c.value === e, I = (e) => {
|
|
73
|
+
const a = e.target.value;
|
|
74
|
+
l.emit("operation:update:summary", {
|
|
75
|
+
meta: n.value,
|
|
76
|
+
payload: { summary: a }
|
|
77
|
+
});
|
|
78
|
+
}, o = (e) => ({
|
|
79
|
+
onAdd: (a) => {
|
|
80
|
+
l.emit("operation:add:parameter", {
|
|
81
|
+
type: e,
|
|
82
|
+
payload: {
|
|
83
|
+
key: a.key ?? "",
|
|
84
|
+
value: a.value ?? "",
|
|
85
|
+
isEnabled: !0
|
|
86
|
+
},
|
|
87
|
+
meta: n.value
|
|
88
|
+
});
|
|
89
|
+
},
|
|
90
|
+
onDelete: (a) => {
|
|
91
|
+
l.emit("operation:delete:parameter", {
|
|
92
|
+
type: e,
|
|
93
|
+
index: a.index,
|
|
94
|
+
meta: n.value
|
|
95
|
+
});
|
|
96
|
+
},
|
|
97
|
+
onDeleteAll: () => {
|
|
98
|
+
l.emit("operation:delete-all:parameters", {
|
|
99
|
+
type: e,
|
|
100
|
+
meta: n.value
|
|
101
|
+
});
|
|
102
|
+
},
|
|
103
|
+
onUpdate: (a) => {
|
|
104
|
+
l.emit("operation:update:parameter", {
|
|
105
|
+
type: e,
|
|
106
|
+
index: a.index,
|
|
107
|
+
payload: a.payload,
|
|
108
|
+
meta: n.value
|
|
109
|
+
});
|
|
110
|
+
}
|
|
111
|
+
}), N = (e) => l.emit("operation:add:requestBody:formRow", {
|
|
112
|
+
contentType: e.contentType,
|
|
113
|
+
meta: n.value,
|
|
114
|
+
payload: {
|
|
115
|
+
key: e.data.key ?? "",
|
|
116
|
+
value: e.data.value ?? ""
|
|
117
|
+
}
|
|
118
|
+
}), M = (e) => l.emit("operation:delete:requestBody:formRow", {
|
|
119
|
+
contentType: e.contentType,
|
|
120
|
+
index: e.index,
|
|
121
|
+
meta: n.value
|
|
122
|
+
}), Q = (e) => l.emit("operation:update:requestBody:contentType", {
|
|
123
|
+
payload: { contentType: e.value },
|
|
124
|
+
meta: n.value
|
|
125
|
+
}), $ = (e) => l.emit("operation:update:requestBody:formRow", {
|
|
126
|
+
contentType: e.contentType,
|
|
127
|
+
meta: n.value,
|
|
128
|
+
index: e.index,
|
|
129
|
+
payload: {
|
|
130
|
+
key: e.data.key ?? "",
|
|
131
|
+
value: e.data.value ?? ""
|
|
132
|
+
}
|
|
133
|
+
}), j = (e) => l.emit("operation:update:requestBody:value", {
|
|
134
|
+
contentType: e.contentType,
|
|
135
|
+
payload: { value: e.value ?? "" },
|
|
136
|
+
meta: n.value
|
|
137
|
+
}), T = V();
|
|
138
|
+
return (e, a) => (u(), U(le, {
|
|
139
|
+
"aria-label": `Request: ${t(r).summary}`
|
|
65
140
|
}, {
|
|
66
|
-
title:
|
|
67
|
-
|
|
68
|
-
|
|
141
|
+
title: q(() => [
|
|
142
|
+
Z("div", ie, [
|
|
143
|
+
t(k) !== "modal" ? (u(), x("label", {
|
|
69
144
|
key: 0,
|
|
70
145
|
class: "pointer-events-auto absolute top-0 left-0 h-full w-full cursor-text opacity-0",
|
|
71
|
-
for:
|
|
72
|
-
}, null, 8,
|
|
73
|
-
|
|
146
|
+
for: t(T)
|
|
147
|
+
}, null, 8, ue)) : K("", !0),
|
|
148
|
+
t(k) !== "modal" ? (u(), x("input", {
|
|
74
149
|
key: 1,
|
|
75
|
-
id:
|
|
150
|
+
id: t(T),
|
|
76
151
|
class: "text-c-1 group-hover-input pointer-events-auto relative z-10 -ml-0.5 h-8 w-full rounded pl-1.25 has-[:focus-visible]:outline md:-ml-1.25",
|
|
77
|
-
placeholder:
|
|
78
|
-
value:
|
|
79
|
-
onInput:
|
|
80
|
-
|
|
81
|
-
payload: {
|
|
82
|
-
summary: t.target.value
|
|
83
|
-
}
|
|
84
|
-
}))
|
|
85
|
-
}, null, 40, X)) : (i(), B("span", J, P(e.operation.summary), 1))
|
|
152
|
+
placeholder: F.value,
|
|
153
|
+
value: t(r).summary,
|
|
154
|
+
onInput: I
|
|
155
|
+
}, null, 40, se)) : (u(), x("span", me, ee(t(r).summary), 1))
|
|
86
156
|
]),
|
|
87
|
-
|
|
88
|
-
modelValue:
|
|
89
|
-
"onUpdate:modelValue": a[
|
|
90
|
-
filterIds:
|
|
91
|
-
filters:
|
|
157
|
+
s(ae, {
|
|
158
|
+
modelValue: c.value,
|
|
159
|
+
"onUpdate:modelValue": a[0] || (a[0] = (D) => c.value = D),
|
|
160
|
+
filterIds: i.value,
|
|
161
|
+
filters: b.value
|
|
92
162
|
}, null, 8, ["modelValue", "filterIds", "filters"])
|
|
93
163
|
]),
|
|
94
|
-
default:
|
|
95
|
-
|
|
96
|
-
id:
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
security:
|
|
101
|
-
securitySchemes:
|
|
164
|
+
default: q(() => [
|
|
165
|
+
h(s(t(de), {
|
|
166
|
+
id: i.value.Auth,
|
|
167
|
+
environment: t(m),
|
|
168
|
+
eventBus: t(l),
|
|
169
|
+
meta: t(H),
|
|
170
|
+
security: t(P),
|
|
171
|
+
securitySchemes: t(S),
|
|
102
172
|
selectedSecurity: e.selectedSecurity,
|
|
103
173
|
server: e.server,
|
|
104
|
-
title: "Authorization"
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
}, null, 8, ["id", "envVariables", "environment", "security", "securitySchemes", "selectedSecurity", "server", "meta", "eventBus"]), [
|
|
108
|
-
[y, p("Auth") && !K.value]
|
|
174
|
+
title: "Authorization"
|
|
175
|
+
}, null, 8, ["id", "environment", "eventBus", "meta", "security", "securitySchemes", "selectedSecurity", "server"]), [
|
|
176
|
+
[f, y("Auth") && !g.value]
|
|
109
177
|
]),
|
|
110
|
-
|
|
111
|
-
id:
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
178
|
+
h(s(B, {
|
|
179
|
+
id: i.value.Variables,
|
|
180
|
+
environment: t(m),
|
|
181
|
+
exampleKey: t(d),
|
|
182
|
+
parameters: p.value.path ?? [],
|
|
183
|
+
showAddRowPlaceholder: !1,
|
|
116
184
|
title: "Variables",
|
|
117
|
-
"
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
})),
|
|
123
|
-
onDeleteAll: a[3] || (a[3] = () => e.eventBus.emit("operation:delete-all:parameters", {
|
|
124
|
-
type: "path",
|
|
125
|
-
meta: o.value
|
|
126
|
-
})),
|
|
127
|
-
onUpdate: a[4] || (a[4] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
|
|
128
|
-
type: "path",
|
|
129
|
-
index: t,
|
|
130
|
-
payload: r,
|
|
131
|
-
meta: o.value
|
|
132
|
-
}))
|
|
133
|
-
}, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
|
|
134
|
-
[y, p("Variables") && m.value.path?.length]
|
|
185
|
+
onDelete: o("path").onDelete,
|
|
186
|
+
onDeleteAll: o("path").onDeleteAll,
|
|
187
|
+
onUpdate: o("path").onUpdate
|
|
188
|
+
}, null, 8, ["id", "environment", "exampleKey", "parameters", "onDelete", "onDeleteAll", "onUpdate"]), [
|
|
189
|
+
[f, y("Variables") && p.value.path?.length]
|
|
135
190
|
]),
|
|
136
|
-
|
|
137
|
-
id:
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
191
|
+
h(s(B, {
|
|
192
|
+
id: i.value.Cookies,
|
|
193
|
+
environment: t(m),
|
|
194
|
+
exampleKey: t(d),
|
|
195
|
+
parameters: p.value.cookie ?? [],
|
|
196
|
+
showAddRowPlaceholder: !0,
|
|
142
197
|
title: "Cookies",
|
|
143
|
-
"
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
onDelete: a[6] || (a[6] = ({ index: t }) => e.eventBus.emit("operation:delete:parameter", {
|
|
150
|
-
type: "cookie",
|
|
151
|
-
index: t,
|
|
152
|
-
meta: o.value
|
|
153
|
-
})),
|
|
154
|
-
onDeleteAll: a[7] || (a[7] = () => e.eventBus.emit("operation:delete-all:parameters", {
|
|
155
|
-
type: "cookie",
|
|
156
|
-
meta: o.value
|
|
157
|
-
})),
|
|
158
|
-
onUpdate: a[8] || (a[8] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
|
|
159
|
-
type: "cookie",
|
|
160
|
-
index: t,
|
|
161
|
-
payload: r,
|
|
162
|
-
meta: o.value
|
|
163
|
-
}))
|
|
164
|
-
}, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
|
|
165
|
-
[y, p("Cookies")]
|
|
198
|
+
onAdd: o("cookie").onAdd,
|
|
199
|
+
onDelete: o("cookie").onDelete,
|
|
200
|
+
onDeleteAll: o("cookie").onDeleteAll,
|
|
201
|
+
onUpdate: o("cookie").onUpdate
|
|
202
|
+
}, null, 8, ["id", "environment", "exampleKey", "parameters", "onAdd", "onDelete", "onDeleteAll", "onUpdate"]), [
|
|
203
|
+
[f, y("Cookies")]
|
|
166
204
|
]),
|
|
167
|
-
|
|
168
|
-
id:
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
parameters: m.value.header ?? [],
|
|
205
|
+
h(s(B, {
|
|
206
|
+
id: i.value.Headers,
|
|
207
|
+
environment: t(m),
|
|
208
|
+
exampleKey: t(d),
|
|
209
|
+
parameters: p.value.header ?? [],
|
|
173
210
|
title: "Headers",
|
|
174
|
-
onAdd:
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
type: "header",
|
|
181
|
-
index: t,
|
|
182
|
-
meta: o.value
|
|
183
|
-
})),
|
|
184
|
-
onDeleteAll: a[11] || (a[11] = () => e.eventBus.emit("operation:delete-all:parameters", {
|
|
185
|
-
type: "header",
|
|
186
|
-
meta: o.value
|
|
187
|
-
})),
|
|
188
|
-
onUpdate: a[12] || (a[12] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
|
|
189
|
-
type: "header",
|
|
190
|
-
index: t,
|
|
191
|
-
payload: r,
|
|
192
|
-
meta: o.value
|
|
193
|
-
}))
|
|
194
|
-
}, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
|
|
195
|
-
[y, p("Headers")]
|
|
211
|
+
onAdd: o("header").onAdd,
|
|
212
|
+
onDelete: o("header").onDelete,
|
|
213
|
+
onDeleteAll: o("header").onDeleteAll,
|
|
214
|
+
onUpdate: o("header").onUpdate
|
|
215
|
+
}, null, 8, ["id", "environment", "exampleKey", "parameters", "onAdd", "onDelete", "onDeleteAll", "onUpdate"]), [
|
|
216
|
+
[f, y("Headers")]
|
|
196
217
|
]),
|
|
197
|
-
|
|
198
|
-
id:
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
parameters: m.value.query ?? [],
|
|
218
|
+
h(s(B, {
|
|
219
|
+
id: i.value.Query,
|
|
220
|
+
environment: t(m),
|
|
221
|
+
exampleKey: t(d),
|
|
222
|
+
parameters: p.value.query ?? [],
|
|
203
223
|
title: "Query Parameters",
|
|
204
|
-
onAdd:
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
type: "query",
|
|
211
|
-
index: t,
|
|
212
|
-
meta: o.value
|
|
213
|
-
})),
|
|
214
|
-
onDeleteAll: a[15] || (a[15] = () => e.eventBus.emit("operation:delete-all:parameters", {
|
|
215
|
-
type: "query",
|
|
216
|
-
meta: o.value
|
|
217
|
-
})),
|
|
218
|
-
onUpdate: a[16] || (a[16] = ({ index: t, payload: r }) => e.eventBus.emit("operation:update:parameter", {
|
|
219
|
-
type: "query",
|
|
220
|
-
index: t,
|
|
221
|
-
payload: r,
|
|
222
|
-
meta: o.value
|
|
223
|
-
}))
|
|
224
|
-
}, null, 8, ["id", "envVariables", "environment", "exampleKey", "parameters"]), [
|
|
225
|
-
[y, p("Query")]
|
|
224
|
+
onAdd: o("query").onAdd,
|
|
225
|
+
onDelete: o("query").onDelete,
|
|
226
|
+
onDeleteAll: o("query").onDeleteAll,
|
|
227
|
+
onUpdate: o("query").onUpdate
|
|
228
|
+
}, null, 8, ["id", "environment", "exampleKey", "parameters", "onAdd", "onDelete", "onDeleteAll", "onUpdate"]), [
|
|
229
|
+
[f, y("Query")]
|
|
226
230
|
]),
|
|
227
|
-
|
|
228
|
-
id:
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
requestBody: v(g)(e.operation.requestBody),
|
|
231
|
+
h(s(ne, {
|
|
232
|
+
id: i.value.Body,
|
|
233
|
+
environment: t(m),
|
|
234
|
+
exampleKey: t(d),
|
|
235
|
+
requestBody: t(C)(t(r).requestBody),
|
|
233
236
|
title: "Request Body",
|
|
234
|
-
"onAdd:formRow":
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
})),
|
|
242
|
-
"onUpdate:contentType": a[18] || (a[18] = (t) => e.eventBus.emit("operation:update:requestBody:contentType", {
|
|
243
|
-
payload: {
|
|
244
|
-
contentType: t.value
|
|
245
|
-
},
|
|
246
|
-
meta: o.value
|
|
247
|
-
})),
|
|
248
|
-
"onUpdate:formRow": a[19] || (a[19] = (t) => e.eventBus.emit("operation:update:requestBody:formRow", {
|
|
249
|
-
contentType: t.contentType,
|
|
250
|
-
meta: o.value,
|
|
251
|
-
index: t.index,
|
|
252
|
-
payload: {
|
|
253
|
-
key: t.data.key,
|
|
254
|
-
value: t.data.value
|
|
255
|
-
}
|
|
256
|
-
})),
|
|
257
|
-
"onDelete:fromRow": a[20] || (a[20] = (t) => e.eventBus.emit("operation:delete:requestBody:formRow", {
|
|
258
|
-
contentType: t.contentType,
|
|
259
|
-
index: t.index,
|
|
260
|
-
meta: o.value
|
|
261
|
-
})),
|
|
262
|
-
"onUpdate:value": a[21] || (a[21] = (t) => e.eventBus.emit("operation:update:requestBody:value", {
|
|
263
|
-
contentType: t.contentType,
|
|
264
|
-
payload: {
|
|
265
|
-
value: t.value
|
|
266
|
-
},
|
|
267
|
-
meta: o.value
|
|
268
|
-
}))
|
|
269
|
-
}, null, 8, ["id", "envVariables", "environment", "exampleKey", "requestBody"]), [
|
|
270
|
-
[y, p("Body") && v(q)(e.method)]
|
|
237
|
+
"onAdd:formRow": N,
|
|
238
|
+
"onDelete:fromRow": M,
|
|
239
|
+
"onUpdate:contentType": Q,
|
|
240
|
+
"onUpdate:formRow": $,
|
|
241
|
+
"onUpdate:value": j
|
|
242
|
+
}, null, 8, ["id", "environment", "exampleKey", "requestBody"]), [
|
|
243
|
+
[f, y("Body") && t(w)(t(A))]
|
|
271
244
|
]),
|
|
272
|
-
(
|
|
273
|
-
default:
|
|
274
|
-
|
|
245
|
+
(u(!0), x(J, null, W(e.plugins, (D, z) => (u(), U(t(te), { key: z }, {
|
|
246
|
+
default: q(() => [
|
|
247
|
+
D?.components?.request ? (u(), U(Y(D.components.request), {
|
|
275
248
|
key: 0,
|
|
276
|
-
operation:
|
|
277
|
-
selectedExample:
|
|
278
|
-
}, null, 8, ["operation", "selectedExample"])) :
|
|
249
|
+
operation: t(r),
|
|
250
|
+
selectedExample: t(d)
|
|
251
|
+
}, null, 8, ["operation", "selectedExample"])) : K("", !0)
|
|
279
252
|
]),
|
|
280
253
|
_: 2
|
|
281
254
|
}, 1024))), 128))
|
|
@@ -285,5 +258,5 @@ const z = { class: "group pointer-events-none flex flex-1 items-center gap-1 lg:
|
|
|
285
258
|
}
|
|
286
259
|
});
|
|
287
260
|
export {
|
|
288
|
-
|
|
261
|
+
Ue as default
|
|
289
262
|
};
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { XScalarEnvironment } from '@scalar/workspace-store/schemas/extensions/document/x-scalar-environments';
|
|
2
2
|
import type { RequestBodyObject } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document';
|
|
3
|
-
import type { EnvVariable } from '../../../../store/active-entities.js';
|
|
4
3
|
type __VLS_Props = {
|
|
5
4
|
/** Request body */
|
|
6
5
|
requestBody?: RequestBodyObject;
|
|
@@ -8,9 +7,8 @@ type __VLS_Props = {
|
|
|
8
7
|
exampleKey: string;
|
|
9
8
|
/** Display title */
|
|
10
9
|
title: string;
|
|
11
|
-
/**
|
|
12
|
-
environment:
|
|
13
|
-
envVariables: EnvVariable[];
|
|
10
|
+
/** Selected environment */
|
|
11
|
+
environment: XScalarEnvironment;
|
|
14
12
|
};
|
|
15
13
|
declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
|
|
16
14
|
"update:contentType": (payload: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OperationBody.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-operation-block/components/OperationBody.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"OperationBody.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/blocks/scalar-operation-block/components/OperationBody.vue"],"names":[],"mappings":"AAuVA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2EAA2E,CAAA;AACnH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8DAA8D,CAAA;AAgBrG,KAAK,WAAW,GAAG;IACjB,mBAAmB;IACnB,WAAW,CAAC,EAAE,iBAAiB,CAAA;IAC/B,+DAA+D;IAC/D,UAAU,EAAE,MAAM,CAAA;IAClB,oBAAoB;IACpB,KAAK,EAAE,MAAM,CAAA;IACb,2BAA2B;IAC3B,WAAW,EAAE,kBAAkB,CAAA;CAChC,CAAC;;;eAI4C,MAAM;;;gBAI7B,MAAM,GAAG,IAAI;qBAAe,MAAM;;;cAM7C,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,CAAC;qBACxC,MAAM;;;eAMZ,MAAM;cACP,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAA;SAAE,CAAC;qBAC9C,MAAM;;;eAGiB,MAAM;qBAAe,MAAM;;;;eAtBvB,MAAM;;;gBAI7B,MAAM,GAAG,IAAI;qBAAe,MAAM;;;cAM7C,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;SAAE,CAAC;qBACxC,MAAM;;;eAMZ,MAAM;cACP,OAAO,CAAC;YAAE,GAAG,EAAE,MAAM,CAAC;YAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAA;SAAE,CAAC;qBAC9C,MAAM;;;eAGiB,MAAM;qBAAe,MAAM;;;AAyjBrE,wBAOG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./OperationBody.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-01b90115"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|