@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.
Files changed (106) hide show
  1. package/CHANGELOG.md +69 -0
  2. package/dist/components/AddressBar/AddressBarServer.vue.d.ts.map +1 -1
  3. package/dist/components/AddressBar/AddressBarServer.vue.js +15 -15
  4. package/dist/components/CommandPalette/CommandPaletteExample.vue.js +1 -1
  5. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +1 -1
  6. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
  7. package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +24 -24
  8. package/dist/components/CommandPalette/CommandPaletteServer.vue.js +2 -2
  9. package/dist/components/CommandPalette/CommandPaletteTag.vue.js +5 -5
  10. package/dist/components/DataTable/DataTableCheckbox.vue.d.ts.map +1 -1
  11. package/dist/components/DataTable/DataTableCheckbox.vue.js +5 -6
  12. package/dist/components/DataTable/DataTableInputSelect.vue.d.ts.map +1 -1
  13. package/dist/components/DataTable/DataTableInputSelect.vue.js +8 -8
  14. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.d.ts.map +1 -1
  15. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +37 -47
  16. package/dist/components/HttpMethod/HttpMethod.vue.d.ts.map +1 -1
  17. package/dist/components/HttpMethod/HttpMethod.vue.js +2 -2
  18. package/dist/components/HttpMethod/HttpMethod.vue2.js +16 -17
  19. package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts.map +1 -1
  20. package/dist/components/ImportCollection/ImportCollectionModal.vue.js +85 -84
  21. package/dist/components/ImportCollection/ImportNowButton.vue.js +3 -3
  22. package/dist/components/ImportCollection/WorkspaceSelector.vue.d.ts.map +1 -1
  23. package/dist/components/ImportCollection/WorkspaceSelector.vue.js +24 -26
  24. package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts +6 -0
  25. package/dist/components/ImportCollection/hooks/useUrlPrefetcher.d.ts.map +1 -1
  26. package/dist/components/ImportCollection/hooks/useUrlPrefetcher.js +28 -23
  27. package/dist/components/OpenApiClientButton.vue.d.ts.map +1 -1
  28. package/dist/components/OpenApiClientButton.vue.js +1 -1
  29. package/dist/components/OpenApiClientButton.vue2.js +16 -16
  30. package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
  31. package/dist/components/TopNav/TopNav.vue.js +72 -70
  32. package/dist/components/TopNav/TopNavItem.vue.d.ts.map +1 -1
  33. package/dist/components/TopNav/TopNavItem.vue.js +1 -1
  34. package/dist/components/TopNav/TopNavItem.vue2.js +83 -81
  35. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
  36. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +5 -6
  37. package/dist/layouts/App/create-api-client-app.d.ts +3 -2
  38. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  39. package/dist/layouts/App/create-api-client-app.js +6 -6
  40. package/dist/layouts/Modal/create-api-client-modal.d.ts +6 -4
  41. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  42. package/dist/layouts/Modal/create-api-client-modal.js +1 -1
  43. package/dist/layouts/Web/create-api-client-web.d.ts +3 -2
  44. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  45. package/dist/layouts/Web/create-api-client-web.js +4 -4
  46. package/dist/libs/create-client.d.ts +6 -5
  47. package/dist/libs/create-client.d.ts.map +1 -1
  48. package/dist/libs/create-client.js +38 -37
  49. package/dist/libs/index.d.ts +1 -2
  50. package/dist/libs/index.d.ts.map +1 -1
  51. package/dist/libs/index.js +20 -20
  52. package/dist/libs/send-request/index.d.ts +2 -0
  53. package/dist/libs/send-request/index.d.ts.map +1 -0
  54. package/dist/libs/send-request/index.js +9 -0
  55. package/dist/libs/{send-request.d.ts → send-request/send-request.d.ts} +6 -6
  56. package/dist/libs/send-request/send-request.d.ts.map +1 -0
  57. package/dist/libs/{send-request.js → send-request/send-request.js} +29 -29
  58. package/dist/store/events.d.ts +1 -1
  59. package/dist/store/import-spec.d.ts +1 -1
  60. package/dist/store/import-spec.d.ts.map +1 -1
  61. package/dist/store/import-spec.js +1 -1
  62. package/dist/store/store.d.ts +6 -4
  63. package/dist/store/store.d.ts.map +1 -1
  64. package/dist/store/store.js +47 -45
  65. package/dist/style.css +1 -1
  66. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  67. package/dist/views/Cookies/Cookies.vue2.js +18 -20
  68. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
  69. package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +76 -72
  70. package/dist/views/Request/Request.vue.js +1 -1
  71. package/dist/views/Request/Request.vue2.js +30 -30
  72. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
  73. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +20 -19
  74. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
  75. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +1 -1
  76. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +2 -2
  77. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  78. package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
  79. package/dist/views/Request/RequestSection/RequestBody.vue2.js +245 -191
  80. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  81. package/dist/views/Request/RequestSidebar.vue.js +3 -3
  82. package/dist/views/Request/RequestSidebar.vue2.js +60 -61
  83. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  84. package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
  85. package/dist/views/Request/RequestSidebarItem.vue2.js +188 -196
  86. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
  87. package/dist/views/Request/RequestSidebarItemMenu.vue.js +3 -3
  88. package/dist/views/Request/RequestSidebarItemMenu.vue2.js +153 -147
  89. package/dist/views/Request/RequestSubpageHeader.vue.d.ts.map +1 -1
  90. package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
  91. package/dist/views/Request/RequestSubpageHeader.vue2.js +24 -28
  92. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.d.ts.map +1 -1
  93. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.js +1 -1
  94. package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue2.js +5 -5
  95. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
  96. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +2 -2
  97. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +30 -25
  98. package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.d.ts.map +1 -1
  99. package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.js +41 -30
  100. package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
  101. package/dist/views/Request/components/WorkspaceDropdown.vue.js +50 -58
  102. package/dist/views/Request/libs/oauth2.d.ts +6 -2
  103. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  104. package/dist/views/Request/libs/oauth2.js +43 -37
  105. package/package.json +18 -14
  106. package/dist/libs/send-request.d.ts.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"OpenApiClientButton.vue.d.ts","sourceRoot":"","sources":["../../src/components/OpenApiClientButton.vue"],"names":[],"mappings":"AA4FA,KAAK,WAAW,GAAG;IACjB,YAAY,EAAE,SAAS,GAAG,OAAO,CAAA;IACjC,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC3B,GAAG,CAAC,EAAE,MAAM,CAAA;CACb,CAAC;;AAkGF,wBAMG"}
