@scalar/api-client 2.2.7 → 2.2.9
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 +27 -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 +65 -65
- package/dist/components/CodeInput/codeVariableWidget.d.ts +6 -4
- package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
- package/dist/components/CodeInput/codeVariableWidget.js +72 -68
- package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPaletteImport.vue.js +108 -106
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue.js +2 -2
- package/dist/components/CommandPalette/TheCommandPalette.vue2.js +12 -12
- package/dist/components/DataTable/DataTable.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTable.vue.js +20 -15
- package/dist/components/DataTable/DataTableCell.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableCell.vue.js +16 -11
- package/dist/components/DataTable/DataTableHeader.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableHeader.vue.js +11 -12
- package/dist/components/DataTable/DataTableInput.vue.d.ts +2 -1
- package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableInput.vue.js +3 -3
- package/dist/components/DataTable/DataTableInput.vue2.js +9 -9
- package/dist/components/DataTable/index.js +14 -14
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.d.ts.map +1 -1
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +87 -67
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +2 -2
- package/dist/components/Sidebar/SidebarList.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarList.vue.js +4 -4
- package/dist/components/Sidebar/SidebarListElement.vue.d.ts +8 -4
- package/dist/components/Sidebar/SidebarListElement.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarListElement.vue.js +1 -1
- package/dist/components/Sidebar/SidebarListElement.vue2.js +52 -32
- package/dist/components/Sidebar/SidebarListElementActions.vue.d.ts +3 -0
- package/dist/components/Sidebar/SidebarListElementActions.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarListElementActions.vue.js +43 -31
- package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
- package/dist/components/TopNav/TopNav.vue.js +32 -31
- package/dist/layouts/App/create-api-client-app.d.ts +49 -42
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.d.ts +103 -89
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.js +31 -19
- package/dist/layouts/Web/create-api-client-web.d.ts +49 -42
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/libs/create-client.d.ts +50 -44
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/env-helpers.d.ts +9 -0
- package/dist/libs/env-helpers.d.ts.map +1 -0
- package/dist/libs/env-helpers.js +4 -0
- package/dist/libs/environment-parser.d.ts +3 -4
- package/dist/libs/environment-parser.d.ts.map +1 -1
- package/dist/libs/environment-parser.js +5 -4
- package/dist/libs/index.d.ts +2 -0
- package/dist/libs/index.d.ts.map +1 -1
- package/dist/libs/index.js +28 -22
- package/dist/libs/postman.d.ts +11 -0
- package/dist/libs/postman.d.ts.map +1 -0
- package/dist/libs/postman.js +39 -0
- package/dist/libs/send-request/send-request.d.ts +5 -2
- package/dist/libs/send-request/send-request.d.ts.map +1 -1
- package/dist/libs/send-request/send-request.js +106 -104
- package/dist/routes.d.ts +11 -0
- package/dist/routes.d.ts.map +1 -1
- package/dist/routes.js +13 -7
- package/dist/store/active-entities.d.ts +18 -11
- package/dist/store/active-entities.d.ts.map +1 -1
- package/dist/store/active-entities.js +108 -69
- package/dist/store/collections.d.ts +17 -15
- package/dist/store/collections.d.ts.map +1 -1
- package/dist/store/collections.js +62 -41
- package/dist/store/environment.d.ts +4 -4
- package/dist/store/import-spec.d.ts +2 -2
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/index.d.ts +1 -0
- package/dist/store/index.d.ts.map +1 -1
- package/dist/store/index.js +7 -3
- package/dist/store/requests.d.ts +4 -4
- package/dist/store/router-params.d.ts +1 -1
- package/dist/store/router-params.d.ts.map +1 -1
- package/dist/store/router-params.js +7 -7
- package/dist/store/store.d.ts +49 -42
- package/dist/store/store.d.ts.map +1 -1
- package/dist/store/store.js +76 -72
- package/dist/store/workspace.d.ts +12 -12
- package/dist/store/workspace.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/index.d.ts +2 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +1 -0
- package/dist/types/vue.d.ts +10 -0
- package/dist/types/vue.d.ts.map +1 -0
- package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
- package/dist/views/Cookies/Cookies.vue2.js +75 -70
- package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
- package/dist/views/Environment/Environment.vue2.js +308 -152
- package/dist/views/Environment/EnvironmentColorModal.vue.d.ts.map +1 -1
- package/dist/views/Environment/EnvironmentColorModal.vue.js +20 -18
- package/dist/views/Environment/EnvironmentColors.vue.d.ts +4 -1
- package/dist/views/Environment/EnvironmentColors.vue.d.ts.map +1 -1
- package/dist/views/Environment/EnvironmentColors.vue.js +83 -58
- package/dist/views/Environment/EnvironmentModal.vue.d.ts +7 -0
- package/dist/views/Environment/EnvironmentModal.vue.d.ts.map +1 -1
- package/dist/views/Environment/EnvironmentModal.vue.js +119 -37
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts +4 -5
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +73 -63
- 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 +60 -61
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +185 -187
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.js +27 -24
- 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 +35 -187
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts +7 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts.map +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +7 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +207 -0
- package/dist/views/Request/RequestSection/{RequestAuthDataTableInput.vue.d.ts → RequestAuth/RequestAuthDataTableInput.vue.d.ts} +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts.map +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.js +43 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.js +5 -134
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue2.js +176 -2
- package/dist/views/Request/RequestSection/RequestAuth/index.d.ts +2 -0
- package/dist/views/Request/RequestSection/RequestAuth/index.d.ts.map +1 -0
- package/dist/views/Request/RequestSection/RequestAuth/index.js +4 -0
- 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 +139 -117
- 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 +32 -38
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
- package/dist/views/Request/libs/auth.d.ts.map +1 -1
- package/dist/views/Request/libs/auth.js +3 -3
- package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
- package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
- package/dist/views/Servers/Servers.vue2.js +9 -8
- package/package.json +19 -8
- package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts.map +0 -1
- package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.js +0 -46
- /package/dist/views/Request/RequestSection/{RequestAuthDataTableInput.vue2.js → RequestAuth/RequestAuthDataTableInput.vue2.js} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TopNav.vue.d.ts","sourceRoot":"","sources":["../../../src/components/TopNav/TopNav.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"TopNav.vue.d.ts","sourceRoot":"","sources":["../../../src/components/TopNav/TopNav.vue"],"names":[],"mappings":"AA2PA,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACjD,CAAC;;AA2aF,wBAOG"}
|
|
@@ -1,37 +1,38 @@
|
|
|
1
|
-
import { defineComponent as M, reactive as $, ref as z, computed as B, watch as w, onMounted as E, onBeforeUnmount as j, openBlock as m, createElementBlock as b, createElementVNode as f, createVNode as n, unref as l, withCtx as
|
|
1
|
+
import { defineComponent as M, reactive as $, ref as z, computed as B, watch as w, onMounted as E, onBeforeUnmount as j, openBlock as m, createElementBlock as b, createElementVNode as f, createVNode as n, unref as l, withCtx as s, toDisplayString as O, createTextVNode as x, Fragment as V, renderList as D, createBlock as K } from "vue";
|
|
2
2
|
import q from "../ScalarHotkey.vue.js";
|
|
3
3
|
import { ROUTES as F } from "../../constants.js";
|
|
4
4
|
import { useActiveEntities as H } from "../../store/active-entities.js";
|
|
5
5
|
import { ScalarContextMenu as W, ScalarIcon as d, ScalarFloating as G, ScalarDropdownMenu as J, ScalarDropdownButton as _ } from "@scalar/components";
|
|
6
6
|
import { capitalize as P } from "@scalar/oas-utils/helpers";
|
|
7
7
|
import { useClipboard as Q } from "@scalar/use-hooks/useClipboard";
|
|
8
|
-
import X from "
|
|
9
|
-
import
|
|
10
|
-
|
|
8
|
+
import { useRouter as X } from "vue-router";
|
|
9
|
+
import Y from "./TopNavItem.vue.js";
|
|
10
|
+
import { useWorkspace as Z } from "../../store/store.js";
|
|
11
|
+
const ee = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, te = { class: "flex h-10 flex-1 items-center gap-1.5 text-sm font-medium pr-2.5 relative overflow-hidden" }, oe = {
|
|
11
12
|
key: 0,
|
|
12
13
|
class: "h-full w-full overflow-hidden"
|
|
13
|
-
},
|
|
14
|
+
}, fe = /* @__PURE__ */ M({
|
|
14
15
|
__name: "TopNav",
|
|
15
16
|
props: {
|
|
16
17
|
openNewTab: {}
|
|
17
18
|
},
|
|
18
19
|
setup(I) {
|
|
19
|
-
const S = I, { activeRequest: L
|
|
20
|
+
const S = I, { activeRequest: L } = H(), i = X(), { events: g } = Z(), { copyToClipboard: R } = Q(), t = $([{ label: "", path: "", icon: "Add" }]), a = z(0), T = B(() => a.value);
|
|
20
21
|
function k() {
|
|
21
22
|
var o;
|
|
22
|
-
const e = F.find((u) =>
|
|
23
|
+
const e = F.find((u) => i.currentRoute.value.name == u.name);
|
|
23
24
|
e && ((e == null ? void 0 : e.name) === "request" ? t[a.value] = {
|
|
24
25
|
label: ((o = L.value) == null ? void 0 : o.summary) || "",
|
|
25
|
-
path:
|
|
26
|
+
path: i.currentRoute.value.path,
|
|
26
27
|
icon: e.icon
|
|
27
28
|
} : t[a.value] = {
|
|
28
29
|
label: P(e == null ? void 0 : e.name) || "",
|
|
29
|
-
path:
|
|
30
|
+
path: i.currentRoute.value.path,
|
|
30
31
|
icon: e.icon
|
|
31
32
|
});
|
|
32
33
|
}
|
|
33
34
|
function v() {
|
|
34
|
-
|
|
35
|
+
i.push(t[a.value].path);
|
|
35
36
|
}
|
|
36
37
|
function p() {
|
|
37
38
|
t.push({ label: "", path: "", icon: "Add" }), a.value = t.length - 1, k();
|
|
@@ -40,7 +41,7 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
40
41
|
a.value = e, v();
|
|
41
42
|
}
|
|
42
43
|
w(
|
|
43
|
-
() =>
|
|
44
|
+
() => i.currentRoute.value.path,
|
|
44
45
|
() => {
|
|
45
46
|
k();
|
|
46
47
|
},
|
|
@@ -54,8 +55,8 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
54
55
|
}
|
|
55
56
|
const y = (e) => {
|
|
56
57
|
const o = new URL(window.location.href);
|
|
57
|
-
o.pathname = t[e].path,
|
|
58
|
-
},
|
|
58
|
+
o.pathname = t[e].path, R(o.toString());
|
|
59
|
+
}, U = (e) => {
|
|
59
60
|
t.splice(0, e), t.splice(1), a.value = 0, v();
|
|
60
61
|
}, C = (e) => {
|
|
61
62
|
if (e) {
|
|
@@ -78,12 +79,12 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
78
79
|
e && A(e);
|
|
79
80
|
},
|
|
80
81
|
{ immediate: !0 }
|
|
81
|
-
), E(() => g.hotKeys.on(C)), j(() => g.hotKeys.off(C)), (e, o) => (m(), b("nav",
|
|
82
|
+
), E(() => g.hotKeys.on(C)), j(() => g.hotKeys.off(C)), (e, o) => (m(), b("nav", ee, [
|
|
82
83
|
o[3] || (o[3] = f("div", { class: "absolute inset-0 app-drag-region" }, null, -1)),
|
|
83
|
-
f("div",
|
|
84
|
-
t.length === 1 ? (m(), b("div",
|
|
84
|
+
f("div", te, [
|
|
85
|
+
t.length === 1 ? (m(), b("div", oe, [
|
|
85
86
|
n(l(W), { triggerClass: "flex custom-scroll gap-1.5 h-full items-center justify-center w-full whitespace-nowrap" }, {
|
|
86
|
-
trigger:
|
|
87
|
+
trigger: s(() => [
|
|
87
88
|
n(l(d), {
|
|
88
89
|
icon: t[0].icon,
|
|
89
90
|
size: "xs",
|
|
@@ -91,16 +92,16 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
91
92
|
}, null, 8, ["icon"]),
|
|
92
93
|
f("span", null, O(t[0].label), 1)
|
|
93
94
|
]),
|
|
94
|
-
content:
|
|
95
|
+
content: s(() => [
|
|
95
96
|
n(l(G), { placement: "right-start" }, {
|
|
96
|
-
floating:
|
|
97
|
+
floating: s(() => [
|
|
97
98
|
n(l(J), { class: "scalar-app scalar-client" }, {
|
|
98
|
-
default:
|
|
99
|
+
default: s(() => [
|
|
99
100
|
n(l(_), {
|
|
100
101
|
class: "flex items-center gap-1.5",
|
|
101
102
|
onClick: p
|
|
102
103
|
}, {
|
|
103
|
-
default:
|
|
104
|
+
default: s(() => [
|
|
104
105
|
n(l(d), {
|
|
105
106
|
icon: "AddTab",
|
|
106
107
|
size: "sm",
|
|
@@ -118,7 +119,7 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
118
119
|
class: "flex items-center gap-1.5",
|
|
119
120
|
onClick: o[0] || (o[0] = (u) => y(T.value))
|
|
120
121
|
}, {
|
|
121
|
-
default:
|
|
122
|
+
default: s(() => [
|
|
122
123
|
n(l(d), {
|
|
123
124
|
icon: "Link",
|
|
124
125
|
size: "sm",
|
|
@@ -137,16 +138,16 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
137
138
|
]),
|
|
138
139
|
_: 1
|
|
139
140
|
})
|
|
140
|
-
])) : (m(!0), b(V, { key: 1 }, D(t, (u,
|
|
141
|
-
key:
|
|
142
|
-
active:
|
|
143
|
-
hotkey: (
|
|
141
|
+
])) : (m(!0), b(V, { key: 1 }, D(t, (u, r) => (m(), K(Y, {
|
|
142
|
+
key: r,
|
|
143
|
+
active: r === T.value,
|
|
144
|
+
hotkey: (r + 1).toString(),
|
|
144
145
|
icon: u.icon,
|
|
145
146
|
label: u.label,
|
|
146
|
-
onClick: (h) => c(
|
|
147
|
-
onClose: (h) => N(
|
|
148
|
-
onCloseOtherTabs: (h) =>
|
|
149
|
-
onCopyUrl: (h) => y(
|
|
147
|
+
onClick: (h) => c(r),
|
|
148
|
+
onClose: (h) => N(r),
|
|
149
|
+
onCloseOtherTabs: (h) => U(r),
|
|
150
|
+
onCopyUrl: (h) => y(r),
|
|
150
151
|
onNewTab: p
|
|
151
152
|
}, null, 8, ["active", "hotkey", "icon", "label", "onClick", "onClose", "onCloseOtherTabs", "onCopyUrl"]))), 128)),
|
|
152
153
|
f("button", {
|
|
@@ -165,5 +166,5 @@ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee
|
|
|
165
166
|
}
|
|
166
167
|
});
|
|
167
168
|
export {
|
|
168
|
-
|
|
169
|
+
fe as default
|
|
169
170
|
};
|