@scalar/api-client 2.2.48 → 2.2.50
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 +41 -0
- package/dist/components/AddressBar/AddressBar.vue.d.ts +15 -3
- package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBar.vue.js +1 -1
- package/dist/components/AddressBar/AddressBar.vue2.js +102 -94
- package/dist/components/AddressBar/AddressBarHistory.vue.d.ts +2 -0
- package/dist/components/AddressBar/AddressBarHistory.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBarHistory.vue.js +2 -2
- package/dist/components/AddressBar/AddressBarHistory.vue2.js +54 -58
- package/dist/components/CodeInput/CodeInput.vue.d.ts +9 -0
- package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
- package/dist/components/CodeInput/CodeInput.vue.js +2 -2
- package/dist/components/CodeInput/CodeInput.vue2.js +95 -93
- package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
- package/dist/components/CodeInput/codeVariableWidget.js +1 -3
- package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +26 -22
- package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteImport.vue.js +13 -13
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +12 -12
- package/dist/components/CommandPalette/CommandPaletteServer.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteServer.vue.js +54 -49
- package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteTag.vue.js +9 -9
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableCell.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableCell.vue.js +11 -8
- package/dist/components/DataTable/DataTableInput.vue.d.ts +6 -0
- package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableInput.vue.js +4 -4
- package/dist/components/DataTable/DataTableInput.vue2.js +36 -30
- package/dist/components/DataTable/DataTableInputSelect.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableInputSelect.vue.js +15 -15
- package/dist/components/Form/Form.vue.d.ts +3 -1
- package/dist/components/Form/Form.vue.d.ts.map +1 -1
- package/dist/components/Form/Form.vue.js +30 -25
- package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/ImportCollectionModal.vue.js +41 -41
- package/dist/components/ImportCollection/ImportNowButton.vue.js +24 -24
- package/dist/components/ScreenReader.vue.d.ts.map +1 -1
- package/dist/components/Server/ServerDropdown.vue.d.ts.map +1 -1
- package/dist/components/Server/ServerDropdown.vue.js +13 -13
- package/dist/components/Server/ServerDropdownItem.vue.d.ts +1 -1
- package/dist/components/Server/ServerDropdownItem.vue.d.ts.map +1 -1
- package/dist/components/Server/ServerDropdownItem.vue.js +1 -1
- package/dist/components/Server/ServerDropdownItem.vue2.js +19 -19
- package/dist/layouts/App/create-api-client-app.d.ts +387 -477
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.d.ts +774 -954
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Web/create-api-client-web.d.ts +387 -477
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/libs/create-client.d.ts +390 -479
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/create-client.js +3 -15
- package/dist/libs/env-helpers.d.ts.map +1 -1
- package/dist/libs/find-request.d.ts +7 -7
- package/dist/libs/find-request.d.ts.map +1 -1
- package/dist/libs/hot-keys.d.ts +3 -1
- package/dist/libs/hot-keys.d.ts.map +1 -1
- package/dist/libs/hot-keys.js +11 -15
- package/dist/libs/hot-keys.test.d.ts +2 -0
- package/dist/libs/hot-keys.test.d.ts.map +1 -0
- package/dist/libs/index.js +27 -26
- package/dist/libs/send-request/build-request-security.d.ts +1 -1
- package/dist/libs/send-request/build-request-security.js +19 -16
- package/dist/libs/send-request/create-request-operation.test.d.ts +10 -10
- package/dist/libs/send-request/create-request-operation.test.d.ts.map +1 -1
- package/dist/libs/send-request/set-request-cookies.d.ts +1 -1
- package/dist/libs/send-request/set-request-cookies.d.ts.map +1 -1
- package/dist/libs/send-request/set-request-cookies.js +37 -34
- package/dist/store/active-entities.d.ts +58 -67
- package/dist/store/active-entities.d.ts.map +1 -1
- package/dist/store/active-entities.js +61 -74
- package/dist/store/collections.d.ts +90 -90
- package/dist/store/collections.d.ts.map +1 -1
- package/dist/store/collections.js +4 -17
- package/dist/store/cookies.d.ts +14 -14
- package/dist/store/environment.d.ts +19 -18
- package/dist/store/environment.d.ts.map +1 -1
- package/dist/store/environment.js +2 -8
- package/dist/store/import-spec.d.ts +16 -106
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/import-spec.js +9 -14
- package/dist/store/request-example.d.ts +25 -25
- package/dist/store/request-example.d.ts.map +1 -1
- package/dist/store/request-example.js +15 -20
- package/dist/store/requests.d.ts +84 -84
- package/dist/store/requests.d.ts.map +1 -1
- package/dist/store/requests.js +17 -40
- package/dist/store/router-params.d.ts +13 -11
- package/dist/store/router-params.d.ts.map +1 -1
- package/dist/store/router-params.js +5 -5
- package/dist/store/security-schemes.d.ts +58 -58
- package/dist/store/security-schemes.d.ts.map +1 -1
- package/dist/store/security-schemes.js +1 -3
- package/dist/store/servers.d.ts +17 -17
- package/dist/store/servers.d.ts.map +1 -1
- package/dist/store/servers.js +2 -9
- package/dist/store/store.d.ts +387 -477
- package/dist/store/store.d.ts.map +1 -1
- package/dist/store/store.js +2 -4
- package/dist/store/tags.d.ts +28 -28
- package/dist/store/tags.d.ts.map +1 -1
- package/dist/store/tags.js +19 -34
- package/dist/store/workspace.d.ts +36 -36
- package/dist/store/workspace.d.ts.map +1 -1
- package/dist/store/workspace.js +1 -5
- package/dist/style.css +1 -1
- package/dist/views/Collection/Collection.vue.d.ts.map +1 -1
- package/dist/views/Cookies/CookieForm.vue.d.ts.map +1 -1
- package/dist/views/Cookies/CookieForm.vue.js +18 -18
- package/dist/views/Cookies/CookieRaw.vue.d.ts.map +1 -1
- package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
- package/dist/views/Cookies/Cookies.vue2.js +24 -24
- package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
- package/dist/views/Environment/Environment.vue2.js +140 -132
- package/dist/views/Environment/EnvironmentModal.vue.d.ts +2 -2
- package/dist/views/Environment/EnvironmentModal.vue.d.ts.map +1 -1
- package/dist/views/Environment/EnvironmentModal.vue.js +15 -15
- package/dist/views/Request/Request.vue.d.ts.map +1 -1
- package/dist/views/Request/Request.vue.js +2 -2
- package/dist/views/Request/Request.vue2.js +160 -141
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts +2 -1
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.js +7 -7
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts +6 -2
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +99 -95
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts +4 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +70 -64
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts +4 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +40 -34
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts +6 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.js +32 -26
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.d.ts +4 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue2.js +93 -85
- package/dist/views/Request/RequestSection/RequestBody.vue.d.ts +9 -0
- package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestBody.vue2.js +214 -244
- package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts +10 -1
- package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +77 -80
- package/dist/views/Request/RequestSection/RequestParams.vue.d.ts +7 -0
- package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestParams.vue.js +89 -96
- package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts +10 -2
- package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestPathParams.vue.js +59 -66
- package/dist/views/Request/RequestSection/RequestSection.vue.d.ts +11 -0
- package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestSection.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestSection.vue2.js +176 -155
- package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +6 -0
- package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestTable.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestTable.vue2.js +97 -100
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue2.js +31 -22
- package/dist/views/Request/RequestSection/helpers/getting-started.d.ts +2 -2
- package/dist/views/Request/RequestSection/helpers/getting-started.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/helpers/getting-started.js +11 -13
- package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebar.vue.js +1 -1
- package/dist/views/Request/RequestSidebar.vue2.js +50 -48
- package/dist/views/Request/RequestSidebarItem.vue.d.ts +1 -1
- package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebarItem.vue.js +2 -2
- package/dist/views/Request/RequestSidebarItem.vue2.js +38 -44
- package/dist/views/Request/RequestSubpageHeader.vue.d.ts +10 -0
- 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 +77 -69
- package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue.js +7 -7
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts +4 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +41 -39
- package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts +1 -0
- package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseSection.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +56 -52
- package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
- package/dist/views/Request/components/WorkspaceDropdown.vue.js +68 -68
- package/dist/views/Request/consts/new-auth-options.d.ts.map +1 -1
- package/dist/views/Request/handle-drag.d.ts +1 -1
- package/dist/views/Request/handle-drag.d.ts.map +1 -1
- package/dist/views/Request/handle-drag.js +38 -55
- package/dist/views/Request/libs/auth.d.ts +2 -2
- package/dist/views/Request/libs/auth.d.ts.map +1 -1
- package/dist/views/Request/libs/auth.js +28 -29
- package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
- package/dist/views/Request/libs/oauth2.js +42 -65
- package/dist/views/Request/libs/request.d.ts +5 -0
- package/dist/views/Request/libs/request.d.ts.map +1 -1
- package/dist/views/Request/libs/request.js +37 -2
- package/dist/views/Request/libs/watch-mode.d.ts.map +1 -1
- package/dist/views/Request/libs/watch-mode.js +10 -34
- package/dist/views/Servers/ServerForm.vue.d.ts +1 -8
- package/dist/views/Servers/ServerForm.vue.d.ts.map +1 -1
- package/dist/views/Servers/ServerForm.vue.js +21 -22
- package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
- package/dist/views/Servers/Servers.vue2.js +73 -81
- package/dist/views/Settings/SettingsGeneral.vue.d.ts.map +1 -1
- package/dist/views/Settings/SettingsGeneral.vue.js +118 -134
- package/package.json +14 -14
|
@@ -1,27 +1,26 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ScalarIcon as
|
|
3
|
-
import { prettyPrintJson as
|
|
4
|
-
import { useCodeMirror as
|
|
5
|
-
import { useClipboard as
|
|
6
|
-
import { nanoid as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import {
|
|
11
|
-
|
|
12
|
-
const fe = ["id"], ce = {
|
|
1
|
+
import { defineComponent as j, useAttrs as H, ref as d, toRef as r, watch as J, computed as $, openBlock as n, createElementBlock as i, Fragment as Q, normalizeClass as W, unref as u, createElementVNode as g, toDisplayString as G, createBlock as f, mergeProps as X, withKeys as V, withModifiers as q, createVNode as Y, createCommentVNode as c, renderSlot as R } from "vue";
|
|
2
|
+
import { ScalarIcon as Z } from "@scalar/components";
|
|
3
|
+
import { prettyPrintJson as _ } from "@scalar/oas-utils/helpers";
|
|
4
|
+
import { useCodeMirror as ee, useDropdown as oe, colorPicker as le } from "@scalar/use-codemirror";
|
|
5
|
+
import { useClipboard as te } from "@scalar/use-hooks/useClipboard";
|
|
6
|
+
import { nanoid as ne } from "nanoid";
|
|
7
|
+
import ae from "../../views/Environment/EnvironmentVariableDropdown.vue.js";
|
|
8
|
+
import h from "../DataTable/DataTableInputSelect.vue.js";
|
|
9
|
+
import { pillPlugin as re, backspaceCommand as ue } from "./codeVariableWidget.js";
|
|
10
|
+
import { useLayout as se } from "../../hooks/useLayout.js";
|
|
11
|
+
const de = ["id"], ie = {
|
|
13
12
|
key: 0,
|
|
14
13
|
class: "scalar-code-copy z-context"
|
|
15
|
-
},
|
|
14
|
+
}, pe = {
|
|
16
15
|
key: 5,
|
|
17
16
|
class: "centered-y text-orange absolute right-7 text-xs"
|
|
18
|
-
},
|
|
17
|
+
}, me = {
|
|
19
18
|
key: 6,
|
|
20
|
-
class: "required centered-y text-xxs text-c-3 bg-b-1 pointer-events-none absolute right-0 pr-2 pt-px opacity-100 shadow-[-8px_0_4px_var(--scalar-background-1)] transition-opacity duration-150 peer-has-[.cm-focused]:opacity-0"
|
|
21
|
-
},
|
|
19
|
+
class: "required centered-y text-xxs text-c-3 bg-b-1 pointer-events-none absolute right-0 pr-2 pt-px opacity-100 shadow-[-8px_0_4px_var(--scalar-background-1)] transition-opacity duration-150 group-[.alert]:bg-transparent group-[.alert]:shadow-none peer-has-[.cm-focused]:opacity-0"
|
|
20
|
+
}, fe = {
|
|
22
21
|
inheritAttrs: !1
|
|
23
|
-
},
|
|
24
|
-
...
|
|
22
|
+
}, ke = /* @__PURE__ */ j({
|
|
23
|
+
...fe,
|
|
25
24
|
__name: "CodeInput",
|
|
26
25
|
props: {
|
|
27
26
|
colorPicker: { type: Boolean, default: !1 },
|
|
@@ -46,79 +45,82 @@ const fe = ["id"], ce = {
|
|
|
46
45
|
withVariables: { type: Boolean, default: !0 },
|
|
47
46
|
importCurl: { type: Boolean },
|
|
48
47
|
isCopyable: { type: Boolean, default: !1 },
|
|
49
|
-
default: {}
|
|
48
|
+
default: {},
|
|
49
|
+
environment: {},
|
|
50
|
+
envVariables: {},
|
|
51
|
+
workspace: {}
|
|
50
52
|
},
|
|
51
53
|
emits: ["submit", "update:modelValue", "curl"],
|
|
52
|
-
setup(
|
|
53
|
-
var
|
|
54
|
-
const o =
|
|
54
|
+
setup(A, { expose: E, emit: M }) {
|
|
55
|
+
var x;
|
|
56
|
+
const o = A, s = M, C = H(), N = C.id || `id-${ne()}`, B = d(!1), y = d(!1), k = d(""), S = d({ left: 0, top: 0 }), m = d(null), { layout: b } = se(), { copyToClipboard: O } = te();
|
|
55
57
|
function T(e) {
|
|
56
58
|
var l;
|
|
57
|
-
return e === o.modelValue ? null : o.importCurl && e.trim().toLowerCase().startsWith("curl") ? (s("curl", e), (l =
|
|
59
|
+
return e === o.modelValue ? null : o.importCurl && e.trim().toLowerCase().startsWith("curl") ? (s("curl", e), (l = a.value) == null || l.dispatch({
|
|
58
60
|
changes: {
|
|
59
61
|
from: 0,
|
|
60
|
-
to:
|
|
62
|
+
to: a.value.state.doc.length,
|
|
61
63
|
insert: String(o.modelValue)
|
|
62
64
|
}
|
|
63
65
|
}), null) : o.handleFieldChange ? o.handleFieldChange(e) : s("update:modelValue", e);
|
|
64
66
|
}
|
|
65
|
-
function
|
|
67
|
+
function D(e) {
|
|
66
68
|
return o.handleFieldSubmit ? o.handleFieldSubmit(e) : s("submit", e);
|
|
67
69
|
}
|
|
68
|
-
function
|
|
69
|
-
|
|
70
|
+
function I(e) {
|
|
71
|
+
B.value = !1, o.emitOnBlur && o.modelValue && D(e);
|
|
70
72
|
}
|
|
71
|
-
const
|
|
72
|
-
o.colorPicker &&
|
|
73
|
-
|
|
74
|
-
environment:
|
|
75
|
-
envVariables:
|
|
76
|
-
workspace:
|
|
77
|
-
isReadOnly:
|
|
73
|
+
const v = [];
|
|
74
|
+
o.colorPicker && v.push(le), v.push(
|
|
75
|
+
re({
|
|
76
|
+
environment: o.environment,
|
|
77
|
+
envVariables: o.envVariables,
|
|
78
|
+
workspace: o.workspace,
|
|
79
|
+
isReadOnly: b === "modal"
|
|
78
80
|
}),
|
|
79
|
-
|
|
81
|
+
ue
|
|
80
82
|
);
|
|
81
|
-
const
|
|
82
|
-
content:
|
|
83
|
+
const P = d(null), { codeMirror: a } = ee({
|
|
84
|
+
content: r(
|
|
83
85
|
() => o.modelValue !== void 0 ? String(o.modelValue) : ""
|
|
84
86
|
),
|
|
85
87
|
onChange: (e) => {
|
|
86
|
-
T(e),
|
|
88
|
+
T(e), z();
|
|
87
89
|
},
|
|
88
|
-
onFocus: () =>
|
|
89
|
-
onBlur: (e) =>
|
|
90
|
-
codeMirrorRef:
|
|
91
|
-
disableTabIndent:
|
|
92
|
-
disableEnter:
|
|
93
|
-
disableCloseBrackets:
|
|
94
|
-
lineNumbers:
|
|
95
|
-
language:
|
|
96
|
-
lint:
|
|
97
|
-
extensions:
|
|
98
|
-
placeholder:
|
|
90
|
+
onFocus: () => B.value = !0,
|
|
91
|
+
onBlur: (e) => I(e),
|
|
92
|
+
codeMirrorRef: P,
|
|
93
|
+
disableTabIndent: r(() => o.disableTabIndent),
|
|
94
|
+
disableEnter: r(() => o.disableEnter),
|
|
95
|
+
disableCloseBrackets: r(() => o.disableCloseBrackets),
|
|
96
|
+
lineNumbers: r(() => o.lineNumbers),
|
|
97
|
+
language: r(() => o.language),
|
|
98
|
+
lint: r(() => o.lint),
|
|
99
|
+
extensions: v,
|
|
100
|
+
placeholder: r(() => o.placeholder)
|
|
99
101
|
});
|
|
100
|
-
(
|
|
101
|
-
|
|
102
|
+
(x = a.value) == null || x.focus(), J(a, () => {
|
|
103
|
+
a.value && Object.prototype.hasOwnProperty.call(C, "autofocus") && a.value.focus();
|
|
102
104
|
});
|
|
103
|
-
const { handleDropdownSelect:
|
|
104
|
-
codeMirror:
|
|
105
|
-
query:
|
|
105
|
+
const { handleDropdownSelect: K, updateDropdownVisibility: z } = oe({
|
|
106
|
+
codeMirror: a,
|
|
107
|
+
query: k,
|
|
106
108
|
showDropdown: y,
|
|
107
|
-
dropdownPosition:
|
|
108
|
-
}),
|
|
109
|
+
dropdownPosition: S
|
|
110
|
+
}), L = $(() => {
|
|
109
111
|
var e;
|
|
110
112
|
return o.type === "boolean" || (e = o.type) != null && e.includes("boolean") || o.nullable ? ["true", "false", "null"] : ["true", "false"];
|
|
111
113
|
});
|
|
112
|
-
|
|
114
|
+
E({
|
|
113
115
|
focus: () => {
|
|
114
116
|
var e;
|
|
115
|
-
(e =
|
|
117
|
+
(e = a.value) == null || e.focus();
|
|
116
118
|
}
|
|
117
119
|
});
|
|
118
120
|
const w = (e, l) => {
|
|
119
|
-
var p, t,
|
|
120
|
-
y.value
|
|
121
|
-
},
|
|
121
|
+
var p, t, F;
|
|
122
|
+
y.value ? e === "down" ? (l.preventDefault(), (p = m.value) == null || p.handleArrowKey("down")) : e === "up" ? (l.preventDefault(), (t = m.value) == null || t.handleArrowKey("up")) : e === "enter" && (l.preventDefault(), (F = m.value) == null || F.handleSelect()) : e === "enter" && l.target instanceof HTMLDivElement && D(l.target.textContent ?? "");
|
|
123
|
+
}, U = $(() => Array.isArray(o.type) ? (
|
|
122
124
|
// Find the first type, that’s not 'null'
|
|
123
125
|
o.type.find((e) => e !== "null") ?? "string"
|
|
124
126
|
) : (
|
|
@@ -127,79 +129,79 @@ const fe = ["id"], ce = {
|
|
|
127
129
|
));
|
|
128
130
|
return (e, l) => {
|
|
129
131
|
var p;
|
|
130
|
-
return n(), i(
|
|
132
|
+
return n(), i(Q, null, [
|
|
131
133
|
e.disabled ? (n(), i("div", {
|
|
132
134
|
key: 0,
|
|
133
|
-
class:
|
|
135
|
+
class: W(["text-c-2 flex cursor-default items-center justify-center", u(b) === "modal" ? "font-code pl-1 pr-2 text-sm" : "px-2"])
|
|
134
136
|
}, [
|
|
135
|
-
|
|
136
|
-
], 2)) : o.enum && o.enum.length ? (n(), f(
|
|
137
|
+
g("span", null, G(e.modelValue), 1)
|
|
138
|
+
], 2)) : o.enum && o.enum.length ? (n(), f(h, {
|
|
137
139
|
key: 1,
|
|
138
140
|
default: o.default,
|
|
139
141
|
modelValue: e.modelValue,
|
|
140
|
-
type:
|
|
142
|
+
type: U.value,
|
|
141
143
|
value: o.enum,
|
|
142
144
|
"onUpdate:modelValue": l[0] || (l[0] = (t) => s("update:modelValue", t))
|
|
143
|
-
}, null, 8, ["default", "modelValue", "type", "value"])) : e.type === "boolean" || (p = e.type) != null && p.includes("boolean") ? (n(), f(
|
|
145
|
+
}, null, 8, ["default", "modelValue", "type", "value"])) : e.type === "boolean" || (p = e.type) != null && p.includes("boolean") ? (n(), f(h, {
|
|
144
146
|
key: 2,
|
|
145
147
|
default: o.default,
|
|
146
148
|
modelValue: e.modelValue,
|
|
147
|
-
value:
|
|
149
|
+
value: L.value,
|
|
148
150
|
"onUpdate:modelValue": l[1] || (l[1] = (t) => s("update:modelValue", t))
|
|
149
|
-
}, null, 8, ["default", "modelValue", "value"])) : o.examples && o.examples.length ? (n(), f(
|
|
151
|
+
}, null, 8, ["default", "modelValue", "value"])) : o.examples && o.examples.length ? (n(), f(h, {
|
|
150
152
|
key: 3,
|
|
151
153
|
default: o.default,
|
|
152
154
|
modelValue: o.modelValue,
|
|
153
155
|
value: o.examples,
|
|
154
156
|
"onUpdate:modelValue": l[2] || (l[2] = (t) => s("update:modelValue", t))
|
|
155
|
-
}, null, 8, ["default", "modelValue", "value"])) : (n(), i("div",
|
|
157
|
+
}, null, 8, ["default", "modelValue", "value"])) : (n(), i("div", X({
|
|
156
158
|
key: 4,
|
|
157
|
-
id:
|
|
159
|
+
id: u(N)
|
|
158
160
|
}, e.$attrs, {
|
|
159
161
|
ref_key: "codeMirrorRef",
|
|
160
|
-
ref:
|
|
161
|
-
class: ["font-code peer relative w-full overflow-hidden whitespace-nowrap text-xs leading-[1.44] -outline-offset-1 has-[:focus-visible]:rounded-[4px] has-[:focus-visible]:outline", {
|
|
162
|
+
ref: P,
|
|
163
|
+
class: ["group-[.alert]:outline-orange font-code peer relative w-full overflow-hidden whitespace-nowrap text-xs leading-[1.44] -outline-offset-1 has-[:focus-visible]:rounded-[4px] has-[:focus-visible]:outline", {
|
|
162
164
|
"flow-code-input--error": e.error
|
|
163
165
|
}],
|
|
164
166
|
onKeydown: [
|
|
165
|
-
l[4] || (l[4] =
|
|
166
|
-
l[5] || (l[5] =
|
|
167
|
-
l[6] || (l[6] =
|
|
167
|
+
l[4] || (l[4] = V(q((t) => w("down", t), ["stop"]), ["down"])),
|
|
168
|
+
l[5] || (l[5] = V((t) => w("enter", t), ["enter"])),
|
|
169
|
+
l[6] || (l[6] = V(q((t) => w("up", t), ["stop"]), ["up"]))
|
|
168
170
|
]
|
|
169
171
|
}), [
|
|
170
|
-
e.isCopyable ? (n(), i("div",
|
|
171
|
-
|
|
172
|
+
e.isCopyable ? (n(), i("div", ie, [
|
|
173
|
+
g("button", {
|
|
172
174
|
class: "copy-button",
|
|
173
175
|
type: "button",
|
|
174
|
-
onClick: l[3] || (l[3] = (t) =>
|
|
176
|
+
onClick: l[3] || (l[3] = (t) => u(O)(u(_)(e.modelValue)))
|
|
175
177
|
}, [
|
|
176
|
-
l[7] || (l[7] =
|
|
177
|
-
|
|
178
|
+
l[7] || (l[7] = g("span", { class: "sr-only" }, "Copy content", -1)),
|
|
179
|
+
Y(u(Z), {
|
|
178
180
|
icon: "Clipboard",
|
|
179
181
|
size: "md"
|
|
180
182
|
})
|
|
181
183
|
])
|
|
182
184
|
])) : c("", !0)
|
|
183
|
-
], 16,
|
|
184
|
-
e.$slots.warning ? (n(), i("div",
|
|
185
|
-
|
|
185
|
+
], 16, de)),
|
|
186
|
+
e.$slots.warning ? (n(), i("div", pe, [
|
|
187
|
+
R(e.$slots, "warning", {}, void 0, !0)
|
|
186
188
|
])) : c("", !0),
|
|
187
|
-
|
|
188
|
-
e.required ? (n(), i("div",
|
|
189
|
-
y.value && e.withVariables &&
|
|
189
|
+
R(e.$slots, "icon", {}, void 0, !0),
|
|
190
|
+
e.required ? (n(), i("div", me, " Required ")) : c("", !0),
|
|
191
|
+
y.value && e.withVariables && u(b) !== "modal" && e.environment ? (n(), f(ae, {
|
|
190
192
|
key: 7,
|
|
191
193
|
ref_key: "dropdownRef",
|
|
192
194
|
ref: m,
|
|
193
|
-
dropdownPosition:
|
|
194
|
-
envVariables:
|
|
195
|
-
environment:
|
|
196
|
-
query:
|
|
197
|
-
onSelect:
|
|
195
|
+
dropdownPosition: S.value,
|
|
196
|
+
envVariables: e.envVariables,
|
|
197
|
+
environment: e.environment,
|
|
198
|
+
query: k.value,
|
|
199
|
+
onSelect: u(K)
|
|
198
200
|
}, null, 8, ["dropdownPosition", "envVariables", "environment", "query", "onSelect"])) : c("", !0)
|
|
199
201
|
], 64);
|
|
200
202
|
};
|
|
201
203
|
}
|
|
202
204
|
});
|
|
203
205
|
export {
|
|
204
|
-
|
|
206
|
+
ke as default
|
|
205
207
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"codeVariableWidget.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/codeVariableWidget.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"codeVariableWidget.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/codeVariableWidget.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,YAAY,EAAe,MAAM,oBAAoB,CAAA;AAEnE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAA;AACzE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAA;AAErE,OAAO,EACL,UAAU,EACV,KAAK,aAAa,EAClB,UAAU,EAEV,UAAU,EACV,KAAK,UAAU,EAEhB,MAAM,wBAAwB,CAAA;AA+H/B;;GAEG;AACH,eAAO,MAAM,UAAU,UAAW;IAChC,WAAW,EAAE,WAAW,GAAG,SAAS,CAAA;IACpC,YAAY,EAAE,YAAY,GAAG,SAAS,CAAA;IACtC,SAAS,EAAE,SAAS,GAAG,SAAS,CAAA;IAChC,UAAU,EAAE,OAAO,GAAG,SAAS,CAAA;CAChC;iBAGkB,aAAa;mBAMX,UAAU;2BASF,UAAU;EAkCpC,CAAA;AAEH,eAAO,MAAM,gBAAgB,uCA8B3B,CAAA"}
|
|
@@ -23,9 +23,7 @@ class d extends k {
|
|
|
23
23
|
const o = C({
|
|
24
24
|
props: { variableName: { type: String, default: null } },
|
|
25
25
|
render: () => {
|
|
26
|
-
const i = this.envVariables ? R(this.envVariables).find(
|
|
27
|
-
(r) => r.key === this.variableName
|
|
28
|
-
) : void 0, c = i && this.environment ? f(this.environment) : "#8E8E8E";
|
|
26
|
+
const i = this.envVariables ? R(this.envVariables).find((r) => r.key === this.variableName) : void 0, c = i && this.environment ? f(this.environment) : "#8E8E8E";
|
|
29
27
|
e.style.setProperty("--tw-bg-base", c || "#8E8E8E"), e.style.opacity = i != null && i.value ? "1" : "0.5";
|
|
30
28
|
const a = i != null && i.value ? s("div", { class: "p-2" }, i.value) : s("div", { class: "divide-y divide-1/2 grid" }, [
|
|
31
29
|
s("span", { class: "p-2 opacity-25" }, "No value"),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommandPaletteCollection.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteCollection.vue"],"names":[],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"CommandPaletteCollection.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteCollection.vue"],"names":[],"mappings":";;;;;;;AAyQA,wBAOG"}
|
|
@@ -1,23 +1,27 @@
|
|
|
1
|
-
import { defineComponent as v, ref as
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import
|
|
6
|
-
import {
|
|
1
|
+
import { defineComponent as v, ref as u, openBlock as b, createBlock as _, withCtx as l, createVNode as r, unref as c, createTextVNode as k } from "vue";
|
|
2
|
+
import { ScalarButton as C } from "@scalar/components";
|
|
3
|
+
import { LibraryIcon as V } from "@scalar/icons";
|
|
4
|
+
import { useToasts as x } from "@scalar/use-toasts";
|
|
5
|
+
import N from "../IconSelector.vue.js";
|
|
6
|
+
import { useActiveEntities as B } from "../../store/active-entities.js";
|
|
7
7
|
import S from "./CommandActionForm.vue.js";
|
|
8
8
|
import $ from "./CommandActionInput.vue.js";
|
|
9
|
-
import { useWorkspace as
|
|
9
|
+
import { useWorkspace as w } from "../../store/store.js";
|
|
10
10
|
const D = /* @__PURE__ */ v({
|
|
11
11
|
__name: "CommandPaletteCollection",
|
|
12
12
|
emits: ["close", "back"],
|
|
13
|
-
setup(
|
|
14
|
-
const i =
|
|
15
|
-
var
|
|
13
|
+
setup(I, { emit: d }) {
|
|
14
|
+
const i = d, { activeWorkspace: s } = B(), { collectionMutators: f } = w(), o = u(""), a = u("interface-content-folder"), { toast: m } = x(), p = () => {
|
|
15
|
+
var n, e;
|
|
16
16
|
if (!o.value) {
|
|
17
|
-
|
|
17
|
+
m("Please enter a name before creating a collection.", "error");
|
|
18
18
|
return;
|
|
19
19
|
}
|
|
20
|
-
|
|
20
|
+
if (!((n = s.value) != null && n.uid)) {
|
|
21
|
+
m("No active workspace found.", "error");
|
|
22
|
+
return;
|
|
23
|
+
}
|
|
24
|
+
f.add(
|
|
21
25
|
{
|
|
22
26
|
openapi: "3.1.0",
|
|
23
27
|
info: {
|
|
@@ -26,27 +30,27 @@ const D = /* @__PURE__ */ v({
|
|
|
26
30
|
},
|
|
27
31
|
"x-scalar-icon": a.value
|
|
28
32
|
},
|
|
29
|
-
(
|
|
33
|
+
(e = s.value) == null ? void 0 : e.uid
|
|
30
34
|
), i("close");
|
|
31
35
|
};
|
|
32
|
-
return (
|
|
36
|
+
return (n, e) => (b(), _(S, {
|
|
33
37
|
disabled: !o.value.trim(),
|
|
34
|
-
onSubmit:
|
|
38
|
+
onSubmit: p
|
|
35
39
|
}, {
|
|
36
40
|
options: l(() => [
|
|
37
|
-
|
|
41
|
+
r(N, {
|
|
38
42
|
modelValue: a.value,
|
|
39
43
|
"onUpdate:modelValue": e[2] || (e[2] = (t) => a.value = t),
|
|
40
44
|
placement: "bottom-start"
|
|
41
45
|
}, {
|
|
42
46
|
default: l(() => [
|
|
43
|
-
|
|
44
|
-
class: "aspect-square px-0
|
|
47
|
+
r(c(C), {
|
|
48
|
+
class: "aspect-square h-auto px-0",
|
|
45
49
|
variant: "outlined"
|
|
46
50
|
}, {
|
|
47
51
|
default: l(() => [
|
|
48
|
-
|
|
49
|
-
class: "
|
|
52
|
+
r(c(V), {
|
|
53
|
+
class: "text-c-2 size-4 stroke-[1.75]",
|
|
50
54
|
src: a.value
|
|
51
55
|
}, null, 8, ["src"])
|
|
52
56
|
]),
|
|
@@ -57,10 +61,10 @@ const D = /* @__PURE__ */ v({
|
|
|
57
61
|
}, 8, ["modelValue"])
|
|
58
62
|
]),
|
|
59
63
|
submit: l(() => e[3] || (e[3] = [
|
|
60
|
-
|
|
64
|
+
k(" Create Collection ")
|
|
61
65
|
])),
|
|
62
66
|
default: l(() => [
|
|
63
|
-
|
|
67
|
+
r($, {
|
|
64
68
|
modelValue: o.value,
|
|
65
69
|
"onUpdate:modelValue": e[0] || (e[0] = (t) => o.value = t),
|
|
66
70
|
label: "Collection Name",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommandPaletteImport.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteImport.vue"],"names":[],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"CommandPaletteImport.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteImport.vue"],"names":[],"mappings":";;;;;;;AAmqBA,wBAOG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as j, ref as D, computed as I, watch as L, openBlock as l, createBlock as U, unref as r, withCtx as m, createElementVNode as y, createVNode as x, createTextVNode as d, createElementBlock as i, Fragment as v, toDisplayString as V, createCommentVNode as E } from "vue";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
2
|
+
import { useLoadingState as W, ScalarButton as R, ScalarIcon as J, ScalarTooltip as Y, ScalarCodeBlock as q } from "@scalar/components";
|
|
3
|
+
import { useToasts as G } from "@scalar/use-toasts";
|
|
4
|
+
import { useActiveEntities as H } from "../../store/active-entities.js";
|
|
5
5
|
import K from "./CommandActionForm.vue.js";
|
|
6
6
|
import Q from "./CommandActionInput.vue.js";
|
|
7
7
|
import X from "./WatchModeToggle.vue.js";
|
|
@@ -10,7 +10,7 @@ import { getOpenApiDocumentDetails as ee } from "../../libs/getOpenApiDocumentDe
|
|
|
10
10
|
import { isUrl as C } from "../../libs/isUrl.js";
|
|
11
11
|
import { useFileDialog as te } from "../../hooks/useFileDialog.js";
|
|
12
12
|
import { useWorkspace as oe } from "../../store/store.js";
|
|
13
|
-
const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items-center justify-between gap-3
|
|
13
|
+
const ae = { class: "flex justify-between" }, le = { class: "flex w-full flex-row items-center justify-between gap-3" }, ne = { class: "w-content bg-b-1 z-100 text-xxs text-c-1 pointer-events-none z-10 grid max-w-[320px] gap-1.5 rounded p-2 leading-5 shadow-lg" }, se = { class: "text-c-2 flex items-center" }, re = {
|
|
14
14
|
key: 0,
|
|
15
15
|
class: "text-pretty"
|
|
16
16
|
}, ie = {
|
|
@@ -20,7 +20,7 @@ const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items
|
|
|
20
20
|
__name: "CommandPaletteImport",
|
|
21
21
|
emits: ["close", "back"],
|
|
22
22
|
setup(ue, { emit: T }) {
|
|
23
|
-
const S = T, { activeWorkspace: p } =
|
|
23
|
+
const S = T, { activeWorkspace: p } = H(), { importSpecFile: w, importSpecFromUrl: M } = oe(), { toast: u } = G(), c = W(), t = D(""), f = D(!0), s = I(() => P(t.value) ? Z(t.value) : ee(t.value)), _ = I(
|
|
24
24
|
() => s.value ? s.value.type : "json"
|
|
25
25
|
), g = I(() => C(t.value)), $ = I(() => !!s.value), { open: z } = te({
|
|
26
26
|
onChange: async (a) => {
|
|
@@ -101,13 +101,13 @@ const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items
|
|
|
101
101
|
options: m(() => [
|
|
102
102
|
y("div", le, [
|
|
103
103
|
x(r(R), {
|
|
104
|
-
class: "
|
|
104
|
+
class: "hover:bg-b-2 relative max-h-8 gap-1.5 p-2 text-xs",
|
|
105
105
|
variant: "outlined",
|
|
106
106
|
onClick: r(z)
|
|
107
107
|
}, {
|
|
108
108
|
default: m(() => [
|
|
109
109
|
e[6] || (e[6] = d(" JSON, or YAML File ")),
|
|
110
|
-
x(r(
|
|
110
|
+
x(r(J), {
|
|
111
111
|
class: "text-c-3",
|
|
112
112
|
icon: "UploadSimple",
|
|
113
113
|
size: "md"
|
|
@@ -115,7 +115,7 @@ const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items
|
|
|
115
115
|
]),
|
|
116
116
|
_: 1
|
|
117
117
|
}, 8, ["onClick"]),
|
|
118
|
-
x(r(
|
|
118
|
+
x(r(Y), {
|
|
119
119
|
as: "div",
|
|
120
120
|
class: "z-[10001]",
|
|
121
121
|
side: "bottom",
|
|
@@ -150,7 +150,7 @@ const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items
|
|
|
150
150
|
d(V(s.value.version), 1)
|
|
151
151
|
], 64))
|
|
152
152
|
], 64)) : (l(), i(v, { key: 2 }, [
|
|
153
|
-
d("Collection")
|
|
153
|
+
d(" Collection ")
|
|
154
154
|
], 64))
|
|
155
155
|
]),
|
|
156
156
|
default: m(() => [
|
|
@@ -162,9 +162,9 @@ const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items
|
|
|
162
162
|
onOnDelete: e[1] || (e[1] = (o) => S("back", o))
|
|
163
163
|
}, null, 8, ["modelValue"])) : (l(), i(v, { key: 1 }, [
|
|
164
164
|
y("div", ae, [
|
|
165
|
-
e[5] || (e[5] = y("div", { class: "
|
|
165
|
+
e[5] || (e[5] = y("div", { class: "text-c-2 min-h-8 py-2 pl-8 text-xs" }, "Preview", -1)),
|
|
166
166
|
x(r(R), {
|
|
167
|
-
class: "ml-auto
|
|
167
|
+
class: "hover:bg-b-2 relative ml-auto max-h-8 gap-1.5 p-2 text-xs",
|
|
168
168
|
variant: "ghost",
|
|
169
169
|
onClick: e[2] || (e[2] = (o) => t.value = "")
|
|
170
170
|
}, {
|
|
@@ -174,9 +174,9 @@ const ae = { class: "flex justify-between" }, le = { class: "flex flex-row items
|
|
|
174
174
|
_: 1
|
|
175
175
|
})
|
|
176
176
|
]),
|
|
177
|
-
s.value && !r(C)(t.value) ? (l(), U(r(
|
|
177
|
+
s.value && !r(C)(t.value) ? (l(), U(r(q), {
|
|
178
178
|
key: 0,
|
|
179
|
-
class: "
|
|
179
|
+
class: "bg-b-2 mt-1 max-h-[40dvh] rounded border [--scalar-small:--scalar-font-size-4]",
|
|
180
180
|
content: t.value,
|
|
181
181
|
copy: !1,
|
|
182
182
|
lang: _.value
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommandPaletteRequest.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteRequest.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CommandPaletteRequest.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteRequest.vue"],"names":[],"mappings":"AA8MA,KAAK,WAAW,GAAG;IACjB,QAAQ,CAAC,EAAE;QACT,OAAO,EAAE,MAAM,CAAA;QACf,SAAS,EAAE,MAAM,CAAA;KAClB,CAAA;CACF,CAAC;;;;;;;;AA4TF,wBAQG"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { defineComponent as W, ref as c, computed as x, openBlock as h, createBlock as C, withCtx as u, createElementVNode as f, createVNode as i, unref as n, normalizeClass as q, toDisplayString as V, createCommentVNode as j, createTextVNode as H } from "vue";
|
|
2
|
-
import I from "../HttpMethod/HttpMethod.vue.js";
|
|
3
|
-
import { useActiveEntities as P } from "../../store/active-entities.js";
|
|
4
2
|
import { ScalarListbox as w, ScalarButton as D, ScalarIcon as k } from "@scalar/components";
|
|
5
|
-
import { isHttpMethod as
|
|
6
|
-
import { useToasts as
|
|
7
|
-
import { useRouter as
|
|
3
|
+
import { isHttpMethod as I } from "@scalar/oas-utils/helpers";
|
|
4
|
+
import { useToasts as P } from "@scalar/use-toasts";
|
|
5
|
+
import { useRouter as $ } from "vue-router";
|
|
6
|
+
import A from "../HttpMethod/HttpMethod.vue.js";
|
|
7
|
+
import { useActiveEntities as L } from "../../store/active-entities.js";
|
|
8
8
|
import O from "./CommandActionForm.vue.js";
|
|
9
9
|
import F from "./CommandActionInput.vue.js";
|
|
10
10
|
import { useWorkspace as G } from "../../store/store.js";
|
|
@@ -15,12 +15,12 @@ const J = { class: "flex" }, se = /* @__PURE__ */ W({
|
|
|
15
15
|
},
|
|
16
16
|
emits: ["close", "back"],
|
|
17
17
|
setup(S, { emit: _ }) {
|
|
18
|
-
const r = S, b = _, { push: M } =
|
|
18
|
+
const r = S, b = _, { push: M } = $(), { toast: N } = P(), {
|
|
19
19
|
activeCollection: R,
|
|
20
20
|
activeWorkspace: U,
|
|
21
21
|
activeWorkspaceCollections: g,
|
|
22
22
|
activeRequest: y
|
|
23
|
-
} =
|
|
23
|
+
} = L(), { requestMutators: T, tags: z } = G(), o = c(""), m = c("get"), p = x(
|
|
24
24
|
() => g.value.map((t) => {
|
|
25
25
|
var e;
|
|
26
26
|
return {
|
|
@@ -69,7 +69,7 @@ const J = { class: "flex" }, se = /* @__PURE__ */ W({
|
|
|
69
69
|
N("Please enter a name before creating a request.", "error");
|
|
70
70
|
return;
|
|
71
71
|
}
|
|
72
|
-
if (!((e = l.value) != null && e.id) ||
|
|
72
|
+
if (!((e = l.value) != null && e.id) || !I(m.value))
|
|
73
73
|
return;
|
|
74
74
|
const t = T.add(
|
|
75
75
|
{
|
|
@@ -96,7 +96,7 @@ const J = { class: "flex" }, se = /* @__PURE__ */ W({
|
|
|
96
96
|
}, {
|
|
97
97
|
options: u(() => [
|
|
98
98
|
f("div", J, [
|
|
99
|
-
i(
|
|
99
|
+
i(A, {
|
|
100
100
|
isEditable: !0,
|
|
101
101
|
isSquare: "",
|
|
102
102
|
method: m.value,
|
|
@@ -109,7 +109,7 @@ const J = { class: "flex" }, se = /* @__PURE__ */ W({
|
|
|
109
109
|
}, {
|
|
110
110
|
default: u(() => [
|
|
111
111
|
i(n(D), {
|
|
112
|
-
class: "
|
|
112
|
+
class: "hover:bg-b-2 ml-2 max-h-8 w-full justify-between gap-1 p-2 text-xs",
|
|
113
113
|
variant: "outlined"
|
|
114
114
|
}, {
|
|
115
115
|
default: u(() => [
|
|
@@ -135,7 +135,7 @@ const J = { class: "flex" }, se = /* @__PURE__ */ W({
|
|
|
135
135
|
}, {
|
|
136
136
|
default: u(() => [
|
|
137
137
|
i(n(D), {
|
|
138
|
-
class: "
|
|
138
|
+
class: "hover:bg-b-2 ml-2 max-h-8 w-full justify-between gap-1 p-2 text-xs",
|
|
139
139
|
variant: "outlined"
|
|
140
140
|
}, {
|
|
141
141
|
default: u(() => [
|
|
@@ -156,7 +156,7 @@ const J = { class: "flex" }, se = /* @__PURE__ */ W({
|
|
|
156
156
|
])
|
|
157
157
|
]),
|
|
158
158
|
submit: u(() => e[4] || (e[4] = [
|
|
159
|
-
H("Create Request")
|
|
159
|
+
H(" Create Request ")
|
|
160
160
|
])),
|
|
161
161
|
default: u(() => [
|
|
162
162
|
i(F, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommandPaletteServer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteServer.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CommandPaletteServer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CommandPalette/CommandPaletteServer.vue"],"names":[],"mappings":"AAqIA,KAAK,WAAW,GAAG;IACjB,QAAQ,CAAC,EAAE;QACT,OAAO,CAAC,EAAE,MAAM,CAAA;QAChB,SAAS,CAAC,EAAE,MAAM,CAAA;KACnB,CAAA;CACF,CAAC;;;;;;;;AA2PF,wBAQG"}
|