1
+ {"version":3,"file":"OpenApiClientButton.vue.d.ts","sourceRoot":"","sources":["../../src/components/OpenApiClientButton.vue"],"names":[],"mappings":"AAmGA,KAAK,WAAW,GAAG;IACjB,YAAY,EAAE,SAAS,GAAG,OAAO,CAAA;IACjC,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IAC3B,GAAG,CAAC,EAAE,MAAM,CAAA;CACb,CAAC;;AAyGF,wBAMG"}
@@ -1,7 +1,7 @@
1
1
  import t from "./OpenApiClientButton.vue2.js";
2
2
  /* empty css */
3
3
  import o from "../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ o(t, [["__scopeId", "data-v-3d5f00c1"]]);
4
+ const f = /* @__PURE__ */ o(t, [["__scopeId", "data-v-3ceef301"]]);
5
5
  export {
6
6
  f as default
7
7
  };
@@ -1,7 +1,7 @@
1
- import { defineComponent as o, computed as a, openBlock as i, createElementBlock as s, createVNode as c, unref as m, createTextVNode as u, createCommentVNode as l } from "vue";
1
+ import { defineComponent as a, computed as i, openBlock as c, createElementBlock as s, createVNode as m, unref as u, createTextVNode as l, createCommentVNode as f } from "vue";
2
2
  import { ScalarIcon as p } from "@scalar/components";
