@scalar/api-client 2.1.52 → 2.2.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 +22 -0
- 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 +35 -42
- 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 +25 -24
- package/dist/components/AddressBar/AddressBarServer.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBarServer.vue.js +32 -39
- package/dist/components/AddressBar/AddressBarServerItem.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBarServerItem.vue.js +10 -15
- package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
- package/dist/components/CodeInput/CodeInput.vue.js +1 -1
- package/dist/components/CodeInput/CodeInput.vue2.js +48 -47
- package/dist/components/CodeInput/codeVariableWidget.d.ts +3 -2
- package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +15 -14
- package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteExample.vue.js +18 -23
- package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteImport.vue.js +27 -26
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +19 -20
- package/dist/components/CommandPalette/CommandPaletteServer.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteServer.vue.js +19 -24
- package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteTag.vue.js +23 -22
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue.js +4 -4
- package/dist/components/CommandPalette/TheCommandPalette.vue2.js +47 -46
- package/dist/components/DataTable/DataTableInput.vue.d.ts +1 -1
- package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.d.ts.map +1 -1
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +23 -28
- package/dist/components/HttpMethod/HttpMethod.vue.d.ts +2 -2
- package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/ImportCollectionModal.vue.js +127 -96
- package/dist/components/ImportCollection/ImportNowButton.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/ImportNowButton.vue.js +28 -27
- package/dist/components/ImportCollection/IntegrationLogo.vue.d.ts +1 -1
- package/dist/components/ImportCollection/IntegrationLogo.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/IntegrationLogo.vue.js +14 -18
- package/dist/components/ImportCollection/WorkspaceSelector.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/WorkspaceSelector.vue.js +15 -14
- package/dist/components/Search/useSearch.d.ts.map +1 -1
- package/dist/components/Search/useSearch.js +20 -19
- package/dist/components/SideNav/SideNavRouterLink.vue.js +9 -9
- package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
- package/dist/components/TopNav/TopNav.vue.js +1 -1
- package/dist/components/TopNav/TopNav.vue2.js +20 -19
- package/dist/components/TopNav/TopNavItem.vue.d.ts +2 -2
- package/dist/hooks/index.js +3 -2
- package/dist/hooks/useLayout.d.ts +2 -0
- package/dist/hooks/useLayout.d.ts.map +1 -1
- package/dist/hooks/useLayout.js +4 -3
- package/dist/layouts/App/ApiClientApp.vue.d.ts.map +1 -1
- package/dist/layouts/App/ApiClientApp.vue.js +38 -37
- package/dist/layouts/App/MainLayout.vue.d.ts.map +1 -1
- package/dist/layouts/App/MainLayout.vue.js +3 -3
- package/dist/layouts/App/create-api-client-app.d.ts +669 -1232
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- 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 +24 -23
- package/dist/layouts/Modal/create-api-client-modal.d.ts +1382 -2508
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Web/ApiClientWeb.vue.d.ts.map +1 -1
- package/dist/layouts/Web/ApiClientWeb.vue.js +34 -33
- package/dist/layouts/Web/create-api-client-web.d.ts +669 -1232
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/libs/create-client.d.ts +673 -1236
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/create-client.js +91 -102
- package/dist/libs/hot-keys.d.ts +1 -1
- package/dist/libs/send-request.d.ts +2 -3
- package/dist/libs/send-request.d.ts.map +1 -1
- package/dist/libs/send-request.js +127 -123
- package/dist/store/active-entities.d.ts +333 -0
- package/dist/store/active-entities.d.ts.map +1 -0
- package/dist/store/active-entities.js +97 -0
- package/dist/store/collections.d.ts +4 -274
- package/dist/store/collections.d.ts.map +1 -1
- package/dist/store/cookies.d.ts +4 -4
- package/dist/store/environment.d.ts +4 -4
- package/dist/store/import-spec.d.ts +0 -54
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/index.js +4 -3
- package/dist/store/request-example.d.ts +4 -4
- package/dist/store/requests.d.ts +15 -15
- package/dist/store/security-schemes.d.ts +527 -317
- package/dist/store/security-schemes.d.ts.map +1 -1
- package/dist/store/security-schemes.js +33 -41
- package/dist/store/servers.d.ts +4 -4
- package/dist/store/store-context.d.ts +0 -3
- package/dist/store/store-context.d.ts.map +1 -1
- package/dist/store/store.d.ts +640 -5297
- package/dist/store/store.d.ts.map +1 -1
- package/dist/store/store.js +111 -189
- package/dist/store/tags.d.ts +4 -4
- package/dist/store/workspace.d.ts +14 -24
- package/dist/store/workspace.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/views/Cookies/CookieForm.vue.d.ts.map +1 -1
- package/dist/views/Cookies/CookieForm.vue.js +14 -13
- package/dist/views/Cookies/CookieRaw.vue.d.ts.map +1 -1
- package/dist/views/Cookies/CookieRaw.vue.js +14 -13
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts +3 -3
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
- 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 +92 -92
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +96 -99
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.js +49 -46
- 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 +94 -100
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.js +60 -67
- package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts.map +1 -1
- 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 +29 -28
- package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestParams.vue.js +11 -10
- package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestPathParams.vue.js +24 -28
- 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 +19 -18
- package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +2 -2
- 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 +72 -73
- 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 +111 -109
- package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebarItemMenu.vue.js +2 -2
- package/dist/views/Request/RequestSidebarItemMenu.vue2.js +15 -16
- package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
- package/dist/views/Request/RequestSubpageHeader.vue2.js +14 -14
- 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 +23 -22
- package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
- package/dist/views/Request/components/WorkspaceDropdown.vue.js +32 -31
- package/dist/views/Request/consts/new-auth-options.d.ts +16 -8
- package/dist/views/Request/consts/new-auth-options.d.ts.map +1 -1
- package/dist/views/Request/consts/new-auth-options.js +16 -8
- package/dist/views/Request/handle-drag.d.ts +2 -1
- package/dist/views/Request/handle-drag.d.ts.map +1 -1
- package/dist/views/Request/handle-drag.js +23 -25
- package/dist/views/Request/hooks/useOpenApiWatcher.d.ts.map +1 -1
- package/dist/views/Request/hooks/useOpenApiWatcher.js +40 -39
- package/dist/views/Request/libs/auth.d.ts +1 -29
- package/dist/views/Request/libs/auth.d.ts.map +1 -1
- package/dist/views/Request/libs/auth.js +2 -9
- package/dist/views/Request/libs/index.js +6 -8
- package/dist/views/Request/libs/live-sync.d.ts +6 -5
- package/dist/views/Request/libs/live-sync.d.ts.map +1 -1
- package/dist/views/Request/libs/live-sync.js +164 -185
- package/dist/views/Request/libs/oauth2.d.ts +6 -10
- package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
- package/dist/views/Request/libs/oauth2.js +54 -69
- package/dist/views/Servers/ServerForm.vue.d.ts.map +1 -1
- package/dist/views/Servers/ServerForm.vue.js +14 -13
- package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
- package/dist/views/Servers/Servers.vue2.js +18 -17
- package/dist/views/Settings/SettingsGeneral.vue.d.ts.map +1 -1
- package/dist/views/Settings/SettingsGeneral.vue.js +218 -126
- package/dist/views/Settings/{SettingsGeneralMode.vue.d.ts → components/SettingsAppearance.vue.d.ts} +2 -2
- package/dist/views/Settings/components/SettingsAppearance.vue.d.ts.map +1 -0
- package/dist/views/Settings/components/SettingsAppearance.vue.js +74 -0
- package/dist/views/Settings/components/SettingsAppearance.vue2.js +4 -0
- package/dist/views/Settings/components/SettingsSection.vue.d.ts +24 -0
- package/dist/views/Settings/components/SettingsSection.vue.d.ts.map +1 -0
- package/dist/views/Settings/components/SettingsSection.vue.js +24 -0
- package/dist/views/Settings/components/SettingsSection.vue2.js +4 -0
- package/package.json +8 -8
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthModal.vue.d.ts +0 -16
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthModal.vue.d.ts.map +0 -1
- package/dist/views/Settings/SettingsGeneralMode.vue.d.ts.map +0 -1
- package/dist/views/Settings/SettingsGeneralMode.vue.js +0 -78
- package/dist/views/Settings/SettingsGeneralMode.vue2.js +0 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
# @scalar/api-client
|
|
2
2
|
|
|
3
|
+
## 2.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 37abd4f: feat: bring security schemes closer to the openapi spec
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- daa2663: feat: split out the router based computed values from the store into its own store
|
|
12
|
+
- f67c3bc: feat: add framework themes
|
|
13
|
+
- Updated dependencies [d379b81]
|
|
14
|
+
- Updated dependencies [daa2663]
|
|
15
|
+
- Updated dependencies [f67c3bc]
|
|
16
|
+
- Updated dependencies [28a6b05]
|
|
17
|
+
- Updated dependencies [37abd4f]
|
|
18
|
+
- @scalar/themes@0.9.49
|
|
19
|
+
- @scalar/oas-utils@0.2.78
|
|
20
|
+
- @scalar/types@0.0.20
|
|
21
|
+
- @scalar/components@0.12.73
|
|
22
|
+
- @scalar/use-hooks@0.1.2
|
|
23
|
+
- @scalar/use-codemirror@0.11.40
|
|
24
|
+
|
|
3
25
|
## 2.1.52
|
|
4
26
|
|
|
5
27
|
### Patch Changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddressBar.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBar.vue"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"AddressBar.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBar.vue"],"names":[],"mappings":";;;;;AAswBA,wBAMG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./AddressBar.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import r from "../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const d = /* @__PURE__ */ r(o, [["__scopeId", "data-v-
|
|
4
|
+
const d = /* @__PURE__ */ r(o, [["__scopeId", "data-v-156a9bd9"]]);
|
|
5
5
|
export {
|
|
6
6
|
d as default
|
|
7
7
|
};
|
|
@@ -1,35 +1,28 @@
|
|
|
1
|
-
import { defineComponent as H, ref as u, watch as L, onMounted as z, onBeforeUnmount as
|
|
1
|
+
import { defineComponent as H, ref as u, watch as L, onMounted as z, onBeforeUnmount as A, unref as a, openBlock as K, createElementBlock as O, createElementVNode as o, createVNode as n, withCtx as w, normalizeClass as y, normalizeStyle as N, createCommentVNode as T } from "vue";
|
|
2
2
|
import $ from "../CodeInput/CodeInput.vue.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import J from "
|
|
9
|
-
import X from "
|
|
10
|
-
import Y from "./
|
|
11
|
-
import
|
|
12
|
-
|
|
3
|
+
import { useActiveEntities as P } from "../../store/active-entities.js";
|
|
4
|
+
import { Listbox as D } from "@headlessui/vue";
|
|
5
|
+
import { ScalarButton as Q, ScalarIcon as W } from "@scalar/components";
|
|
6
|
+
import { REQUEST_METHODS as j } from "@scalar/oas-utils/helpers";
|
|
7
|
+
import { isMacOS as F } from "@scalar/use-tooltip";
|
|
8
|
+
import { useMagicKeys as G, whenever as J } from "@vueuse/core";
|
|
9
|
+
import X from "../HttpMethod/HttpMethod.vue.js";
|
|
10
|
+
import Y from "./AddressBarHistory.vue.js";
|
|
11
|
+
import Z from "./AddressBarServer.vue.js";
|
|
12
|
+
import { useWorkspace as ee } from "../../store/store.js";
|
|
13
|
+
const te = {
|
|
13
14
|
key: 0,
|
|
14
15
|
class: "order-last lg:order-none lg:w-auto w-full"
|
|
15
|
-
},
|
|
16
|
+
}, le = { class: "m-auto flex flex-row items-center" }, oe = { class: "pointer-events-none absolute left-0 top-0 block h-full w-full overflow-hidden" }, ae = { class: "flex gap-1" }, re = { class: "codemirror-bg-switcher scroll-timeline-x scroll-timeline-x-hidden relative flex w-full" }, se = {
|
|
16
17
|
"aria-hidden": "true",
|
|
17
18
|
class: "inline-flex gap-1 items-center"
|
|
18
|
-
},
|
|
19
|
+
}, we = /* @__PURE__ */ H({
|
|
19
20
|
__name: "AddressBar",
|
|
20
21
|
emits: ["importCurl"],
|
|
21
|
-
setup(
|
|
22
|
-
const {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
activeServer: _,
|
|
26
|
-
isReadOnly: c,
|
|
27
|
-
requestMutators: m,
|
|
28
|
-
requestHistory: R,
|
|
29
|
-
events: d
|
|
30
|
-
} = Z(), v = u(R[0]), p = u(null), x = F();
|
|
31
|
-
G(
|
|
32
|
-
j() ? x.meta_enter : x.ctrl_enter,
|
|
22
|
+
setup(ne) {
|
|
23
|
+
const { activeRequest: l, activeExample: C, activeServer: _ } = P(), { isReadOnly: c, requestMutators: m, requestHistory: R, events: d } = ee(), v = u(R[0]), p = u(null), x = G();
|
|
24
|
+
J(
|
|
25
|
+
F() ? x.meta_enter : x.ctrl_enter,
|
|
33
26
|
() => d.executeRequest.emit()
|
|
34
27
|
);
|
|
35
28
|
const k = (e) => {
|
|
@@ -51,14 +44,14 @@ const ee = {
|
|
|
51
44
|
function B() {
|
|
52
45
|
i.value || (s.value = !0, i.value = setInterval(q, 20));
|
|
53
46
|
}
|
|
54
|
-
function
|
|
47
|
+
function E() {
|
|
55
48
|
h.value = r.value, s.value = !1;
|
|
56
49
|
}
|
|
57
|
-
function
|
|
50
|
+
function S() {
|
|
58
51
|
clearInterval(i.value), i.value = void 0, r.value = 100, s.value = !1;
|
|
59
52
|
}
|
|
60
53
|
d.requestStatus.on((e) => {
|
|
61
|
-
e === "start" && B(), e === "stop" &&
|
|
54
|
+
e === "start" && B(), e === "stop" && E(), e === "abort" && S();
|
|
62
55
|
});
|
|
63
56
|
function V(e) {
|
|
64
57
|
l.value && m.edit(l.value.uid, "method", e);
|
|
@@ -66,7 +59,7 @@ const ee = {
|
|
|
66
59
|
function M() {
|
|
67
60
|
if (!l.value) return;
|
|
68
61
|
const { method: e } = l.value;
|
|
69
|
-
return
|
|
62
|
+
return j[e].backgroundColor;
|
|
70
63
|
}
|
|
71
64
|
function b() {
|
|
72
65
|
s.value || (s.value = !0, d.executeRequest.emit());
|
|
@@ -78,9 +71,9 @@ const ee = {
|
|
|
78
71
|
var t;
|
|
79
72
|
e != null && e.focusAddressBar && ((t = p.value) == null || t.focus());
|
|
80
73
|
}
|
|
81
|
-
return z(() => d.hotKeys.on(g)),
|
|
82
|
-
o("div",
|
|
83
|
-
n(a(
|
|
74
|
+
return z(() => d.hotKeys.on(g)), A(() => d.hotKeys.off(g)), (e, t) => a(l) && a(C) ? (K(), O("div", te, [
|
|
75
|
+
o("div", le, [
|
|
76
|
+
n(a(D), {
|
|
84
77
|
modelValue: v.value,
|
|
85
78
|
"onUpdate:modelValue": t[1] || (t[1] = (f) => v.value = f)
|
|
86
79
|
}, {
|
|
@@ -91,14 +84,14 @@ const ee = {
|
|
|
91
84
|
{ "border-transparent overflow-visible rounded-b-none": f }
|
|
92
85
|
])
|
|
93
86
|
}, [
|
|
94
|
-
o("div",
|
|
87
|
+
o("div", oe, [
|
|
95
88
|
o("div", {
|
|
96
89
|
class: y(["bg-mix-transparent bg-mix-amount-90 absolute left-0 top-0 h-full w-full z-context", M()]),
|
|
97
90
|
style: N({ transform: `translate3d(-${r.value}%,0,0)` })
|
|
98
91
|
}, null, 6)
|
|
99
92
|
]),
|
|
100
|
-
o("div",
|
|
101
|
-
n(
|
|
93
|
+
o("div", ae, [
|
|
94
|
+
n(X, {
|
|
102
95
|
isEditable: !a(c),
|
|
103
96
|
isSquare: "",
|
|
104
97
|
method: a(l).method,
|
|
@@ -106,9 +99,9 @@ const ee = {
|
|
|
106
99
|
onChange: V
|
|
107
100
|
}, null, 8, ["isEditable", "method"])
|
|
108
101
|
]),
|
|
109
|
-
o("div",
|
|
102
|
+
o("div", re, [
|
|
110
103
|
t[2] || (t[2] = o("div", { class: "fade-left" }, null, -1)),
|
|
111
|
-
n(
|
|
104
|
+
n(Z),
|
|
112
105
|
n($, {
|
|
113
106
|
ref_key: "addressBarRef",
|
|
114
107
|
ref: p,
|
|
@@ -129,15 +122,15 @@ const ee = {
|
|
|
129
122
|
}, null, 8, ["disabled", "modelValue", "placeholder"]),
|
|
130
123
|
t[3] || (t[3] = o("div", { class: "fade-right" }, null, -1))
|
|
131
124
|
]),
|
|
132
|
-
n(
|
|
133
|
-
n(a(
|
|
125
|
+
n(Y, { open: f }, null, 8, ["open"]),
|
|
126
|
+
n(a(Q), {
|
|
134
127
|
class: "relative h-auto shrink-0 overflow-hidden pl-2 pr-2.5 py-1 font-bold",
|
|
135
128
|
disabled: s.value,
|
|
136
129
|
onClick: b
|
|
137
130
|
}, {
|
|
138
131
|
default: w(() => [
|
|
139
|
-
o("span",
|
|
140
|
-
n(a(
|
|
132
|
+
o("span", se, [
|
|
133
|
+
n(a(W), {
|
|
141
134
|
class: "relative shrink-0 fill-current",
|
|
142
135
|
icon: "Play",
|
|
143
136
|
size: "xs"
|
|
@@ -157,5 +150,5 @@ const ee = {
|
|
|
157
150
|
}
|
|
158
151
|
});
|
|
159
152
|
export {
|
|
160
|
-
|
|
153
|
+
we as default
|
|
161
154
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddressBarHistory.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarHistory.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AddressBarHistory.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarHistory.vue"],"names":[],"mappings":"AAmIA,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,OAAO,CAAA;CACd,CAAC;;AAoOF,wBAMG"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./AddressBarHistory.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import r from "../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const d = /* @__PURE__ */ r(o, [["__scopeId", "data-v-69d275b6"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
d as default
|
|
7
7
|
};
|
|
@@ -1,35 +1,36 @@
|
|
|
1
|
-
import { defineComponent as C, computed as q, openBlock as u, createElementBlock as b, Fragment as h, createBlock as i, unref as o, withCtx as c, createVNode as x, createCommentVNode as v, createElementVNode as
|
|
1
|
+
import { defineComponent as C, computed as q, openBlock as u, createElementBlock as b, Fragment as h, createBlock as i, unref as o, withCtx as c, createVNode as x, createCommentVNode as v, createElementVNode as s, normalizeClass as g, renderList as B, toDisplayString as l } from "vue";
|
|
2
2
|
import { formatMs as H } from "../../libs/formatters.js";
|
|
3
|
-
import {
|
|
3
|
+
import { useActiveEntities as y } from "../../store/active-entities.js";
|
|
4
|
+
import { ListboxButton as E, ListboxOptions as L, ListboxOption as S } from "@headlessui/vue";
|
|
4
5
|
import { ScalarIcon as z } from "@scalar/components";
|
|
5
|
-
import { httpStatusCodes as
|
|
6
|
-
import { useRouter as
|
|
7
|
-
import
|
|
8
|
-
import { getStatusCodeColor as
|
|
9
|
-
import { useWorkspace as
|
|
10
|
-
const
|
|
6
|
+
import { httpStatusCodes as M } from "@scalar/oas-utils/helpers";
|
|
7
|
+
import { useRouter as N } from "vue-router";
|
|
8
|
+
import U from "../HttpMethod/HttpMethod.vue.js";
|
|
9
|
+
import { getStatusCodeColor as V } from "./httpStatusCodeColors.js";
|
|
10
|
+
import { useWorkspace as $ } from "../../store/store.js";
|
|
11
|
+
const A = { class: "min-w-0" }, I = { class: "min-w-0 truncate text-c-1" }, T = /* @__PURE__ */ C({
|
|
11
12
|
__name: "AddressBarHistory",
|
|
12
13
|
props: {
|
|
13
14
|
open: { type: Boolean }
|
|
14
15
|
},
|
|
15
16
|
setup(O) {
|
|
16
|
-
const { activeRequest: d, requestHistory: k, requestExampleMutators: _ } =
|
|
17
|
+
const { activeRequest: d } = y(), { requestHistory: k, requestExampleMutators: _ } = $(), p = N(), m = q(
|
|
17
18
|
() => k.filter((t) => {
|
|
18
|
-
var
|
|
19
|
-
return t.request.requestUid === ((
|
|
19
|
+
var r;
|
|
20
|
+
return t.request.requestUid === ((r = d.value) == null ? void 0 : r.uid);
|
|
20
21
|
}).slice().reverse()
|
|
21
22
|
);
|
|
22
23
|
function w(t) {
|
|
23
24
|
var n;
|
|
24
|
-
const
|
|
25
|
+
const r = p.currentRoute.value.params.workspace;
|
|
25
26
|
((n = d.value) == null ? void 0 : n.uid) !== t.request.requestUid && p.push(
|
|
26
|
-
`/workspace/${
|
|
27
|
+
`/workspace/${r}/request/${t.request.requestUid}`
|
|
27
28
|
), _.set({ ...t.request });
|
|
28
29
|
}
|
|
29
|
-
return (t,
|
|
30
|
+
return (t, r) => {
|
|
30
31
|
var n;
|
|
31
32
|
return u(), b(h, null, [
|
|
32
|
-
(n = m.value) != null && n.length ? (u(), i(o(
|
|
33
|
+
(n = m.value) != null && n.length ? (u(), i(o(E), {
|
|
33
34
|
key: 0,
|
|
34
35
|
class: "addressbar-history-button mr-1 rounded-lg p-1.5 text-c-3 focus:text-c-1"
|
|
35
36
|
}, {
|
|
@@ -42,7 +43,7 @@ const $ = { class: "min-w-0" }, I = { class: "min-w-0 truncate text-c-1" }, P =
|
|
|
42
43
|
]),
|
|
43
44
|
_: 1
|
|
44
45
|
})) : v("", !0),
|
|
45
|
-
|
|
46
|
+
s("div", {
|
|
46
47
|
class: g([
|
|
47
48
|
"absolute bg-white left-0 top-8 w-full rounded-lg before:pointer-events-none before:absolute before:left-0 before:-top-8 before:h-[calc(100%+32px)] before:w-full before:rounded-lg z-context",
|
|
48
49
|
{ "before:shadow-lg": t.open }
|
|
@@ -59,19 +60,19 @@ const $ = { class: "min-w-0" }, I = { class: "min-w-0 truncate text-c-1" }, P =
|
|
|
59
60
|
default: c(() => {
|
|
60
61
|
var a;
|
|
61
62
|
return [
|
|
62
|
-
e.response.method ? (u(), i(
|
|
63
|
+
e.response.method ? (u(), i(U, {
|
|
63
64
|
key: 0,
|
|
64
65
|
class: "text-[11px]",
|
|
65
66
|
method: e.response.method
|
|
66
67
|
}, null, 8, ["method"])) : v("", !0),
|
|
67
|
-
|
|
68
|
-
|
|
68
|
+
s("div", A, [
|
|
69
|
+
s("div", I, l(e.response.path), 1)
|
|
69
70
|
]),
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
class: g([o(
|
|
71
|
+
s("div", null, l(o(H)(e.response.duration)), 1),
|
|
72
|
+
s("div", {
|
|
73
|
+
class: g([o(V)(e.response.status).color])
|
|
73
74
|
}, l(e.response.status), 3),
|
|
74
|
-
|
|
75
|
+
s("div", null, l((a = o(M)[e.response.status]) == null ? void 0 : a.name), 1)
|
|
75
76
|
];
|
|
76
77
|
}),
|
|
77
78
|
_: 2
|
|
@@ -85,5 +86,5 @@ const $ = { class: "min-w-0" }, I = { class: "min-w-0 truncate text-c-1" }, P =
|
|
|
85
86
|
}
|
|
86
87
|
});
|
|
87
88
|
export {
|
|
88
|
-
|
|
89
|
+
T as default
|
|
89
90
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddressBarServer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarServer.vue"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"AddressBarServer.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarServer.vue"],"names":[],"mappings":";AAqWA,wBAKG"}
|
|
@@ -1,28 +1,21 @@
|
|
|
1
|
-
import { defineComponent as V, computed as u, watch as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
|
|
1
|
+
import { defineComponent as V, computed as u, watch as E, openBlock as l, createBlock as S, unref as n, withCtx as w, createElementBlock as o, createCommentVNode as v, Fragment as m, renderList as g, createVNode as p, createElementVNode as a, createTextVNode as O, toDisplayString as b } from "vue";
|
|
2
|
+
import { useActiveEntities as R } from "../../store/active-entities.js";
|
|
3
|
+
import { ScalarDropdown as W, ScalarDropdownDivider as A, ScalarDropdownItem as I, ScalarIcon as L } from "@scalar/components";
|
|
4
|
+
import C from "./AddressBarServerItem.vue.js";
|
|
5
|
+
import { useWorkspace as T } from "../../store/store.js";
|
|
6
|
+
const j = {
|
|
6
7
|
class: "font-code lg:text-sm text-xs whitespace-nowrap border border-b-3 border-solid rounded px-1.5 py-0.5 text-c-2 -outline-offset-1",
|
|
7
8
|
type: "button"
|
|
8
|
-
},
|
|
9
|
+
}, F = {
|
|
9
10
|
key: 0,
|
|
10
11
|
class: "text-xxs text-c-2 ml-8"
|
|
11
|
-
},
|
|
12
|
+
}, M = { class: "flex items-center justify-center h-4 w-4" }, P = {
|
|
12
13
|
key: 1,
|
|
13
14
|
class: "flex whitespace-nowrap items-center font-code lg:text-sm text-xs"
|
|
14
|
-
},
|
|
15
|
+
}, K = /* @__PURE__ */ V({
|
|
15
16
|
__name: "AddressBarServer",
|
|
16
|
-
setup(
|
|
17
|
-
const {
|
|
18
|
-
activeRequest: y,
|
|
19
|
-
activeCollection: h,
|
|
20
|
-
activeServer: x,
|
|
21
|
-
isReadOnly: A,
|
|
22
|
-
servers: k,
|
|
23
|
-
collectionMutators: N,
|
|
24
|
-
events: B
|
|
25
|
-
} = L(), c = u(
|
|
17
|
+
setup($) {
|
|
18
|
+
const { activeRequest: y, activeCollection: h, activeServer: x } = R(), { isReadOnly: D, servers: k, collectionMutators: N, events: B } = T(), c = u(
|
|
26
19
|
() => {
|
|
27
20
|
var t, e;
|
|
28
21
|
return (e = (t = y.value) == null ? void 0 : t.servers) == null ? void 0 : e.map((r) => {
|
|
@@ -33,7 +26,7 @@ const T = {
|
|
|
33
26
|
};
|
|
34
27
|
});
|
|
35
28
|
}
|
|
36
|
-
),
|
|
29
|
+
), d = u(
|
|
37
30
|
() => {
|
|
38
31
|
var t, e;
|
|
39
32
|
return (e = (t = h.value) == null ? void 0 : t.servers) == null ? void 0 : e.map((r) => {
|
|
@@ -47,10 +40,10 @@ const T = {
|
|
|
47
40
|
), _ = u(
|
|
48
41
|
() => {
|
|
49
42
|
var t, e;
|
|
50
|
-
return ((t = c.value) == null ? void 0 : t.length) && ((e =
|
|
43
|
+
return ((t = c.value) == null ? void 0 : t.length) && ((e = d.value) == null ? void 0 : e.length);
|
|
51
44
|
}
|
|
52
45
|
);
|
|
53
|
-
|
|
46
|
+
E([h, y], ([t, e]) => {
|
|
54
47
|
!t || t.selectedServerUid || e != null && e.selectedServerUid || N.edit(
|
|
55
48
|
t.uid,
|
|
56
49
|
"selectedServerUid",
|
|
@@ -65,37 +58,37 @@ const T = {
|
|
|
65
58
|
});
|
|
66
59
|
return (t, e) => {
|
|
67
60
|
var r, s;
|
|
68
|
-
return c.value && ((r = c.value) == null ? void 0 : r.length) > 1 ||
|
|
61
|
+
return c.value && ((r = c.value) == null ? void 0 : r.length) > 1 || d.value && ((s = d.value) == null ? void 0 : s.length) > 1 ? (l(), S(n(W), {
|
|
69
62
|
key: 0,
|
|
70
63
|
class: "w-max",
|
|
71
64
|
teleport: ".scalar-client"
|
|
72
65
|
}, {
|
|
73
66
|
items: w(() => [
|
|
74
|
-
_.value ? (l(), o("div",
|
|
75
|
-
(l(!0), o(m, null, g(c.value, (
|
|
76
|
-
key:
|
|
77
|
-
serverOption:
|
|
67
|
+
_.value ? (l(), o("div", F, " Request Servers ")) : v("", !0),
|
|
68
|
+
(l(!0), o(m, null, g(c.value, (i) => (l(), S(C, {
|
|
69
|
+
key: i.id,
|
|
70
|
+
serverOption: i,
|
|
78
71
|
type: "request"
|
|
79
72
|
}, null, 8, ["serverOption"]))), 128)),
|
|
80
73
|
_.value ? (l(), o(m, { key: 1 }, [
|
|
81
|
-
p(n(
|
|
74
|
+
p(n(A)),
|
|
82
75
|
e[1] || (e[1] = a("div", { class: "text-xxs text-c-2 ml-8" }, "Collection Servers", -1))
|
|
83
76
|
], 64)) : v("", !0),
|
|
84
|
-
(l(!0), o(m, null, g(
|
|
85
|
-
key:
|
|
86
|
-
serverOption:
|
|
77
|
+
(l(!0), o(m, null, g(d.value, (i) => (l(), S(C, {
|
|
78
|
+
key: i.id,
|
|
79
|
+
serverOption: i,
|
|
87
80
|
type: "collection"
|
|
88
81
|
}, null, 8, ["serverOption"]))), 128)),
|
|
89
|
-
n(
|
|
90
|
-
p(n(
|
|
91
|
-
p(n(
|
|
82
|
+
n(D) ? v("", !0) : (l(), o(m, { key: 2 }, [
|
|
83
|
+
p(n(A)),
|
|
84
|
+
p(n(I), null, {
|
|
92
85
|
default: w(() => [
|
|
93
86
|
a("div", {
|
|
94
87
|
class: "font-code text-xxs flex items-center gap-1.5",
|
|
95
88
|
onClick: U
|
|
96
89
|
}, [
|
|
97
|
-
a("div",
|
|
98
|
-
p(n(
|
|
90
|
+
a("div", M, [
|
|
91
|
+
p(n(L), {
|
|
99
92
|
class: "h-2.5",
|
|
100
93
|
icon: "Add"
|
|
101
94
|
})
|
|
@@ -108,16 +101,16 @@ const T = {
|
|
|
108
101
|
], 64))
|
|
109
102
|
]),
|
|
110
103
|
default: w(() => [
|
|
111
|
-
a("button",
|
|
104
|
+
a("button", j, [
|
|
112
105
|
e[0] || (e[0] = a("span", { class: "sr-only" }, "Server:", -1)),
|
|
113
|
-
|
|
106
|
+
O(" " + b(f.value), 1)
|
|
114
107
|
])
|
|
115
108
|
]),
|
|
116
109
|
_: 1
|
|
117
|
-
})) : f.value ? (l(), o("div",
|
|
110
|
+
})) : f.value ? (l(), o("div", P, b(f.value), 1)) : v("", !0);
|
|
118
111
|
};
|
|
119
112
|
}
|
|
120
113
|
});
|
|
121
114
|
export {
|
|
122
|
-
|
|
115
|
+
K as default
|
|
123
116
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddressBarServerItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarServerItem.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AddressBarServerItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/AddressBar/AddressBarServerItem.vue"],"names":[],"mappings":"AAoEA,MAAM,MAAM,YAAY,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CACvD;;kBAIe,YAAY;UACpB,YAAY,GAAG,SAAS;;kBADhB,YAAY;UACpB,YAAY,GAAG,SAAS;;AAJhC,wBAuJK"}
|
|
@@ -1,20 +1,15 @@
|
|
|
1
1
|
import { defineComponent as v, openBlock as f, createBlock as m, unref as i, withCtx as S, createElementVNode as a, normalizeClass as x, createVNode as h, toDisplayString as w } from "vue";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
|
|
2
|
+
import { useActiveEntities as k } from "../../store/active-entities.js";
|
|
3
|
+
import { ScalarDropdownItem as C, ScalarIcon as g } from "@scalar/components";
|
|
4
|
+
import { useWorkspace as y } from "../../store/store.js";
|
|
5
|
+
const O = { class: "whitespace-nowrap text-ellipsis overflow-hidden" }, _ = /* @__PURE__ */ v({
|
|
5
6
|
__name: "AddressBarServerItem",
|
|
6
7
|
props: {
|
|
7
8
|
serverOption: {},
|
|
8
9
|
type: {}
|
|
9
10
|
},
|
|
10
11
|
setup(l) {
|
|
11
|
-
const r = l, {
|
|
12
|
-
activeCollection: o,
|
|
13
|
-
activeRequest: s,
|
|
14
|
-
activeServer: n,
|
|
15
|
-
collectionMutators: c,
|
|
16
|
-
requestMutators: p
|
|
17
|
-
} = g(), d = (e) => {
|
|
12
|
+
const r = l, { activeCollection: o, activeRequest: s, activeServer: n } = k(), { collectionMutators: c, requestMutators: p } = y(), d = (e) => {
|
|
18
13
|
r.type === "collection" && o.value ? c.edit(
|
|
19
14
|
o.value.uid,
|
|
20
15
|
"selectedServerUid",
|
|
@@ -28,10 +23,10 @@ const y = { class: "whitespace-nowrap text-ellipsis overflow-hidden" }, B = /* @
|
|
|
28
23
|
var t;
|
|
29
24
|
return ((t = n.value) == null ? void 0 : t.uid) === e;
|
|
30
25
|
};
|
|
31
|
-
return (e, t) => (f(), m(i(
|
|
26
|
+
return (e, t) => (f(), m(i(C), {
|
|
32
27
|
class: "flex !gap-1.5 group font-code text-xxs whitespace-nowrap text-ellipsis overflow-hidden",
|
|
33
28
|
value: e.serverOption.id,
|
|
34
|
-
onClick: t[0] || (t[0] = (
|
|
29
|
+
onClick: t[0] || (t[0] = (b) => d(e.serverOption.id))
|
|
35
30
|
}, {
|
|
36
31
|
default: S(() => [
|
|
37
32
|
a("div", {
|
|
@@ -40,18 +35,18 @@ const y = { class: "whitespace-nowrap text-ellipsis overflow-hidden" }, B = /* @
|
|
|
40
35
|
u(e.serverOption.id) ? "bg-c-accent text-b-1" : "group-hover:shadow-border text-transparent"
|
|
41
36
|
])
|
|
42
37
|
}, [
|
|
43
|
-
h(i(
|
|
38
|
+
h(i(g), {
|
|
44
39
|
class: "relative top-[0.5px] size-2.5",
|
|
45
40
|
icon: "Checkmark",
|
|
46
41
|
thickness: "3.5"
|
|
47
42
|
})
|
|
48
43
|
], 2),
|
|
49
|
-
a("span",
|
|
44
|
+
a("span", O, w(e.serverOption.label), 1)
|
|
50
45
|
]),
|
|
51
46
|
_: 1
|
|
52
47
|
}, 8, ["value"]));
|
|
53
48
|
}
|
|
54
49
|
});
|
|
55
50
|
export {
|
|
56
|
-
|
|
51
|
+
_ as default
|
|
57
52
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CodeInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/CodeInput.vue"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"CodeInput.vue.d.ts","sourceRoot":"","sources":["../../../src/components/CodeInput/CodeInput.vue"],"names":[],"mappings":"AAAA,OA6cO,EAGL,KAAK,kBAAkB,EAGxB,MAAM,wBAAwB,CAAA;;kBAkBb,OAAO;gBACT,MAAM,GAAG,MAAM;YACnB,OAAO;iBACF,OAAO;kBACN,OAAO;WACd,OAAO;uBACK,OAAO;eACf,kBAAkB;wBACT,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;wBACnB,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;kBACzB,MAAM;eACT,OAAO;mBACH,OAAO;2BACC,OAAO;WACvB,MAAM,EAAE;WACR,MAAM;eACF,OAAO;oBACF,OAAO;iBACV,OAAO;iBACP,OAAO;cACV,MAAM,GAAG,MAAM;;;;;;;;kBApBX,OAAO;gBACT,MAAM,GAAG,MAAM;YACnB,OAAO;iBACF,OAAO;kBACN,OAAO;WACd,OAAO;uBACK,OAAO;eACf,kBAAkB;wBACT,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;wBACnB,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI;kBACzB,MAAM;eACT,OAAO;mBACH,OAAO;2BACC,OAAO;WACvB,MAAM,EAAE;WACR,MAAM;eACF,OAAO;oBACF,OAAO;iBACV,OAAO;iBACP,OAAO;cACV,MAAM,GAAG,MAAM;;;;;;gBAjBZ,OAAO;iBAHN,OAAO;sBAMF,OAAO;kBAMX,OAAO;0BACC,OAAO;cAGnB,OAAO;mBACF,OAAO;gBAEV,OAAO;;qBAmZM,GAAG;kBACN,GAAG;;AA1a9B,wBAweC;AAgBD,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
|
|
@@ -2,7 +2,7 @@ import o from "./CodeInput.vue2.js";
|
|
|
2
2
|
/* empty css */
|
|
3
3
|
/* empty css */
|
|
4
4
|
import t from "../../_virtual/_plugin-vue_export-helper.js";
|
|
5
|
-
const _ = /* @__PURE__ */ t(o, [["__scopeId", "data-v-
|
|
5
|
+
const _ = /* @__PURE__ */ t(o, [["__scopeId", "data-v-c2f7308b"]]);
|
|
6
6
|
export {
|
|
7
7
|
_ as default
|
|
8
8
|
};
|