@scalar/api-client 2.2.3 → 2.2.6
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 +69 -0
- package/dist/components/AddressBar/AddressBarServer.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBarServer.vue.js +15 -15
- package/dist/components/CommandPalette/CommandPaletteExample.vue.js +1 -1
- package/dist/components/CommandPalette/CommandPaletteImport.vue.js +1 -1
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +24 -24
- package/dist/components/CommandPalette/CommandPaletteServer.vue.js +2 -2
- package/dist/components/CommandPalette/CommandPaletteTag.vue.js +5 -5
- package/dist/components/DataTable/DataTableCheckbox.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableCheckbox.vue.js +5 -6
- package/dist/components/DataTable/DataTableInputSelect.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableInputSelect.vue.js +8 -8
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.d.ts.map +1 -1
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +37 -47
- package/dist/components/HttpMethod/HttpMethod.vue.d.ts.map +1 -1
- package/dist/components/HttpMethod/HttpMethod.vue.js +2 -2
- package/dist/components/HttpMethod/HttpMethod.vue2.js +16 -17
- package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/ImportCollectionModal.vue.js +85 -84
- package/dist/components/ImportCollection/ImportNowButton.vue.js +3 -3
- package/dist/components/ImportCollection/WorkspaceSelector.vue.d.ts.map +1 -1
- package/dist/components/ImportCollection/WorkspaceSelector.vue.js +24 -26
- package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts +6 -0
- package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts.map +1 -1
- package/dist/components/ImportCollection/hooks/useUrlPrefetcher.js +28 -23
- package/dist/components/OpenApiClientButton.vue.d.ts.map +1 -1
- package/dist/components/OpenApiClientButton.vue.js +1 -1
- package/dist/components/OpenApiClientButton.vue2.js +16 -16
- package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
- package/dist/components/TopNav/TopNav.vue.js +72 -70
- package/dist/components/TopNav/TopNavItem.vue.d.ts.map +1 -1
- package/dist/components/TopNav/TopNavItem.vue.js +1 -1
- package/dist/components/TopNav/TopNavItem.vue2.js +83 -81
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
- package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +5 -6
- package/dist/layouts/App/create-api-client-app.d.ts +3 -2
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- package/dist/layouts/App/create-api-client-app.js +6 -6
- package/dist/layouts/Modal/create-api-client-modal.d.ts +6 -4
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.js +1 -1
- package/dist/layouts/Web/create-api-client-web.d.ts +3 -2
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/layouts/Web/create-api-client-web.js +4 -4
- package/dist/libs/create-client.d.ts +6 -5
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/create-client.js +38 -37
- package/dist/libs/index.d.ts +1 -2
- package/dist/libs/index.d.ts.map +1 -1
- package/dist/libs/index.js +20 -20
- package/dist/libs/send-request/index.d.ts +2 -0
- package/dist/libs/send-request/index.d.ts.map +1 -0
- package/dist/libs/send-request/index.js +9 -0
- package/dist/libs/{send-request.d.ts → send-request/send-request.d.ts} +6 -6
- package/dist/libs/send-request/send-request.d.ts.map +1 -0
- package/dist/libs/{send-request.js → send-request/send-request.js} +29 -29
- package/dist/store/events.d.ts +1 -1
- package/dist/store/import-spec.d.ts +1 -1
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/import-spec.js +1 -1
- package/dist/store/store.d.ts +6 -4
- package/dist/store/store.d.ts.map +1 -1
- package/dist/store/store.js +47 -45
- package/dist/style.css +1 -1
- package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
- package/dist/views/Cookies/Cookies.vue2.js +18 -20
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +76 -72
- package/dist/views/Request/Request.vue.js +1 -1
- package/dist/views/Request/Request.vue2.js +30 -30
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +20 -19
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +2 -2
- 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 +245 -191
- package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebar.vue.js +3 -3
- package/dist/views/Request/RequestSidebar.vue2.js +60 -61
- 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 +188 -196
- package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebarItemMenu.vue.js +3 -3
- package/dist/views/Request/RequestSidebarItemMenu.vue2.js +153 -147
- 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 +24 -28
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue2.js +5 -5
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +2 -2
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +30 -25
- package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.js +41 -30
- package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
- package/dist/views/Request/components/WorkspaceDropdown.vue.js +50 -58
- package/dist/views/Request/libs/oauth2.d.ts +6 -2
- package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
- package/dist/views/Request/libs/oauth2.js +43 -37
- package/package.json +18 -14
- package/dist/libs/send-request.d.ts.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,74 @@
|
|
|
1
1
|
# @scalar/api-client
|
|
2
2
|
|
|
3
|
+
## 2.2.6
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- b744324: style: removes add item hotkey style
|
|
8
|
+
- 0804d6b: feat: fall back to just the request path in the sidebar
|
|
9
|
+
- 0076308: feat: show API client button in GitBook
|
|
10
|
+
- 13432e7: feat: fall back to the API reference URL for the import
|
|
11
|
+
- Updated dependencies [9b4f85d]
|
|
12
|
+
- @scalar/oas-utils@0.2.84
|
|
13
|
+
- @scalar/import@0.2.2
|
|
14
|
+
|
|
15
|
+
## 2.2.5
|
|
16
|
+
|
|
17
|
+
### Patch Changes
|
|
18
|
+
|
|
19
|
+
- e199e9b: feat: updates chevron down icon
|
|
20
|
+
- f524411: feat: adds response status color
|
|
21
|
+
- e199e9b: feat: updates add icon
|
|
22
|
+
- 10c01b2: fix: updates overflow and height for image response preview
|
|
23
|
+
- e199e9b: feat: adds request creation from sidebar
|
|
24
|
+
- 31cb86b: style: updates http method variants
|
|
25
|
+
- c2f5f08: feat: adds hideClientButton option configuration
|
|
26
|
+
- 1f730c6: feat: upgraded cva and added tests
|
|
27
|
+
- 8958af0: feat: add the proxy to oauth authorize calls
|
|
28
|
+
- Updated dependencies [e199e9b]
|
|
29
|
+
- Updated dependencies [e199e9b]
|
|
30
|
+
- Updated dependencies [f524411]
|
|
31
|
+
- Updated dependencies [e199e9b]
|
|
32
|
+
- Updated dependencies [d6e7008]
|
|
33
|
+
- Updated dependencies [10c9016]
|
|
34
|
+
- Updated dependencies [c2f5f08]
|
|
35
|
+
- Updated dependencies [1f730c6]
|
|
36
|
+
- Updated dependencies [b11294c]
|
|
37
|
+
- Updated dependencies [f30ce11]
|
|
38
|
+
- @scalar/components@0.13.1
|
|
39
|
+
- @scalar/oas-utils@0.2.83
|
|
40
|
+
- @scalar/use-codemirror@0.11.45
|
|
41
|
+
- @scalar/types@0.0.23
|
|
42
|
+
- @scalar/import@0.2.1
|
|
43
|
+
- @scalar/themes@0.9.54
|
|
44
|
+
- @scalar/use-hooks@0.1.7
|
|
45
|
+
|
|
46
|
+
## 2.2.4
|
|
47
|
+
|
|
48
|
+
### Patch Changes
|
|
49
|
+
|
|
50
|
+
- d08a7ae: feat(components): cleanup and extend floating components
|
|
51
|
+
- baaad1c: refactor: deprecated the `proxy` configuration attribute, and use `proxyUrl` everywhere
|
|
52
|
+
- 642d112: feat: adds request body example selector
|
|
53
|
+
- bae9997: refactor: move send-request lib to its own folder
|
|
54
|
+
- Updated dependencies [2dd6aa3]
|
|
55
|
+
- Updated dependencies [6389557]
|
|
56
|
+
- Updated dependencies [6389557]
|
|
57
|
+
- Updated dependencies [7605d6f]
|
|
58
|
+
- Updated dependencies [d08a7ae]
|
|
59
|
+
- Updated dependencies [baaad1c]
|
|
60
|
+
- Updated dependencies [c984ac8]
|
|
61
|
+
- Updated dependencies [7278742]
|
|
62
|
+
- Updated dependencies [3ca88dc]
|
|
63
|
+
- Updated dependencies [f6cd5ed]
|
|
64
|
+
- @scalar/components@0.13.0
|
|
65
|
+
- @scalar/import@0.2.0
|
|
66
|
+
- @scalar/oas-utils@0.2.82
|
|
67
|
+
- @scalar/types@0.0.22
|
|
68
|
+
- @scalar/use-codemirror@0.11.44
|
|
69
|
+
- @scalar/themes@0.9.53
|
|
70
|
+
- @scalar/use-hooks@0.1.6
|
|
71
|
+
|
|
3
72
|
## 2.2.3
|
|
4
73
|
|
|
5
74
|
### Patch Changes
|
|
@@ -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":";AAoWA,wBAKG"}
|
|
@@ -6,44 +6,44 @@ import { useWorkspace as T } from "../../store/store.js";
|
|
|
6
6
|
const j = {
|
|
7
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",
|
|
8
8
|
type: "button"
|
|
9
|
-
},
|
|
9
|
+
}, z = {
|
|
10
10
|
key: 0,
|
|
11
11
|
class: "text-xxs text-c-2 ml-8"
|
|
12
|
-
},
|
|
12
|
+
}, F = { class: "flex items-center justify-center h-4 w-4" }, M = {
|
|
13
13
|
key: 1,
|
|
14
14
|
class: "flex whitespace-nowrap items-center font-code lg:text-sm text-xs"
|
|
15
15
|
}, K = /* @__PURE__ */ V({
|
|
16
16
|
__name: "AddressBarServer",
|
|
17
|
-
setup(
|
|
18
|
-
const { activeRequest: y, activeCollection:
|
|
17
|
+
setup(P) {
|
|
18
|
+
const { activeRequest: y, activeCollection: k, activeServer: x } = R(), { isReadOnly: D, servers: _, collectionMutators: N, events: B } = T(), c = u(
|
|
19
19
|
() => {
|
|
20
20
|
var t, e;
|
|
21
21
|
return (e = (t = y.value) == null ? void 0 : t.servers) == null ? void 0 : e.map((r) => {
|
|
22
22
|
var s;
|
|
23
23
|
return {
|
|
24
24
|
id: r,
|
|
25
|
-
label: ((s =
|
|
25
|
+
label: ((s = _[r]) == null ? void 0 : s.url) ?? "Unknown server"
|
|
26
26
|
};
|
|
27
27
|
});
|
|
28
28
|
}
|
|
29
29
|
), d = u(
|
|
30
30
|
() => {
|
|
31
31
|
var t, e;
|
|
32
|
-
return (e = (t =
|
|
32
|
+
return (e = (t = k.value) == null ? void 0 : t.servers) == null ? void 0 : e.map((r) => {
|
|
33
33
|
var s;
|
|
34
34
|
return {
|
|
35
35
|
id: r,
|
|
36
|
-
label: ((s =
|
|
36
|
+
label: ((s = _[r]) == null ? void 0 : s.url) ?? "Unknown server"
|
|
37
37
|
};
|
|
38
38
|
});
|
|
39
39
|
}
|
|
40
|
-
),
|
|
40
|
+
), h = u(
|
|
41
41
|
() => {
|
|
42
42
|
var t, e;
|
|
43
43
|
return ((t = c.value) == null ? void 0 : t.length) && ((e = d.value) == null ? void 0 : e.length);
|
|
44
44
|
}
|
|
45
45
|
);
|
|
46
|
-
E([
|
|
46
|
+
E([k, y], ([t, e]) => {
|
|
47
47
|
!t || t.selectedServerUid || e != null && e.selectedServerUid || N.edit(
|
|
48
48
|
t.uid,
|
|
49
49
|
"selectedServerUid",
|
|
@@ -64,13 +64,13 @@ const j = {
|
|
|
64
64
|
teleport: ".scalar-client"
|
|
65
65
|
}, {
|
|
66
66
|
items: w(() => [
|
|
67
|
-
|
|
67
|
+
h.value ? (l(), o("div", z, " Request Servers ")) : v("", !0),
|
|
68
68
|
(l(!0), o(m, null, g(c.value, (i) => (l(), S(C, {
|
|
69
69
|
key: i.id,
|
|
70
70
|
serverOption: i,
|
|
71
71
|
type: "request"
|
|
72
72
|
}, null, 8, ["serverOption"]))), 128)),
|
|
73
|
-
|
|
73
|
+
h.value ? (l(), o(m, { key: 1 }, [
|
|
74
74
|
p(n(A)),
|
|
75
75
|
e[1] || (e[1] = a("div", { class: "text-xxs text-c-2 ml-8" }, "Collection Servers", -1))
|
|
76
76
|
], 64)) : v("", !0),
|
|
@@ -87,10 +87,10 @@ const j = {
|
|
|
87
87
|
class: "font-code text-xxs flex items-center gap-1.5",
|
|
88
88
|
onClick: U
|
|
89
89
|
}, [
|
|
90
|
-
a("div",
|
|
90
|
+
a("div", F, [
|
|
91
91
|
p(n(L), {
|
|
92
|
-
|
|
93
|
-
|
|
92
|
+
icon: "Add",
|
|
93
|
+
size: "sm"
|
|
94
94
|
})
|
|
95
95
|
]),
|
|
96
96
|
e[2] || (e[2] = a("span", null, "Add Server", -1))
|
|
@@ -107,7 +107,7 @@ const j = {
|
|
|
107
107
|
])
|
|
108
108
|
]),
|
|
109
109
|
_: 1
|
|
110
|
-
})) : f.value ? (l(), o("div",
|
|
110
|
+
})) : f.value ? (l(), o("div", M, b(f.value), 1)) : v("", !0);
|
|
111
111
|
};
|
|
112
112
|
}
|
|
113
113
|
});
|
|
@@ -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":"AA4MA,KAAK,WAAW,GAAG;IACjB,QAAQ,CAAC,EAAE;QACT,OAAO,EAAE,MAAM,CAAA;QACf,SAAS,EAAE,MAAM,CAAA;KAClB,CAAA;CACF,CAAC;;;;;;;;AA4TF,wBAQG"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { defineComponent as P, ref as c, computed as x, openBlock as
|
|
1
|
+
import { defineComponent as P, 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 W, createTextVNode as j } from "vue";
|
|
2
2
|
import H from "../HttpMethod/HttpMethod.vue.js";
|
|
3
3
|
import { useActiveEntities as I } from "../../store/active-entities.js";
|
|
4
|
-
import { ScalarListbox as
|
|
4
|
+
import { ScalarListbox as w, ScalarButton as D, ScalarIcon as k } from "@scalar/components";
|
|
5
5
|
import { useToasts as $ } from "@scalar/use-toasts";
|
|
6
6
|
import { useRouter as A } from "vue-router";
|
|
7
7
|
import L from "./CommandActionForm.vue.js";
|
|
8
8
|
import O from "./CommandActionInput.vue.js";
|
|
9
9
|
import { isHTTPMethod as F } from "../HttpMethod/helpers.js";
|
|
10
10
|
import { useWorkspace as G } from "../../store/store.js";
|
|
11
|
-
const J = { class: "flex
|
|
11
|
+
const J = { class: "flex" }, se = /* @__PURE__ */ P({
|
|
12
12
|
__name: "CommandPaletteRequest",
|
|
13
13
|
props: {
|
|
14
14
|
metaData: {}
|
|
@@ -20,7 +20,7 @@ const J = { class: "flex gap-2" }, se = /* @__PURE__ */ P({
|
|
|
20
20
|
activeWorkspace: U,
|
|
21
21
|
activeWorkspaceCollections: g,
|
|
22
22
|
activeRequest: T
|
|
23
|
-
} = I(), { requestMutators: y, tags: z } = G(), o = c(""),
|
|
23
|
+
} = I(), { requestMutators: y, tags: z } = G(), o = c(""), m = c("get"), p = x(
|
|
24
24
|
() => g.value.map((t) => {
|
|
25
25
|
var e;
|
|
26
26
|
return {
|
|
@@ -28,7 +28,7 @@ const J = { class: "flex gap-2" }, se = /* @__PURE__ */ P({
|
|
|
28
28
|
label: ((e = t.info) == null ? void 0 : e.title) ?? "Unititled Collection"
|
|
29
29
|
};
|
|
30
30
|
})
|
|
31
|
-
),
|
|
31
|
+
), d = x(
|
|
32
32
|
() => g.value.flatMap(
|
|
33
33
|
(t) => {
|
|
34
34
|
var e;
|
|
@@ -56,25 +56,25 @@ const J = { class: "flex gap-2" }, se = /* @__PURE__ */ P({
|
|
|
56
56
|
}
|
|
57
57
|
)
|
|
58
58
|
), s = c(
|
|
59
|
-
r.metaData ?
|
|
59
|
+
r.metaData ? d.value.find((t) => {
|
|
60
60
|
var e;
|
|
61
61
|
return t.id === ((e = r.metaData) == null ? void 0 : e.itemUid);
|
|
62
|
-
}) :
|
|
62
|
+
}) : d.value.find((t) => {
|
|
63
63
|
var e, a;
|
|
64
64
|
return t.label === ((a = (e = T.value) == null ? void 0 : e.tags) == null ? void 0 : a[0]);
|
|
65
65
|
})
|
|
66
|
-
), B = (t) =>
|
|
66
|
+
), B = (t) => m.value = t, E = () => {
|
|
67
67
|
var e;
|
|
68
68
|
if (!o.value.trim()) {
|
|
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) || !F(
|
|
72
|
+
if (!((e = l.value) != null && e.id) || !F(m.value))
|
|
73
73
|
return;
|
|
74
74
|
const t = y.add(
|
|
75
75
|
{
|
|
76
76
|
path: "",
|
|
77
|
-
method:
|
|
77
|
+
method: m.value,
|
|
78
78
|
description: o.value,
|
|
79
79
|
operationId: o.value,
|
|
80
80
|
summary: o.value,
|
|
@@ -90,7 +90,7 @@ const J = { class: "flex gap-2" }, se = /* @__PURE__ */ P({
|
|
|
90
90
|
}
|
|
91
91
|
}), b("close");
|
|
92
92
|
};
|
|
93
|
-
return (t, e) => (
|
|
93
|
+
return (t, e) => (h(), C(L, {
|
|
94
94
|
disabled: !o.value.trim(),
|
|
95
95
|
onSubmit: E
|
|
96
96
|
}, {
|
|
@@ -99,27 +99,27 @@ const J = { class: "flex gap-2" }, se = /* @__PURE__ */ P({
|
|
|
99
99
|
i(H, {
|
|
100
100
|
isEditable: !0,
|
|
101
101
|
isSquare: "",
|
|
102
|
-
method:
|
|
102
|
+
method: m.value,
|
|
103
103
|
onChange: B
|
|
104
104
|
}, null, 8, ["method"]),
|
|
105
|
-
i(n(
|
|
105
|
+
i(n(w), {
|
|
106
106
|
modelValue: l.value,
|
|
107
107
|
"onUpdate:modelValue": e[2] || (e[2] = (a) => l.value = a),
|
|
108
108
|
options: p.value
|
|
109
109
|
}, {
|
|
110
110
|
default: u(() => [
|
|
111
|
-
i(n(
|
|
112
|
-
class: "justify-between p-2 max-h-8 w-full gap-1 text-xs hover:bg-b-2",
|
|
111
|
+
i(n(D), {
|
|
112
|
+
class: "justify-between p-2 ml-2 max-h-8 w-full gap-1 text-xs hover:bg-b-2",
|
|
113
113
|
variant: "outlined"
|
|
114
114
|
}, {
|
|
115
115
|
default: u(() => [
|
|
116
116
|
f("span", {
|
|
117
|
-
class: q(l.value ? "text-c-1" : "text-c-3")
|
|
117
|
+
class: q(["whitespace-nowrap", l.value ? "text-c-1" : "text-c-3"])
|
|
118
118
|
}, V(l.value ? l.value.label : "Select Collection"), 3),
|
|
119
|
-
i(n(
|
|
119
|
+
i(n(k), {
|
|
120
120
|
class: "text-c-3",
|
|
121
121
|
icon: "ChevronDown",
|
|
122
|
-
size: "
|
|
122
|
+
size: "md"
|
|
123
123
|
})
|
|
124
124
|
]),
|
|
125
125
|
_: 1
|
|
@@ -127,25 +127,25 @@ const J = { class: "flex gap-2" }, se = /* @__PURE__ */ P({
|
|
|
127
127
|
]),
|
|
128
128
|
_: 1
|
|
129
129
|
}, 8, ["modelValue", "options"]),
|
|
130
|
-
|
|
130
|
+
d.value.length ? (h(), C(n(w), {
|
|
131
131
|
key: 0,
|
|
132
132
|
modelValue: s.value,
|
|
133
133
|
"onUpdate:modelValue": e[3] || (e[3] = (a) => s.value = a),
|
|
134
|
-
options:
|
|
134
|
+
options: d.value
|
|
135
135
|
}, {
|
|
136
136
|
default: u(() => [
|
|
137
|
-
i(n(
|
|
138
|
-
class: "justify-between p-2 max-h-8 w-full gap-1 text-xs hover:bg-b-2",
|
|
137
|
+
i(n(D), {
|
|
138
|
+
class: "justify-between p-2 ml-2 max-h-8 w-full gap-1 text-xs hover:bg-b-2",
|
|
139
139
|
variant: "outlined"
|
|
140
140
|
}, {
|
|
141
141
|
default: u(() => [
|
|
142
142
|
f("span", {
|
|
143
143
|
class: q(s.value ? "text-c-1" : "text-c-3")
|
|
144
144
|
}, V(s.value ? s.value.label : "Select Tag"), 3),
|
|
145
|
-
i(n(
|
|
145
|
+
i(n(k), {
|
|
146
146
|
class: "text-c-3",
|
|
147
147
|
icon: "ChevronDown",
|
|
148
|
-
size: "
|
|
148
|
+
size: "md"
|
|
149
149
|
})
|
|
150
150
|
]),
|
|
151
151
|
_: 1
|
|
@@ -55,7 +55,7 @@ const q = /* @__PURE__ */ w({
|
|
|
55
55
|
default: a(() => [
|
|
56
56
|
n.value.length > 0 ? (s(), u(i(p), {
|
|
57
57
|
key: 0,
|
|
58
|
-
class: "justify-between p-2 max-h-8 w-
|
|
58
|
+
class: "justify-between p-2 max-h-8 w-fit gap-1 text-xs hover:bg-b-2",
|
|
59
59
|
variant: "outlined"
|
|
60
60
|
}, {
|
|
61
61
|
default: a(() => [
|
|
@@ -65,7 +65,7 @@ const q = /* @__PURE__ */ w({
|
|
|
65
65
|
c(i(L), {
|
|
66
66
|
class: "text-c-3",
|
|
67
67
|
icon: "ChevronDown",
|
|
68
|
-
size: "
|
|
68
|
+
size: "md"
|
|
69
69
|
})
|
|
70
70
|
]),
|
|
71
71
|
_: 1
|
|
@@ -8,9 +8,9 @@ import { useWorkspace as P } from "../../store/store.js";
|
|
|
8
8
|
const O = /* @__PURE__ */ g({
|
|
9
9
|
__name: "CommandPaletteTag",
|
|
10
10
|
emits: ["close", "back"],
|
|
11
|
-
setup(U, { emit:
|
|
12
|
-
const r =
|
|
13
|
-
() =>
|
|
11
|
+
setup(U, { emit: d }) {
|
|
12
|
+
const r = d, { activeWorkspaceCollections: c, activeCollection: p } = N(), { tagMutators: f } = P(), { toast: v } = y(), u = x(
|
|
13
|
+
() => c.value.map((o) => {
|
|
14
14
|
var e;
|
|
15
15
|
return {
|
|
16
16
|
id: o.uid,
|
|
@@ -49,7 +49,7 @@ const O = /* @__PURE__ */ g({
|
|
|
49
49
|
}, {
|
|
50
50
|
default: n(() => [
|
|
51
51
|
i(s(B), {
|
|
52
|
-
class: "justify-between p-2 max-h-8 w-
|
|
52
|
+
class: "justify-between p-2 max-h-8 w-fit gap-1 text-xs hover:bg-b-2",
|
|
53
53
|
variant: "outlined"
|
|
54
54
|
}, {
|
|
55
55
|
default: n(() => [
|
|
@@ -59,7 +59,7 @@ const O = /* @__PURE__ */ g({
|
|
|
59
59
|
i(s(D), {
|
|
60
60
|
class: "text-c-3",
|
|
61
61
|
icon: "ChevronDown",
|
|
62
|
-
size: "
|
|
62
|
+
size: "md"
|
|
63
63
|
})
|
|
64
64
|
]),
|
|
65
65
|
_: 1
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTableCheckbox.vue.d.ts","sourceRoot":"","sources":["../../../src/components/DataTable/DataTableCheckbox.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DataTableCheckbox.vue.d.ts","sourceRoot":"","sources":["../../../src/components/DataTable/DataTableCheckbox.vue"],"names":[],"mappings":"AAwDA,KAAK,WAAW,GAAG;IACf,UAAU,EAAE,OAAO,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ,CAAA;CAC1B,CAAC;;;;;;WADQ,MAAM,GAAG,QAAQ;;AAsH7B,wBASG"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { defineComponent as s, openBlock as n, createBlock as i, withCtx as c, createElementVNode as o, normalizeClass as d, unref as a, createVNode as p } from "vue";
|
|
2
|
-
import {
|
|
3
|
-
import { cva as m } from "cva";
|
|
2
|
+
import { cva as u, ScalarIcon as m } from "@scalar/components";
|
|
4
3
|
import f from "./DataTableCell.vue.js";
|
|
5
|
-
const b = ["checked", "disabled"],
|
|
4
|
+
const b = ["checked", "disabled"], y = /* @__PURE__ */ s({
|
|
6
5
|
__name: "DataTableCheckbox",
|
|
7
6
|
props: {
|
|
8
7
|
modelValue: { type: Boolean },
|
|
@@ -11,7 +10,7 @@ const b = ["checked", "disabled"], x = /* @__PURE__ */ s({
|
|
|
11
10
|
},
|
|
12
11
|
emits: ["update:modelValue"],
|
|
13
12
|
setup(h) {
|
|
14
|
-
const l =
|
|
13
|
+
const l = u({
|
|
15
14
|
base: "w-8 h-8 flex items-center justify-center text-border peer-checked:text-c-2 pointer-events-none absolute",
|
|
16
15
|
variants: {
|
|
17
16
|
align: {
|
|
@@ -33,7 +32,7 @@ const b = ["checked", "disabled"], x = /* @__PURE__ */ s({
|
|
|
33
32
|
class: d(a(l)({ align: e.align }))
|
|
34
33
|
}, [
|
|
35
34
|
t[1] || (t[1] = o("div", { class: "absolute opacity-0 group-hover/cell:opacity-100 group-has-[:focus-visible]/cell:opacity-100 group-has-[:focus-visible]/cell:border-c-accent border-[1px] rounded size-3/4 m-auto" }, null, -1)),
|
|
36
|
-
p(a(
|
|
35
|
+
p(a(m), {
|
|
37
36
|
icon: "Checkmark",
|
|
38
37
|
size: "xs",
|
|
39
38
|
thickness: "2.5"
|
|
@@ -45,5 +44,5 @@ const b = ["checked", "disabled"], x = /* @__PURE__ */ s({
|
|
|
45
44
|
}
|
|
46
45
|
});
|
|
47
46
|
export {
|
|
48
|
-
|
|
47
|
+
y as default
|
|
49
48
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataTableInputSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/DataTable/DataTableInputSelect.vue"],"names":[],"mappings":"AAmJA,KAAK,WAAW,GAAG;IACf,UAAU,EAAE,MAAM,GAAG,MAAM,CAAA;IAC3B,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACzB,iBAAiB,CAAC,EAAE,OAAO,CAAA;CAC5B,CAAC;;;;;;uBADoB,OAAO;;
|
|
1
|
+
{"version":3,"file":"DataTableInputSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/DataTable/DataTableInputSelect.vue"],"names":[],"mappings":"AAmJA,KAAK,WAAW,GAAG;IACf,UAAU,EAAE,MAAM,GAAG,MAAM,CAAA;IAC3B,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACzB,iBAAiB,CAAC,EAAE,OAAO,CAAA;CAC5B,CAAC;;;;;;uBADoB,OAAO;;AAmR/B,wBASG"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as A, computed as
|
|
1
|
+
import { defineComponent as A, computed as w, ref as p, watch as h, nextTick as N, openBlock as n, createElementBlock as i, withDirectives as T, withKeys as j, vModelText as I, createBlock as k, unref as a, withCtx as d, Fragment as y, renderList as E, createElementVNode as c, normalizeClass as K, createVNode as o, createTextVNode as R, toDisplayString as C, createCommentVNode as $ } from "vue";
|
|
2
2
|
import { ScalarDropdown as F, ScalarDropdownItem as g, ScalarIcon as f, ScalarDropdownDivider as L, ScalarButton as M } from "@scalar/components";
|
|
3
3
|
const U = { class: "w-full" }, W = { class: "text-c-1" }, q = { class: "flex items-center justify-center h-4 w-4" }, O = /* @__PURE__ */ A({
|
|
4
4
|
__name: "DataTableInputSelect",
|
|
@@ -10,8 +10,8 @@ const U = { class: "w-full" }, W = { class: "text-c-1" }, q = { class: "flex ite
|
|
|
10
10
|
},
|
|
11
11
|
emits: ["update:modelValue"],
|
|
12
12
|
setup(S, { emit: _ }) {
|
|
13
|
-
const s = S, m = _, D =
|
|
14
|
-
|
|
13
|
+
const s = S, m = _, D = w(() => s.value ?? []), r = p(!1), u = p(""), v = p(null);
|
|
14
|
+
h(u, (e) => {
|
|
15
15
|
m("update:modelValue", e);
|
|
16
16
|
});
|
|
17
17
|
const V = (e) => {
|
|
@@ -21,13 +21,13 @@ const U = { class: "w-full" }, W = { class: "text-c-1" }, q = { class: "flex ite
|
|
|
21
21
|
}, b = () => {
|
|
22
22
|
u.value.trim() || (m("update:modelValue", ""), r.value = !1);
|
|
23
23
|
}, z = (e) => s.modelValue.toString() === e;
|
|
24
|
-
|
|
24
|
+
h(r, (e) => {
|
|
25
25
|
e && N(() => {
|
|
26
26
|
var t;
|
|
27
27
|
(t = v.value) == null || t.focus();
|
|
28
28
|
});
|
|
29
29
|
});
|
|
30
|
-
const x =
|
|
30
|
+
const x = w(() => s.modelValue !== void 0 ? s.modelValue : s.default);
|
|
31
31
|
return (e, t) => (n(), i("div", U, [
|
|
32
32
|
r.value ? T((n(), i("input", {
|
|
33
33
|
key: 0,
|
|
@@ -79,8 +79,8 @@ const U = { class: "w-full" }, W = { class: "text-c-1" }, q = { class: "flex ite
|
|
|
79
79
|
default: d(() => [
|
|
80
80
|
c("div", q, [
|
|
81
81
|
o(a(f), {
|
|
82
|
-
|
|
83
|
-
|
|
82
|
+
icon: "Add",
|
|
83
|
+
size: "sm"
|
|
84
84
|
})
|
|
85
85
|
]),
|
|
86
86
|
t[2] || (t[2] = c("span", null, "Add value", -1))
|
|
@@ -99,7 +99,7 @@ const U = { class: "w-full" }, W = { class: "text-c-1" }, q = { class: "flex ite
|
|
|
99
99
|
c("span", W, C(x.value || "Select a value"), 1),
|
|
100
100
|
o(a(f), {
|
|
101
101
|
icon: "ChevronDown",
|
|
102
|
-
size: "
|
|
102
|
+
size: "md"
|
|
103
103
|
})
|
|
104
104
|
]),
|
|
105
105
|
_: 1
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EnvironmentSelector.vue.d.ts","sourceRoot":"","sources":["../../../src/components/EnvironmentSelector/EnvironmentSelector.vue"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"EnvironmentSelector.vue.d.ts","sourceRoot":"","sources":["../../../src/components/EnvironmentSelector/EnvironmentSelector.vue"],"names":[],"mappings":";AAqXA,wBAMG"}
|
|
@@ -1,89 +1,80 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useActiveEntities as
|
|
3
|
-
import { ScalarDropdown as
|
|
4
|
-
import { useRouter as
|
|
5
|
-
import { useWorkspace as
|
|
6
|
-
const O = { class: "font-medium m-0 flex gap-1.5 items-center whitespace-nowrap" }, R = { class: "flex items-center justify-center h-4 w-4" },
|
|
1
|
+
import { defineComponent as b, computed as S, openBlock as a, createElementBlock as f, createVNode as n, unref as e, withCtx as r, Fragment as y, renderList as N, createBlock as v, withModifiers as w, createTextVNode as c, toDisplayString as x, createElementVNode as l, normalizeClass as D, createCommentVNode as B } from "vue";
|
|
2
|
+
import { useActiveEntities as I } from "../../store/active-entities.js";
|
|
3
|
+
import { ScalarDropdown as j, ScalarDropdownItem as m, ScalarListboxCheckbox as z, ScalarIcon as d, ScalarDropdownDivider as V, ScalarButton as M } from "@scalar/components";
|
|
4
|
+
import { useRouter as W } from "vue-router";
|
|
5
|
+
import { useWorkspace as L } from "../../store/store.js";
|
|
6
|
+
const O = { class: "font-medium m-0 flex gap-1.5 items-center whitespace-nowrap" }, R = { class: "flex items-center justify-center h-4 w-4" }, J = /* @__PURE__ */ b({
|
|
7
7
|
__name: "EnvironmentSelector",
|
|
8
8
|
setup($) {
|
|
9
|
-
const { activeWorkspace: i, activeEnvironment:
|
|
10
|
-
|
|
11
|
-
},
|
|
9
|
+
const { activeWorkspace: i, activeEnvironment: h } = I(), { environments: u, workspaceMutators: k, isReadOnly: g } = L(), E = W(), p = (s) => {
|
|
10
|
+
k.edit(i.value.uid, "activeEnvironmentId", s);
|
|
11
|
+
}, C = () => E.push({
|
|
12
12
|
name: "environment",
|
|
13
13
|
params: {
|
|
14
14
|
environment: i.value.uid
|
|
15
15
|
}
|
|
16
|
-
}),
|
|
16
|
+
}), _ = S(() => [
|
|
17
17
|
// Always add the default environment
|
|
18
18
|
u.default,
|
|
19
|
-
...Object.values(u).filter((
|
|
19
|
+
...Object.values(u).filter((s) => s.uid !== "default")
|
|
20
20
|
]);
|
|
21
|
-
return (
|
|
22
|
-
n(e(
|
|
21
|
+
return (s, o) => (a(), f("div", null, [
|
|
22
|
+
n(e(j), { placement: "bottom-end" }, {
|
|
23
23
|
items: r(() => [
|
|
24
|
-
(
|
|
24
|
+
(a(!0), f(y, null, N(_.value, (t) => (a(), v(e(m), {
|
|
25
25
|
key: t.uid,
|
|
26
26
|
class: "flex gap-1.5 group/item items-center whitespace-nowrap text-ellipsis overflow-hidden",
|
|
27
|
-
onClick:
|
|
27
|
+
onClick: w((A) => p(t.uid), ["stop"])
|
|
28
28
|
}, {
|
|
29
29
|
default: r(() => [
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
])
|
|
35
|
-
}, [
|
|
36
|
-
n(e(l), {
|
|
37
|
-
class: "size-2.5",
|
|
38
|
-
icon: "Checkmark",
|
|
39
|
-
thickness: "3.5"
|
|
40
|
-
})
|
|
41
|
-
], 2),
|
|
42
|
-
m(" " + x(t.name), 1)
|
|
30
|
+
n(e(z), {
|
|
31
|
+
selected: e(i).activeEnvironmentId === t.uid
|
|
32
|
+
}, null, 8, ["selected"]),
|
|
33
|
+
c(" " + x(t.name), 1)
|
|
43
34
|
]),
|
|
44
35
|
_: 2
|
|
45
36
|
}, 1032, ["onClick"]))), 128)),
|
|
46
|
-
n(e(
|
|
37
|
+
n(e(m), {
|
|
47
38
|
class: "flex gap-1.5 group/item items-center whitespace-nowrap text-ellipsis overflow-hidden",
|
|
48
|
-
onClick: o[0] || (o[0] =
|
|
39
|
+
onClick: o[0] || (o[0] = w((t) => p(""), ["stop"]))
|
|
49
40
|
}, {
|
|
50
41
|
default: r(() => [
|
|
51
|
-
|
|
52
|
-
class:
|
|
42
|
+
l("div", {
|
|
43
|
+
class: D([
|
|
53
44
|
"flex items-center justify-center rounded-full p-[3px] w-4 h-4",
|
|
54
45
|
e(i).activeEnvironmentId === "" ? "bg-c-accent text-b-1" : "group-hover/item:shadow-border text-transparent"
|
|
55
46
|
])
|
|
56
47
|
}, [
|
|
57
|
-
n(e(
|
|
48
|
+
n(e(d), {
|
|
58
49
|
class: "size-2.5",
|
|
59
50
|
icon: "Checkmark",
|
|
60
51
|
thickness: "3.5"
|
|
61
52
|
})
|
|
62
53
|
], 2),
|
|
63
|
-
o[1] || (o[1] =
|
|
54
|
+
o[1] || (o[1] = c(" No Environment "))
|
|
64
55
|
]),
|
|
65
56
|
_: 1
|
|
66
57
|
}),
|
|
67
|
-
n(e(
|
|
68
|
-
e(
|
|
58
|
+
n(e(V)),
|
|
59
|
+
e(g) ? B("", !0) : (a(), v(e(m), {
|
|
69
60
|
key: 0,
|
|
70
61
|
class: "flex items-center gap-1.5",
|
|
71
|
-
onClick:
|
|
62
|
+
onClick: C
|
|
72
63
|
}, {
|
|
73
64
|
default: r(() => [
|
|
74
|
-
|
|
75
|
-
n(e(
|
|
65
|
+
l("div", R, [
|
|
66
|
+
n(e(d), {
|
|
76
67
|
icon: "Brackets",
|
|
77
68
|
size: "sm"
|
|
78
69
|
})
|
|
79
70
|
]),
|
|
80
|
-
o[2] || (o[2] =
|
|
71
|
+
o[2] || (o[2] = l("span", { class: "leading-none" }, "Manage Environments", -1))
|
|
81
72
|
]),
|
|
82
73
|
_: 1
|
|
83
74
|
}))
|
|
84
75
|
]),
|
|
85
76
|
default: r(() => [
|
|
86
|
-
n(e(
|
|
77
|
+
n(e(M), {
|
|
87
78
|
class: "font-normal h-auto justify-start py-1.5 px-1.5 pl-2 text-c-1 hover:bg-b-2 text-c-1 w-fit",
|
|
88
79
|
fullWidth: "",
|
|
89
80
|
variant: "ghost"
|
|
@@ -91,12 +82,11 @@ const O = { class: "font-medium m-0 flex gap-1.5 items-center whitespace-nowrap"
|
|
|
91
82
|
default: r(() => {
|
|
92
83
|
var t;
|
|
93
84
|
return [
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
n(e(
|
|
97
|
-
class: "size-3",
|
|
85
|
+
l("h2", O, [
|
|
86
|
+
c(x(((t = e(h)) == null ? void 0 : t.name) ?? "No Environment") + " ", 1),
|
|
87
|
+
n(e(d), {
|
|
98
88
|
icon: "ChevronDown",
|
|
99
|
-
|
|
89
|
+
size: "md"
|
|
100
90
|
})
|
|
101
91
|
])
|
|
102
92
|
];
|
|
@@ -110,5 +100,5 @@ const O = { class: "font-medium m-0 flex gap-1.5 items-center whitespace-nowrap"
|
|
|
110
100
|
}
|
|
111
101
|
});
|
|
112
102
|
export {
|
|
113
|
-
|
|
103
|
+
J as default
|
|
114
104
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HttpMethod.vue.d.ts","sourceRoot":"","sources":["../../../src/components/HttpMethod/HttpMethod.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"HttpMethod.vue.d.ts","sourceRoot":"","sources":["../../../src/components/HttpMethod/HttpMethod.vue"],"names":[],"mappings":"AAgGA,KAAK,WAAW,GAAG;IACf,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,EAAE,MAAM,CAAA;IACd,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB,CAAC;;;;;;cAHW,OAAO;gBAEL,OAAO;;AAwIxB,wBAQG"}
|