3
- import { makeUrlAbsolute as f } from "@scalar/oas-utils/helpers";
4
- const h = ["href"], v = /* @__PURE__ */ o({
3
+ import { makeUrlAbsolute as d } from "@scalar/oas-utils/helpers";
4
+ const h = ["href"], P = /* @__PURE__ */ a({
5
5
  __name: "OpenApiClientButton",
6
6
  props: {
7
7
  buttonSource: {},
@@ -9,31 +9,31 @@ const h = ["href"], v = /* @__PURE__ */ o({
9
9
  integration: {},
10
10
  url: {}
11
11
  },
12
- setup(t) {
13
- const r = a(() => {
14
- const n = f(t.url);
15
- if (!(n != null && n.length))
12
+ setup(n) {
13
+ const o = i(() => {
14
+ const r = n.url ?? (typeof window < "u" ? window.location.href : void 0), e = d(r);
15
+ if (!(e != null && e.length))
16
16
  return;
17
- const e = new URL(
18
- t.isDevelopment ? "http://localhost:5065" : "https://client.scalar.com"
17
+ const t = new URL(
18
+ n.isDevelopment ? "http://localhost:5065" : "https://client.scalar.com"
19
19
  );
20
- return e.searchParams.set("url", n), t.integration !== null && e.searchParams.set("integration", t.integration ?? "vue"), e.searchParams.set("utm_source", "api-reference"), e.searchParams.set("utm_medium", "button"), e.searchParams.set("utm_campaign", t.buttonSource), e.toString();
20
+ return t.searchParams.set("url", e), n.integration !== null && t.searchParams.set("integration", n.integration ?? "vue"), t.searchParams.set("utm_source", "api-reference"), t.searchParams.set("utm_medium", "button"), t.searchParams.set("utm_campaign", n.buttonSource), t.toString();
21
21
  });
22
- return (n, e) => r.value ? (i(), s("a", {
22
+ return (r, e) => o.value ? (c(), s("a", {
23
23
  key: 0,
24
24
  class: "open-api-client-button",
25
- href: r.value,
25
+ href: o.value,
26
26
  target: "_blank"
27
27
  }, [
28
- c(m(p), {
28
+ m(u(p), {
29
29
  icon: "ExternalLink",
30
30
  size: "xs",
31
31
  thickness: "2.5"
32
32
  }),
33
- e[0] || (e[0] = u(" Open API Client "))
34
- ], 8, h)) : l("", !0);
33
+ e[0] || (e[0] = l(" Open API Client "))
34
+ ], 8, h)) : f("", !0);
35
35
  }
36
36
  });
37
37
  export {
38
- v as default
38
+ P as default
39
39
  };
@@ -1 +1 @@
1
- {"version":3,"file":"TopNav.vue.d.ts","sourceRoot":"","sources":["../../../src/components/TopNav/TopNav.vue"],"names":[],"mappings":"AAsPA,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACjD,CAAC;;AAgaF,wBAOG"}
1
+ {"version":3,"file":"TopNav.vue.d.ts","sourceRoot":"","sources":["../../../src/components/TopNav/TopNav.vue"],"names":[],"mappings":"AAwPA,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACjD,CAAC;;AA0aF,wBAOG"}
@@ -1,46 +1,46 @@
1
- import { defineComponent as $, reactive as z, ref as E, computed as M, watch as w, onMounted as j, onBeforeUnmount as B, openBlock as m, createElementBlock as b, createElementVNode as f, createVNode as n, unref as l, withCtx as u, toDisplayString as O, createTextVNode as x, Fragment as V, renderList as D, createBlock as K } from "vue";
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 r, 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
- import { ScalarContextMenu as W, ScalarIcon as d, ScalarDropdown as G, ScalarDropdownItem as I } from "@scalar/components";
6
- import { capitalize as J } from "@scalar/oas-utils/helpers";
7
- import { useClipboard as P } from "@scalar/use-hooks/useClipboard";
8
- import Q from "./TopNavItem.vue.js";
9
- import { useWorkspace as X } from "../../store/store.js";
10
- const Y = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, Z = { class: "flex h-10 flex-1 items-center gap-1.5 text-sm font-medium pr-2.5 relative overflow-hidden" }, ee = {
5
+ import { ScalarContextMenu as W, ScalarIcon as d, ScalarFloating as G, ScalarDropdownMenu as J, ScalarDropdownButton as _ } from "@scalar/components";
6
+ import { capitalize as P } from "@scalar/oas-utils/helpers";
7
+ import { useClipboard as Q } from "@scalar/use-hooks/useClipboard";
8
+ import X from "./TopNavItem.vue.js";
9
+ import { useWorkspace as Y } from "../../store/store.js";
10
+ const Z = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, ee = { class: "flex h-10 flex-1 items-center gap-1.5 text-sm font-medium pr-2.5 relative overflow-hidden" }, te = {
11
11
  key: 0,
12
12
  class: "h-full w-full overflow-hidden"
13
- }, ue = /* @__PURE__ */ $({
13
+ }, pe = /* @__PURE__ */ M({
14
14
  __name: "TopNav",
15
15
  props: {
16
16
  openNewTab: {}
17
17
  },
18
- setup(_) {
19
- const L = _, { activeRequest: S, router: i } = H(), { events: g } = X(), { copyToClipboard: U } = P(), t = z([{ label: "", path: "", icon: "Add" }]), a = E(0), T = M(() => a.value);
18
+ setup(I) {
19
+ const S = I, { activeRequest: L, router: s } = H(), { events: g } = Y(), { copyToClipboard: U } = Q(), t = $([{ label: "", path: "", icon: "Add" }]), a = z(0), T = B(() => a.value);
20
20
  function k() {
21
21
  var o;
22
- const e = F.find((c) => i.currentRoute.value.name == c.name);
22
+ const e = F.find((u) => s.currentRoute.value.name == u.name);
23
23
  e && ((e == null ? void 0 : e.name) === "request" ? t[a.value] = {
24
- label: ((o = S.value) == null ? void 0 : o.summary) || "",
25
- path: i.currentRoute.value.path,
24
+ label: ((o = L.value) == null ? void 0 : o.summary) || "",
25
+ path: s.currentRoute.value.path,
26
26
  icon: e.icon
27
27
  } : t[a.value] = {
28
- label: J(e == null ? void 0 : e.name) || "",
29
- path: i.currentRoute.value.path,
28
+ label: P(e == null ? void 0 : e.name) || "",
29
+ path: s.currentRoute.value.path,
30
30
  icon: e.icon
31
31
  });
32
32
  }
33
33
  function v() {
34
- i.push(t[a.value].path);
34
+ s.push(t[a.value].path);
35
35
  }
36
36
  function p() {
37
37
  t.push({ label: "", path: "", icon: "Add" }), a.value = t.length - 1, k();
38
38
  }
39
- function r(e) {
39
+ function c(e) {
40
40
  a.value = e, v();
41
41
  }
42
42
  w(
43
- () => i.currentRoute.value.path,
43
+ () => s.currentRoute.value.path,
44
44
  () => {
45
45
  k();
46
46
  },
@@ -59,11 +59,11 @@ const Y = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, Z =
59
59
  t.splice(0, e), t.splice(1), a.value = 0, v();
60
60
  }, C = (e) => {
61
61
  if (e) {
62
- if (e.addTopNav && p(), e.closeTopNav && N(a.value), e.navigateTopNavLeft && r(Math.max(a.value - 1, 0)), e.navigateTopNavRight && r(Math.min(a.value + 1, t.length - 1)), e.jumpToTab) {
62
+ if (e.addTopNav && p(), e.closeTopNav && N(a.value), e.navigateTopNavLeft && c(Math.max(a.value - 1, 0)), e.navigateTopNavRight && c(Math.min(a.value + 1, t.length - 1)), e.jumpToTab) {
63
63
  const o = Number(e.jumpToTab.key) - 1;
64
- o >= 0 && o < t.length && r(o);
64
+ o >= 0 && o < t.length && c(o);
65
65
  }
66
- e.jumpToLastTab && r(t.length - 1);
66
+ e.jumpToLastTab && c(t.length - 1);
67
67
  }
68
68
  }, A = (e) => {
69
69
  t.push({
@@ -73,17 +73,17 @@ const Y = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, Z =
73
73
  });
74
74
  };
75
75
  return w(
76
- () => L.openNewTab,
76
+ () => S.openNewTab,
77
77
  (e) => {
78
78
  e && A(e);
79
79
  },
80
80
  { immediate: !0 }
81
- ), j(() => g.hotKeys.on(C)), B(() => g.hotKeys.off(C)), (e, o) => (m(), b("nav", Y, [
81
+ ), E(() => g.hotKeys.on(C)), j(() => g.hotKeys.off(C)), (e, o) => (m(), b("nav", Z, [
82
82
  o[3] || (o[3] = f("div", { class: "absolute inset-0 app-drag-region" }, null, -1)),
83
- f("div", Z, [
84
- t.length === 1 ? (m(), b("div", ee, [
83
+ f("div", ee, [
84
+ t.length === 1 ? (m(), b("div", te, [
85
85
  n(l(W), { triggerClass: "flex custom-scroll gap-1.5 h-full items-center justify-center w-full whitespace-nowrap" }, {
86
- trigger: u(() => [
86
+ trigger: r(() => [
87
87
  n(l(d), {
88
88
  icon: t[0].icon,
89
89
  size: "xs",
@@ -91,43 +91,45 @@ const Y = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, Z =
91
91
  }, null, 8, ["icon"]),
92
92
  f("span", null, O(t[0].label), 1)
93
93
  ]),
94
- content: u(() => [
95
- n(l(G), {
96
- class: "scalar-client",
97
- static: ""
98
- }, {
99
- items: u(() => [
100
- n(l(I), {
101
- class: "flex items-center gap-1.5",
102
- onClick: p
103
- }, {
104
- default: u(() => [
105
- n(l(d), {
106
- icon: "AddTab",
107
- size: "sm",
108
- thickness: "1.5"
94
+ content: r(() => [
95
+ n(l(G), { placement: "right-start" }, {
96
+ floating: r(() => [
97
+ n(l(J), { class: "scalar-app scalar-client" }, {
98
+ default: r(() => [
99
+ n(l(_), {
100
+ class: "flex items-center gap-1.5",
101
+ onClick: p
102
+ }, {
103
+ default: r(() => [
104
+ n(l(d), {
105
+ icon: "AddTab",
106
+ size: "sm",
107
+ thickness: "1.5"
108
+ }),
109
+ o[1] || (o[1] = x(" New Tab ")),
110
+ n(q, {
111
+ class: "bg-b-2 ml-auto",
112
+ hotkey: "T"
113
+ })
114
+ ]),
115
+ _: 1
109
116
  }),
110
- o[1] || (o[1] = x(" New Tab ")),
111
- n(q, {
112
- class: "bg-b-2 ml-auto",
113
- hotkey: "T"
117
+ n(l(_), {
118
+ class: "flex items-center gap-1.5",
119
+ onClick: o[0] || (o[0] = (u) => y(T.value))
120
+ }, {
121
+ default: r(() => [
122
+ n(l(d), {
123
+ icon: "Link",
124
+ size: "sm",
125
+ thickness: "1.5"
126
+ }),
127
+ o[2] || (o[2] = x(" Copy URL "))
128
+ ]),
129
+ _: 1
114
130
  })
115
131
  ]),
116
132
  _: 1
117
- }),
118
- n(l(I), {
119
- class: "flex items-center gap-1.5",
120
- onClick: o[0] || (o[0] = (c) => y(T.value))
121
- }, {
122
- default: u(() => [
123
- n(l(d), {
124
- icon: "Link",
125
- size: "sm",
126
- thickness: "1.5"
127
- }),
128
- o[2] || (o[2] = x(" Copy URL "))
129
- ]),
130
- _: 1
131
133
  })
132
134
  ]),
133
135
  _: 1
@@ -135,16 +137,16 @@ const Y = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, Z =
135
137
  ]),
136
138
  _: 1
137
139
  })
138
- ])) : (m(!0), b(V, { key: 1 }, D(t, (c, s) => (m(), K(Q, {
139
- key: s,
140
- active: s === T.value,
141
- hotkey: (s + 1).toString(),
142
- icon: c.icon,
143
- label: c.label,
144
- onClick: (h) => r(s),
145
- onClose: (h) => N(s),
146
- onCloseOtherTabs: (h) => R(s),
147
- onCopyUrl: (h) => y(s),
140
+ ])) : (m(!0), b(V, { key: 1 }, D(t, (u, i) => (m(), K(X, {
141
+ key: i,
142
+ active: i === T.value,
143
+ hotkey: (i + 1).toString(),
144
+ icon: u.icon,
145
+ label: u.label,
146
+ onClick: (h) => c(i),
147
+ onClose: (h) => N(i),
148
+ onCloseOtherTabs: (h) => R(i),
149
+ onCopyUrl: (h) => y(i),
148
150
  onNewTab: p
149
151
  }, null, 8, ["active", "hotkey", "icon", "label", "onClick", "onClose", "onCloseOtherTabs", "onCopyUrl"]))), 128)),
150
152
  f("button", {
@@ -163,5 +165,5 @@ const Y = { class: "flex relative h-10 pl-2 mac:pl-[72px] t-app__top-nav" }, Z =
163
165
  }
164
166
  });
165
167
  export {
166
- ue as default
168
+ pe as default
167
169
  };
@@ -1 +1 @@
1
- {"version":3,"file":"TopNavItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/TopNav/TopNavItem.vue"],"names":[],"mappings":"AAuMA,OAAO,EACL,KAAK,IAAI,EAOV,MAAM,oBAAoB,CAAA;AAI3B,KAAK,WAAW,GAAG;IACjB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,MAAM,EAAE,OAAO,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,IAAI,CAAA;CACX,CAAC;;;;;;;;;;;;;;AAiUF,wBAQG"}
1
+ {"version":3,"file":"TopNavItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/TopNav/TopNavItem.vue"],"names":[],"mappings":"AAwMA,OAAO,EACL,KAAK,IAAI,EAQV,MAAM,oBAAoB,CAAA;AAI3B,KAAK,WAAW,GAAG;IACjB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,MAAM,EAAE,OAAO,CAAA;IACf,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,IAAI,CAAA;CACX,CAAC;;;;;;;;;;;;;;AA2UF,wBAQG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./TopNavItem.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-9e263bd8"]]);
4
+ const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-d56f12d9"]]);
5
5
  export {
6
6
  a as default
7
7
  };
@@ -1,7 +1,7 @@
1
- import { defineComponent as k, openBlock as p, createBlock as d, unref as s, withCtx as i, createVNode as t, createElementVNode as a, normalizeClass as f, toDisplayString as u, createCommentVNode as b, createTextVNode as r } from "vue";
1
+ import { defineComponent as f, openBlock as p, createBlock as d, unref as s, withCtx as l, createVNode as t, createElementVNode as a, normalizeClass as k, toDisplayString as u, createCommentVNode as g, createTextVNode as r } from "vue";
2
2
  import c from "../ScalarHotkey.vue.js";
3
- import { ScalarContextMenu as g, ScalarTooltip as v, ScalarIcon as l, ScalarDropdown as C, ScalarDropdownItem as m, ScalarDropdownDivider as y } from "@scalar/components";
4
- const T = { class: "nav-item-icon-copy flex flex-1 items-center justify-center gap-1.5" }, $ = { class: "custom-scroll nav-item-copy text-xs" }, D = /* @__PURE__ */ k({
3
+ import { ScalarContextMenu as b, ScalarTooltip as v, ScalarIcon as n, ScalarFloating as C, ScalarDropdownMenu as y, ScalarDropdownButton as m, ScalarDropdownDivider as T } from "@scalar/components";
4
+ const $ = { class: "nav-item-icon-copy flex flex-1 items-center justify-center gap-1.5" }, w = { class: "custom-scroll nav-item-copy text-xs" }, B = /* @__PURE__ */ f({
5
5
  __name: "TopNavItem",
6
6
  props: {
7
7
  hotkey: {},
@@ -10,9 +10,9 @@ const T = { class: "nav-item-icon-copy flex flex-1 items-center justify-center g
10
10
  icon: {}
11
11
  },
12
12
  emits: ["click", "close", "newTab", "copyUrl", "closeOtherTabs"],
13
- setup(w) {
14
- return (o, e) => (p(), d(s(g), { triggerClass: "overflow-hidden w-full" }, {
15
- trigger: i(() => [
13
+ setup(S) {
14
+ return (o, e) => (p(), d(s(b), { triggerClass: "overflow-hidden w-full" }, {
15
+ trigger: l(() => [
16
16
  t(s(v), {
17
17
  class: "scalar-client",
18
18
  delay: 500,
@@ -20,110 +20,112 @@ const T = { class: "nav-item-icon-copy flex flex-1 items-center justify-center g
20
20
  resize: "",
21
21
  sideOffset: 4
22
22
  }, {
23
- trigger: i(() => [
23
+ trigger: l(() => [
24
24
  a("div", {
25
- class: f(["nav-item app-no-drag-region", { "nav-item__active": o.active }]),
26
- onClick: e[1] || (e[1] = (n) => o.$emit("click"))
25
+ class: k(["nav-item app-no-drag-region", { "nav-item__active": o.active }]),
26
+ onClick: e[1] || (e[1] = (i) => o.$emit("click"))
27
27
  }, [
28
- a("div", T, [
29
- t(s(l), {
28
+ a("div", $, [
29
+ t(s(n), {
30
30
  icon: o.icon,
31
31
  size: "xs",
32
32
  thickness: "2.5"
33
33
  }, null, 8, ["icon"]),
34
- a("span", $, u(o.label), 1)
34
+ a("span", w, u(o.label), 1)
35
35
  ]),
36
36
  a("button", {
37
37
  class: "nav-item-close",
38
38
  type: "button",
39
- onClick: e[0] || (e[0] = (n) => o.$emit("close"))
39
+ onClick: e[0] || (e[0] = (i) => o.$emit("close"))
40
40
  }, [
41
- t(s(l), {
41
+ t(s(n), {
42
42
  icon: "Close",
43
43
  thickness: "1.75"
44
44
  })
45
45
  ])
46
46
  ], 2)
47
47
  ]),
48
- content: i(() => [
48
+ content: l(() => [
49
49
  o.hotkey ? (p(), d(c, {
50
50
  key: 0,
51
51
  hotkey: o.hotkey
52
- }, null, 8, ["hotkey"])) : b("", !0)
52
+ }, null, 8, ["hotkey"])) : g("", !0)
53
53
  ]),
54
54
  _: 1
55
55
  })
56
56
  ]),
57
- content: i(() => [
58
- t(s(C), {
59
- class: "scalar-client",
60
- static: ""
61
- }, {
62
- items: i(() => [
63
- t(s(m), {
64
- class: "flex items-center gap-1.5",
65
- onClick: e[2] || (e[2] = (n) => o.$emit("newTab"))
66
- }, {
67
- default: i(() => [
68
- t(s(l), {
69
- icon: "AddTab",
70
- size: "sm",
71
- thickness: "1.5"
57
+ content: l(() => [
58
+ t(s(C), { placement: "right-start" }, {
59
+ floating: l(() => [
60
+ t(s(y), { class: "scalar-app scalar-client" }, {
61
+ default: l(() => [
62
+ t(s(m), {
63
+ class: "flex items-center gap-1.5",
64
+ onClick: e[2] || (e[2] = (i) => o.$emit("newTab"))
65
+ }, {
66
+ default: l(() => [
67
+ t(s(n), {
68
+ icon: "AddTab",
69
+ size: "sm",
70
+ thickness: "1.5"
71
+ }),
72
+ e[6] || (e[6] = r(" New Tab ")),
73
+ t(c, {
74
+ class: "bg-b-2 ml-auto",
75
+ hotkey: "T"
76
+ })
77
+ ]),
78
+ _: 1
72
79
  }),
73
- e[6] || (e[6] = r(" New Tab ")),
74
- t(c, {
75
- class: "bg-b-2 ml-auto",
76
- hotkey: "T"
77
- })
78
- ]),
79
- _: 1
80
- }),
81
- t(s(m), {
82
- class: "flex items-center gap-1.5",
83
- onClick: e[3] || (e[3] = (n) => o.$emit("copyUrl"))
84
- }, {
85
- default: i(() => [
86
- t(s(l), {
87
- icon: "Link",
88
- size: "sm",
89
- thickness: "1.5"
80
+ t(s(m), {
81
+ class: "flex items-center gap-1.5",
82
+ onClick: e[3] || (e[3] = (i) => o.$emit("copyUrl"))
83
+ }, {
84
+ default: l(() => [
85
+ t(s(n), {
86
+ icon: "Link",
87
+ size: "sm",
88
+ thickness: "1.5"
89
+ }),
90
+ e[7] || (e[7] = r(" Copy URL "))
91
+ ]),
92
+ _: 1
90
93
  }),
91
- e[7] || (e[7] = r(" Copy URL "))
92
- ]),
93
- _: 1
94
- }),
95
- t(s(y)),
96
- t(s(m), {
97
- class: "flex items-center gap-1.5",
98
- onClick: e[4] || (e[4] = (n) => o.$emit("close"))
99
- }, {
100
- default: i(() => [
101
- t(s(l), {
102
- icon: "CloseTab",
103
- size: "sm",
104
- thickness: "1.5"
94
+ t(s(T)),
95
+ t(s(m), {
96
+ class: "flex items-center gap-1.5",
97
+ onClick: e[4] || (e[4] = (i) => o.$emit("close"))
98
+ }, {
99
+ default: l(() => [
100
+ t(s(n), {
101
+ icon: "CloseTab",
102
+ size: "sm",
103
+ thickness: "1.5"
104
+ }),
105
+ e[8] || (e[8] = r(" Close Tab ")),
106
+ t(c, {
107
+ class: "bg-b-2 ml-auto",
108
+ hotkey: "W"
109
+ })
110
+ ]),
111
+ _: 1
105
112
  }),
106
- e[8] || (e[8] = r(" Close Tab ")),
107
- t(c, {
108
- class: "bg-b-2 ml-auto",
109
- hotkey: "W"
113
+ t(s(m), {
114
+ class: "flex items-center gap-1.5",
115
+ onClick: e[5] || (e[5] = (i) => o.$emit("closeOtherTabs"))
116
+ }, {
117
+ default: l(() => [
118
+ t(s(n), {
119
+ icon: "CloseTabs",
120
+ size: "sm",
121
+ thickness: "1.5"
122
+ }),
123
+ e[9] || (e[9] = r(" Close Other Tabs "))
124
+ ]),
125
+ _: 1
110
126
  })
111
127
  ]),
112
128
  _: 1
113
- }),
114
- t(s(m), {
115
- class: "flex items-center gap-1.5",
116
- onClick: e[5] || (e[5] = (n) => o.$emit("closeOtherTabs"))
117
- }, {
118
- default: i(() => [
119
- t(s(l), {
120
- icon: "CloseTabs",
121
- size: "sm",
122
- thickness: "1.5"
123
- }),
124
- e[9] || (e[9] = r(" Close Other Tabs "))
125
- ]),
126
- _: 1
127
129
  })
128
130
  ]),
129
131
  _: 1
@@ -134,5 +136,5 @@ const T = { class: "nav-item-icon-copy flex flex-1 items-center justify-center g
134
136
  }
135
137
  });
136
138
  export {
137
- D as default
139
+ B as default
138
140
  };
@@ -1 +1 @@
1
- {"version":3,"file":"ViewLayoutCollapse.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ViewLayout/ViewLayoutCollapse.vue"],"names":[],"mappings":"AAgEA,KAAK,WAAW,GAAG;IACf,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAC;AAkBJ,iBAAS,cAAc;WA2IT,OAAO,IAA6B;;;;YAVtB,GAAG;;;YACD,GAAG;;;YACH,GAAG;;;;EAahC;AAaD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;iBAlLH,OAAO;eACT,MAAM;6EAyLpB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"ViewLayoutCollapse.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ViewLayout/ViewLayoutCollapse.vue"],"names":[],"mappings":"AA+DA,KAAK,WAAW,GAAG;IACf,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAC;AAkBJ,iBAAS,cAAc;WA2IT,OAAO,IAA6B;;;;YAVtB,GAAG;;;YACD,GAAG;;;YACH,GAAG;;;;EAahC;AAaD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;iBAlLH,OAAO;eACT,MAAM;6EAyLpB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as c, openBlock as s, createBlock as d, unref as o, withCtx as n, createElementVNode as r, createVNode as i, renderSlot as l, createElementBlock as u, toDisplayString as p, createCommentVNode as a, mergeProps as f } from "vue";
2
- import { Disclosure as m, DisclosureButton as h, DisclosurePanel as x } from "@headlessui/vue";
2
+ import { Disclosure as m, DisclosureButton as x, DisclosurePanel as h } from "@headlessui/vue";
3
3
  import { ScalarIcon as b } from "@scalar/components";
4
4
  const g = { class: "flex items-center" }, v = { class: "flex flex-1 items-center gap-1.5 text-c-1" }, _ = {
5
5
  key: 0,
@@ -14,20 +14,19 @@ const g = { class: "flex items-center" }, v = { class: "flex flex-1 items-center
14
14
  itemCount: { default: 0 }
15
15
  },
16
16
  setup(y) {
17
- return (e, k) => (s(), d(o(m), {
17
+ return (e, w) => (s(), d(o(m), {
18
18
  as: "div",
19
19
  class: "focus-within:bg-b-2 ui-not-open:hover:bg-b-2 focus-within:text-c-1 text-c-2 rounded request-item ui-not-open:bg-transparent ui-open:[&:not(:last-child)]:mb-2.5 ui-not-open:mb-[0.5px]",
20
20
  defaultOpen: e.defaultOpen
21
21
  }, {
22
22
  default: n(({ open: t }) => [
23
23
  r("div", g, [
24
- i(o(h), { class: "group hover:text-c-1 flex flex-1 items-center gap-2.5 overflow-hidden py-1.5 text-sm font-medium px-1 md:px-1.5 xl:px-2 outline-none" }, {
24
+ i(o(x), { class: "group hover:text-c-1 flex flex-1 items-center gap-2.5 overflow-hidden py-1.5 text-sm font-medium px-1 md:px-1.5 xl:px-2 outline-none" }, {
25
25
  default: n(() => [
26
26
  i(o(b), {
27
27
  class: "text-c-3 group-hover:text-c-1 group-focus-visible:outline ui-open:rotate-90 ui-not-open:rotate-0 rounded-[1px] outline-offset-2",
28
28
  icon: "ChevronRight",
29
- size: "sm",
30
- thickness: "2.5"
29
+ size: "md"
31
30
  }),
32
31
  r("div", v, [
33
32
  l(e.$slots, "title", { open: t }),
@@ -40,7 +39,7 @@ const g = { class: "flex items-center" }, v = { class: "flex flex-1 items-center
40
39
  l(e.$slots, "actions", { open: t })
41
40
  ])) : a("", !0)
42
41
  ]),
43
- i(o(x), f(e.$attrs, { class: "h-full max-h-fit rounded-b diclosure-panel" }), {
42
+ i(o(h), f(e.$attrs, { class: "h-full max-h-fit rounded-b diclosure-panel" }), {
44
43
  default: n(() => [
45
44
  l(e.$slots, "default", { open: t })
46
45
  ]),
@@ -362,6 +362,7 @@ export declare const createApiClientApp: (el: HTMLElement | null, configuration?
362
362
  sidebarWidth: import("vue").Ref<string, string>;
363
363
  setSidebarWidth: (width: string) => void;
364
364
  isReadOnly: boolean;
365
+ hideClientButton: boolean | undefined;
365
366
  importSpecFile: (_spec: string | Record<string, any>, workspaceUid: string, options?: Pick<{
366
367
  type?: "collection" | undefined;
367
368
  uid?: string | undefined;
@@ -473,7 +474,7 @@ export declare const createApiClientApp: (el: HTMLElement | null, configuration?
473
474
  documentUrl?: string | undefined;
474
475
  integration?: string | null | undefined;
475
476
  } | undefined>;
476
- importSpecFromUrl: (url: string, workspaceUid: string, { proxy, ...options }?: Omit<Pick<{
477
+ importSpecFromUrl: (url: string, workspaceUid: string, { proxyUrl, ...options }?: Omit<Pick<{
477
478
  type?: "collection" | undefined;
478
479
  uid?: string | undefined;
479
480
  externalDocs?: {
@@ -529,7 +530,7 @@ export declare const createApiClientApp: (el: HTMLElement | null, configuration?
529
530
  watchModeStatus?: "IDLE" | "WATCHING" | "ERROR" | undefined;
530
531
  }, "documentUrl" | "watchMode"> & Pick<import("@scalar/types").ReferenceConfiguration, "servers" | "authentication" | "baseServerURL"> & {
531
532
  setCollectionSecurity?: boolean;
532
- } & Pick<import("@scalar/types").ReferenceConfiguration, "servers">, "documentUrl"> & Pick<import("@scalar/types").ReferenceConfiguration, "proxy">) => Promise<import("../../libs/index.js").ErrorResponse<Awaited<ReturnType<(_spec: string | Record<string, any>, workspaceUid: string, options?: Pick<{
533
+ } & Pick<import("@scalar/types").ReferenceConfiguration, "servers">, "documentUrl"> & Pick<import("@scalar/types").ReferenceConfiguration, "proxyUrl">) => Promise<import("../../libs/index.js").ErrorResponse<Awaited<ReturnType<(_spec: string | Record<string, any>, workspaceUid: string, options?: Pick<{
533
534
  type?: "collection" | undefined;
534
535
  uid?: string | undefined;
535
536
  externalDocs?: {