@scalar/api-client 2.2.48 → 2.2.50

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (217) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/dist/components/AddressBar/AddressBar.vue.d.ts +15 -3
  3. package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
  4. package/dist/components/AddressBar/AddressBar.vue.js +1 -1
  5. package/dist/components/AddressBar/AddressBar.vue2.js +102 -94
  6. package/dist/components/AddressBar/AddressBarHistory.vue.d.ts +2 -0
  7. package/dist/components/AddressBar/AddressBarHistory.vue.d.ts.map +1 -1
  8. package/dist/components/AddressBar/AddressBarHistory.vue.js +2 -2
  9. package/dist/components/AddressBar/AddressBarHistory.vue2.js +54 -58
  10. package/dist/components/CodeInput/CodeInput.vue.d.ts +9 -0
  11. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  12. package/dist/components/CodeInput/CodeInput.vue.js +2 -2
  13. package/dist/components/CodeInput/CodeInput.vue2.js +95 -93
  14. package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
  15. package/dist/components/CodeInput/codeVariableWidget.js +1 -3
  16. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
  17. package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +26 -22
  18. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
  19. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +13 -13
  20. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
  21. package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +12 -12
  22. package/dist/components/CommandPalette/CommandPaletteServer.vue.d.ts.map +1 -1
  23. package/dist/components/CommandPalette/CommandPaletteServer.vue.js +54 -49
  24. package/dist/components/CommandPalette/CommandPaletteTag.vue.d.ts.map +1 -1
  25. package/dist/components/CommandPalette/CommandPaletteTag.vue.js +9 -9
  26. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
  27. package/dist/components/DataTable/DataTableCell.vue.d.ts.map +1 -1
  28. package/dist/components/DataTable/DataTableCell.vue.js +11 -8
  29. package/dist/components/DataTable/DataTableInput.vue.d.ts +6 -0
  30. package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
  31. package/dist/components/DataTable/DataTableInput.vue.js +4 -4
  32. package/dist/components/DataTable/DataTableInput.vue2.js +36 -30
  33. package/dist/components/DataTable/DataTableInputSelect.vue.d.ts.map +1 -1
  34. package/dist/components/DataTable/DataTableInputSelect.vue.js +15 -15
  35. package/dist/components/Form/Form.vue.d.ts +3 -1
  36. package/dist/components/Form/Form.vue.d.ts.map +1 -1
  37. package/dist/components/Form/Form.vue.js +30 -25
  38. package/dist/components/ImportCollection/ImportCollectionModal.vue.d.ts.map +1 -1
  39. package/dist/components/ImportCollection/ImportCollectionModal.vue.js +41 -41
  40. package/dist/components/ImportCollection/ImportNowButton.vue.js +24 -24
  41. package/dist/components/ScreenReader.vue.d.ts.map +1 -1
  42. package/dist/components/Server/ServerDropdown.vue.d.ts.map +1 -1
  43. package/dist/components/Server/ServerDropdown.vue.js +13 -13
  44. package/dist/components/Server/ServerDropdownItem.vue.d.ts +1 -1
  45. package/dist/components/Server/ServerDropdownItem.vue.d.ts.map +1 -1
  46. package/dist/components/Server/ServerDropdownItem.vue.js +1 -1
  47. package/dist/components/Server/ServerDropdownItem.vue2.js +19 -19
  48. package/dist/layouts/App/create-api-client-app.d.ts +387 -477
  49. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  50. package/dist/layouts/Modal/create-api-client-modal.d.ts +774 -954
  51. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  52. package/dist/layouts/Web/create-api-client-web.d.ts +387 -477
  53. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  54. package/dist/libs/create-client.d.ts +390 -479
  55. package/dist/libs/create-client.d.ts.map +1 -1
  56. package/dist/libs/create-client.js +3 -15
  57. package/dist/libs/env-helpers.d.ts.map +1 -1
  58. package/dist/libs/find-request.d.ts +7 -7
  59. package/dist/libs/find-request.d.ts.map +1 -1
  60. package/dist/libs/hot-keys.d.ts +3 -1
  61. package/dist/libs/hot-keys.d.ts.map +1 -1
  62. package/dist/libs/hot-keys.js +11 -15
  63. package/dist/libs/hot-keys.test.d.ts +2 -0
  64. package/dist/libs/hot-keys.test.d.ts.map +1 -0
  65. package/dist/libs/index.js +27 -26
  66. package/dist/libs/send-request/build-request-security.d.ts +1 -1
  67. package/dist/libs/send-request/build-request-security.js +19 -16
  68. package/dist/libs/send-request/create-request-operation.test.d.ts +10 -10
  69. package/dist/libs/send-request/create-request-operation.test.d.ts.map +1 -1
  70. package/dist/libs/send-request/set-request-cookies.d.ts +1 -1
  71. package/dist/libs/send-request/set-request-cookies.d.ts.map +1 -1
  72. package/dist/libs/send-request/set-request-cookies.js +37 -34
  73. package/dist/store/active-entities.d.ts +58 -67
  74. package/dist/store/active-entities.d.ts.map +1 -1
  75. package/dist/store/active-entities.js +61 -74
  76. package/dist/store/collections.d.ts +90 -90
  77. package/dist/store/collections.d.ts.map +1 -1
  78. package/dist/store/collections.js +4 -17
  79. package/dist/store/cookies.d.ts +14 -14
  80. package/dist/store/environment.d.ts +19 -18
  81. package/dist/store/environment.d.ts.map +1 -1
  82. package/dist/store/environment.js +2 -8
  83. package/dist/store/import-spec.d.ts +16 -106
  84. package/dist/store/import-spec.d.ts.map +1 -1
  85. package/dist/store/import-spec.js +9 -14
  86. package/dist/store/request-example.d.ts +25 -25
  87. package/dist/store/request-example.d.ts.map +1 -1
  88. package/dist/store/request-example.js +15 -20
  89. package/dist/store/requests.d.ts +84 -84
  90. package/dist/store/requests.d.ts.map +1 -1
  91. package/dist/store/requests.js +17 -40
  92. package/dist/store/router-params.d.ts +13 -11
  93. package/dist/store/router-params.d.ts.map +1 -1
  94. package/dist/store/router-params.js +5 -5
  95. package/dist/store/security-schemes.d.ts +58 -58
  96. package/dist/store/security-schemes.d.ts.map +1 -1
  97. package/dist/store/security-schemes.js +1 -3
  98. package/dist/store/servers.d.ts +17 -17
  99. package/dist/store/servers.d.ts.map +1 -1
  100. package/dist/store/servers.js +2 -9
  101. package/dist/store/store.d.ts +387 -477
  102. package/dist/store/store.d.ts.map +1 -1
  103. package/dist/store/store.js +2 -4
  104. package/dist/store/tags.d.ts +28 -28
  105. package/dist/store/tags.d.ts.map +1 -1
  106. package/dist/store/tags.js +19 -34
  107. package/dist/store/workspace.d.ts +36 -36
  108. package/dist/store/workspace.d.ts.map +1 -1
  109. package/dist/store/workspace.js +1 -5
  110. package/dist/style.css +1 -1
  111. package/dist/views/Collection/Collection.vue.d.ts.map +1 -1
  112. package/dist/views/Cookies/CookieForm.vue.d.ts.map +1 -1
  113. package/dist/views/Cookies/CookieForm.vue.js +18 -18
  114. package/dist/views/Cookies/CookieRaw.vue.d.ts.map +1 -1
  115. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  116. package/dist/views/Cookies/Cookies.vue2.js +24 -24
  117. package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
  118. package/dist/views/Environment/Environment.vue2.js +140 -132
  119. package/dist/views/Environment/EnvironmentModal.vue.d.ts +2 -2
  120. package/dist/views/Environment/EnvironmentModal.vue.d.ts.map +1 -1
  121. package/dist/views/Environment/EnvironmentModal.vue.js +15 -15
  122. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  123. package/dist/views/Request/Request.vue.js +2 -2
  124. package/dist/views/Request/Request.vue2.js +160 -141
  125. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts +2 -1
  126. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.d.ts.map +1 -1
  127. package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.js +7 -7
  128. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts +6 -2
  129. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
  130. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +99 -95
  131. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts +4 -0
  132. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
  133. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
  134. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +70 -64
  135. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts +4 -0
  136. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts.map +1 -1
  137. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +1 -1
  138. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +40 -34
  139. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts +6 -0
  140. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts.map +1 -1
  141. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.js +32 -26
  142. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.d.ts +4 -0
  143. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.d.ts.map +1 -1
  144. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.js +2 -2
  145. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue2.js +93 -85
  146. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts +9 -0
  147. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  148. package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
  149. package/dist/views/Request/RequestSection/RequestBody.vue2.js +214 -244
  150. package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts +10 -1
  151. package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts.map +1 -1
  152. package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +2 -2
  153. package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +77 -80
  154. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts +7 -0
  155. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
  156. package/dist/views/Request/RequestSection/RequestParams.vue.js +89 -96
  157. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts +10 -2
  158. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
  159. package/dist/views/Request/RequestSection/RequestPathParams.vue.js +59 -66
  160. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts +11 -0
  161. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  162. package/dist/views/Request/RequestSection/RequestSection.vue.js +2 -2
  163. package/dist/views/Request/RequestSection/RequestSection.vue2.js +176 -155
  164. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts +6 -0
  165. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
  166. package/dist/views/Request/RequestSection/RequestTable.vue.js +2 -2
  167. package/dist/views/Request/RequestSection/RequestTable.vue2.js +97 -100
  168. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.d.ts.map +1 -1
  169. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +2 -2
  170. package/dist/views/Request/RequestSection/RequestTableTooltip.vue2.js +31 -22
  171. package/dist/views/Request/RequestSection/helpers/getting-started.d.ts +2 -2
  172. package/dist/views/Request/RequestSection/helpers/getting-started.d.ts.map +1 -1
  173. package/dist/views/Request/RequestSection/helpers/getting-started.js +11 -13
  174. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  175. package/dist/views/Request/RequestSidebar.vue.js +1 -1
  176. package/dist/views/Request/RequestSidebar.vue2.js +50 -48
  177. package/dist/views/Request/RequestSidebarItem.vue.d.ts +1 -1
  178. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  179. package/dist/views/Request/RequestSidebarItem.vue.js +2 -2
  180. package/dist/views/Request/RequestSidebarItem.vue2.js +38 -44
  181. package/dist/views/Request/RequestSubpageHeader.vue.d.ts +10 -0
  182. package/dist/views/Request/RequestSubpageHeader.vue.d.ts.map +1 -1
  183. package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
  184. package/dist/views/Request/RequestSubpageHeader.vue2.js +77 -69
  185. package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue.js +7 -7
  186. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts +4 -1
  187. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
  188. package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +1 -1
  189. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +41 -39
  190. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts +1 -0
  191. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  192. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +1 -1
  193. package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +56 -52
  194. package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
  195. package/dist/views/Request/components/WorkspaceDropdown.vue.js +68 -68
  196. package/dist/views/Request/consts/new-auth-options.d.ts.map +1 -1
  197. package/dist/views/Request/handle-drag.d.ts +1 -1
  198. package/dist/views/Request/handle-drag.d.ts.map +1 -1
  199. package/dist/views/Request/handle-drag.js +38 -55
  200. package/dist/views/Request/libs/auth.d.ts +2 -2
  201. package/dist/views/Request/libs/auth.d.ts.map +1 -1
  202. package/dist/views/Request/libs/auth.js +28 -29
  203. package/dist/views/Request/libs/oauth2.d.ts.map +1 -1
  204. package/dist/views/Request/libs/oauth2.js +42 -65
  205. package/dist/views/Request/libs/request.d.ts +5 -0
  206. package/dist/views/Request/libs/request.d.ts.map +1 -1
  207. package/dist/views/Request/libs/request.js +37 -2
  208. package/dist/views/Request/libs/watch-mode.d.ts.map +1 -1
  209. package/dist/views/Request/libs/watch-mode.js +10 -34
  210. package/dist/views/Servers/ServerForm.vue.d.ts +1 -8
  211. package/dist/views/Servers/ServerForm.vue.d.ts.map +1 -1
  212. package/dist/views/Servers/ServerForm.vue.js +21 -22
  213. package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
  214. package/dist/views/Servers/Servers.vue2.js +73 -81
  215. package/dist/views/Settings/SettingsGeneral.vue.d.ts.map +1 -1
  216. package/dist/views/Settings/SettingsGeneral.vue.js +118 -134
  217. package/package.json +14 -14
@@ -1,9 +1,10 @@
1
- import { defineComponent as m, openBlock as t, createBlock as a, withCtx as l, createElementBlock as n, toDisplayString as s, renderSlot as p, createElementVNode as c, Fragment as i, renderList as u, normalizeClass as f, createVNode as _, createTextVNode as k, createCommentVNode as y } from "vue";
2
- import V from "../DataTable/DataTable.vue.js";
3
- import h from "../DataTable/DataTableInput.vue.js";
4
- import b from "../DataTable/DataTableRow.vue.js";
5
- import g from "../ViewLayout/ViewLayoutSection.vue.js";
6
- const C = { key: 0 }, N = { class: "custom-scroll flex flex-1 flex-col gap-1.5" }, E = /* @__PURE__ */ m({
1
+ import { defineComponent as u, openBlock as t, createBlock as r, withCtx as a, createElementBlock as i, toDisplayString as m, renderSlot as f, createElementVNode as k, unref as l, Fragment as V, renderList as v, normalizeClass as _, createVNode as y, createTextVNode as b, createCommentVNode as h } from "vue";
2
+ import w from "../DataTable/DataTable.vue.js";
3
+ import E from "../DataTable/DataTableInput.vue.js";
4
+ import g from "../DataTable/DataTableRow.vue.js";
5
+ import C from "../ViewLayout/ViewLayoutSection.vue.js";
6
+ import { useActiveEntities as N } from "../../store/active-entities.js";
7
+ const U = { key: 0 }, B = { class: "custom-scroll flex flex-1 flex-col gap-1.5" }, A = /* @__PURE__ */ u({
7
8
  __name: "Form",
8
9
  props: {
9
10
  title: {},
@@ -11,39 +12,43 @@ const C = { key: 0 }, N = { class: "custom-scroll flex flex-1 flex-col gap-1.5"
11
12
  data: {},
12
13
  onUpdate: { type: Function }
13
14
  },
14
- setup(U) {
15
- return (e, w) => (t(), a(g, null, {
16
- title: l(() => [
17
- e.title ? (t(), n("span", C, s(e.title), 1)) : p(e.$slots, "title", { key: 1 })
15
+ setup(D) {
16
+ const { activeEnvVariables: c, activeEnvironment: d, activeWorkspace: n } = N();
17
+ return (e, F) => (t(), r(C, null, {
18
+ title: a(() => [
19
+ e.title ? (t(), i("span", U, m(e.title), 1)) : f(e.$slots, "title", { key: 1 })
18
20
  ]),
19
- default: l(() => [
20
- c("div", N, [
21
- Object.keys(e.data).length > 0 ? (t(), a(V, {
21
+ default: a(() => [
22
+ k("div", B, [
23
+ Object.keys(e.data).length > 0 && l(n) ? (t(), r(w, {
22
24
  key: 0,
23
25
  columns: [""]
24
26
  }, {
25
- default: l(() => [
26
- (t(!0), n(i, null, u(e.options, (o, r) => (t(), a(b, {
27
- key: r,
28
- class: f({ "border-t": r === 0 })
27
+ default: a(() => [
28
+ (t(!0), i(V, null, v(e.options, (o, s) => (t(), r(g, {
29
+ key: s,
30
+ class: _({ "border-t": s === 0 })
29
31
  }, {
30
- default: l(() => [
31
- _(h, {
32
+ default: a(() => [
33
+ y(E, {
34
+ envVariables: l(c),
35
+ environment: l(d),
32
36
  modelValue: e.data[o.key] ?? "",
33
37
  placeholder: o.placeholder,
34
- "onUpdate:modelValue": (d) => e.onUpdate(o.key, d)
38
+ workspace: l(n),
39
+ "onUpdate:modelValue": (p) => e.onUpdate(o.key, p)
35
40
  }, {
36
- default: l(() => [
37
- k(s(o.label), 1)
41
+ default: a(() => [
42
+ b(m(o.label), 1)
38
43
  ]),
39
44
  _: 2
40
- }, 1032, ["modelValue", "placeholder", "onUpdate:modelValue"])
45
+ }, 1032, ["envVariables", "environment", "modelValue", "placeholder", "workspace", "onUpdate:modelValue"])
41
46
  ]),
42
47
  _: 2
43
48
  }, 1032, ["class"]))), 128))
44
49
  ]),
45
50
  _: 1
46
- })) : y("", !0)
51
+ })) : h("", !0)
47
52
  ])
48
53
  ]),
49
54
  _: 3
@@ -51,5 +56,5 @@ const C = { key: 0 }, N = { class: "custom-scroll flex flex-1 flex-col gap-1.5"
51
56
  }
52
57
  });
53
58
  export {
54
- E as default
59
+ A as default
55
60
  };
@@ -1 +1 @@
1
- {"version":3,"file":"ImportCollectionModal.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ImportCollection/ImportCollectionModal.vue"],"names":[],"mappings":"AA6aA,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;IACrB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAA;IAC1B,SAAS,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,GAAG,IAAI,CAAA;CAC7C,CAAC;;;;;;AA6dF,wBAQG"}
1
+ {"version":3,"file":"ImportCollectionModal.vue.d.ts","sourceRoot":"","sources":["../../../src/components/ImportCollection/ImportCollectionModal.vue"],"names":[],"mappings":"AA+aA,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;IACrB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAA;IAC1B,SAAS,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,GAAG,IAAI,CAAA;CAC7C,CAAC;;;;;;AA6dF,wBAQG"}
@@ -1,31 +1,31 @@
1
1
  import { defineComponent as H, ref as W, computed as a, watch as _, onMounted as K, onUnmounted as G, openBlock as l, createBlock as J, unref as i, withCtx as Q, createElementBlock as d, createCommentVNode as f, createElementVNode as e, normalizeClass as X, Fragment as b, createVNode as m, toDisplayString as Y, createTextVNode as M } from "vue";
2
- import Z from "../CommandPalette/WatchModeToggle.vue.js";
3
- import ee from "./ImportNowButton.vue.js";
4
- import te from "./IntegrationLogo.vue.js";
5
- import oe from "./PrefetchError.vue.js";
6
- import se from "./WorkspaceSelector.vue.js";
7
- import { useUrlPrefetcher as ne } from "./hooks/useUrlPrefetcher.js";
2
+ import { useModal as Z, ScalarModal as ee, ScalarIcon as te } from "@scalar/components";
3
+ import { isLocalUrl as oe } from "@scalar/oas-utils/helpers";
4
+ import { normalize as se } from "@scalar/openapi-parser";
5
+ import { getThemeStyles as ne, themeIds as re } from "@scalar/themes";
6
+ import { useColorMode as ie } from "@scalar/use-hooks/useColorMode";
7
+ import { useRouter as le } from "vue-router";
8
+ import ce from "../CommandPalette/WatchModeToggle.vue.js";
9
+ import { useUrlPrefetcher as ae } from "./hooks/useUrlPrefetcher.js";
10
+ import de from "./ImportNowButton.vue.js";
11
+ import me from "./IntegrationLogo.vue.js";
12
+ import ue from "./PrefetchError.vue.js";
8
13
  import { getOpenApiDocumentVersion as T } from "./utils/getOpenApiDocumentVersion.js";
9
14
  import { isDocument as U } from "./utils/isDocument.js";
10
15
  import { isUrl as A } from "./utils/isUrl.js";
11
- import { useActiveEntities as re } from "../../store/active-entities.js";
12
- import { useModal as ie, ScalarModal as le, ScalarIcon as ce } from "@scalar/components";
13
- import { isLocalUrl as ae } from "@scalar/oas-utils/helpers";
14
- import { normalize as de } from "@scalar/openapi-parser";
15
- import { getThemeStyles as me, themeIds as ue } from "@scalar/themes";
16
- import { useColorMode as fe } from "@scalar/use-hooks/useColorMode";
17
- import { useRouter as pe } from "vue-router";
16
+ import fe from "./WorkspaceSelector.vue.js";
17
+ import { useActiveEntities as pe } from "../../store/active-entities.js";
18
18
  import { useWorkspace as ve } from "../../store/store.js";
19
- const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center px-6 overflow-hidden relative md:px-0" }, ye = {
19
+ const he = ["innerHTML"], xe = { class: "relative flex h-screen flex-col justify-center overflow-hidden px-6 md:px-0" }, ye = {
20
20
  key: 0,
21
- class: "flex justify-center items-center mb-2 p-1"
22
- }, ge = { class: "rounded-xl size-10" }, _e = ["src"], be = {
21
+ class: "mb-2 flex items-center justify-center p-1"
22
+ }, ge = { class: "size-10 rounded-xl" }, _e = ["src"], be = {
23
23
  key: 2,
24
- class: "text-center text-md font-bold mb-2 line-clamp-1"
25
- }, we = { class: "inline-flex flex-col gap-2 items-center z-10 w-full" }, ke = { class: "flex justify-center" }, Ie = { class: "inline-flex py-1 px-4 items-center text-xs font-medium text-c-3" }, Le = {
24
+ class: "text-md mb-2 line-clamp-1 text-center font-bold"
25
+ }, we = { class: "z-10 inline-flex w-full flex-col items-center gap-2" }, ke = { class: "flex justify-center" }, Ie = { class: "text-c-3 inline-flex items-center px-4 py-1 text-xs font-medium" }, Le = {
26
26
  key: 0,
27
- class: "text-sm overflow-hidden mt-5 pt-4 border-t-1/2"
28
- }, Me = { class: "flex items-center justify-center" }, Te = { class: "flex flex-col justify-center items-center pb-8" }, Ue = { class: "text-center flex items-center flex-col" }, Ae = { class: "mb-2 w-10 h-10 border rounded-[10px] flex items-center justify-center" }, Ce = {
27
+ class: "border-t-1/2 mt-5 overflow-hidden pt-4 text-sm"
28
+ }, Me = { class: "flex items-center justify-center" }, Te = { class: "flex flex-col items-center justify-center pb-8" }, Ue = { class: "flex flex-col items-center text-center" }, Ae = { class: "mb-2 flex h-10 w-10 items-center justify-center rounded-[10px] border" }, Ce = {
29
29
  href: "https://scalar.com/download",
30
30
  target: "_blank"
31
31
  }, Je = /* @__PURE__ */ H({
@@ -37,11 +37,11 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
37
37
  },
38
38
  emits: ["importFinished"],
39
39
  setup(C, { emit: P }) {
40
- const s = C, D = P, { activeWorkspace: p } = re(), { workspaceMutators: V, events: j } = ve(), { prefetchResult: n, prefetchUrl: w, resetPrefetchResult: S } = ne(), r = ie(), h = W(!0);
40
+ const s = C, D = P, { activeWorkspace: p } = pe(), { workspaceMutators: V, events: j } = ve(), { prefetchResult: n, prefetchUrl: w, resetPrefetchResult: S } = ae(), r = Z(), h = W(!0);
41
41
  j.hotKeys.on(() => r.hide());
42
42
  const z = a(() => {
43
43
  try {
44
- return de(
44
+ return se(
45
45
  n.content || s.source || ""
46
46
  );
47
47
  } catch {
@@ -52,7 +52,7 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
52
52
  return (t = (o = z.value) == null ? void 0 : o.info) == null ? void 0 : t.title;
53
53
  }), k = a(
54
54
  () => T(n.content || s.source || "")
55
- ), { darkLightMode: O } = fe(), { currentRoute: $ } = pe(), x = a(() => {
55
+ ), { darkLightMode: O } = ie(), { currentRoute: $ } = le(), x = a(() => {
56
56
  try {
57
57
  const o = $.value.query, t = O.value === "dark" ? o.dark_logo : o.light_logo;
58
58
  if (t) return decodeURIComponent(t);
@@ -79,7 +79,7 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
79
79
  o && U(o) && T(o) ? r.show() : r.hide();
80
80
  }
81
81
  );
82
- const E = a(() => !!s.source && A(s.source)), F = a(() => !!s.source && U(s.source)), y = a(() => n.url && ae(n.url)), g = (o) => {
82
+ const E = a(() => !!s.source && A(s.source)), F = a(() => !!s.source && U(s.source)), y = a(() => n.url && oe(n.url)), g = (o) => {
83
83
  document.body.classList.remove("has-no-import-url"), (E.value || F.value) && r.open ? document.body.classList.add("has-import-url") : document.body.classList.remove("has-import-url");
84
84
  }, R = () => {
85
85
  document.body.classList.remove("has-import-url"), document.body.classList.add("has-no-import-url");
@@ -100,18 +100,18 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
100
100
  document.body.classList.remove("has-import-url"), document.body.classList.remove("has-no-import-url");
101
101
  });
102
102
  const I = a(
103
- () => p.value && y.value && s.integration && `<style>${me(s.integration)}</style>`
103
+ () => p.value && y.value && s.integration && `<style>${ne(s.integration)}</style>`
104
104
  );
105
105
  function q() {
106
106
  var c;
107
- const o = (u) => ue.includes(u), t = s.integration && o(s.integration) ? s.integration : "default";
107
+ const o = (u) => re.includes(u), t = s.integration && o(s.integration) ? s.integration : "default";
108
108
  y.value && V.edit(
109
- ((c = p.value) == null ? void 0 : c.uid) ?? "",
109
+ (c = p.value) == null ? void 0 : c.uid,
110
110
  "themeId",
111
111
  t
112
112
  ), D("importFinished");
113
113
  }
114
- return (o, t) => (l(), J(i(le), {
114
+ return (o, t) => (l(), J(i(ee), {
115
115
  size: "full",
116
116
  state: i(r)
117
117
  }, {
@@ -134,29 +134,29 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
134
134
  e("div", { class: "section-flare-item" })
135
135
  ], -1)),
136
136
  e("div", {
137
- class: X(["flex items-center flex-col m-auto px-8 py-8 rounded-xl border-1/2 max-w-[380px] w-full transition-opacity", { "opacity-0": i(n).state === "loading" }])
137
+ class: X(["border-1/2 m-auto flex w-full max-w-[380px] flex-col items-center rounded-xl px-8 py-8 transition-opacity", { "opacity-0": i(n).state === "loading" }])
138
138
  }, [
139
139
  i(n).error && i(n).state === "idle" && !k.value ? (l(), d(b, { key: 0 }, [
140
- t[1] || (t[1] = e("div", { class: "text-center text-md font-bold mb-2 line-clamp-1" }, " No OpenAPI document found ", -1)),
141
- m(oe, {
140
+ t[1] || (t[1] = e("div", { class: "text-md mb-2 line-clamp-1 text-center font-bold" }, " No OpenAPI document found ", -1)),
141
+ m(ue, {
142
142
  url: ((c = i(n)) == null ? void 0 : c.input) || s.source
143
143
  }, null, 8, ["url"])
144
144
  ], 64)) : (l(), d(b, { key: 1 }, [
145
145
  y.value ? (l(), d("div", ye, [
146
146
  e("div", ge, [
147
- m(te, { integration: o.integration }, null, 8, ["integration"])
147
+ m(me, { integration: o.integration }, null, 8, ["integration"])
148
148
  ])
149
149
  ])) : x.value ? (l(), d("img", {
150
150
  key: 1,
151
151
  alt: "Logo",
152
- class: "w-full object-contain mb-2",
152
+ class: "mb-2 w-full object-contain",
153
153
  src: x.value
154
154
  }, null, 8, _e)) : f("", !0),
155
155
  x.value ? f("", !0) : (l(), d("div", be, Y(N.value || "Untitled Collection"), 1)),
156
- t[4] || (t[4] = e("div", { class: "text-c-1 text-sm font-medium text-center text-balance" }, " Import the OpenAPI document to instantly send API requests. No signup required. ", -1)),
156
+ t[4] || (t[4] = e("div", { class: "text-c-1 text-balance text-center text-sm font-medium" }, " Import the OpenAPI document to instantly send API requests. No signup required. ", -1)),
157
157
  k.value ? (l(), d(b, { key: 3 }, [
158
158
  e("div", we, [
159
- m(ee, {
159
+ m(de, {
160
160
  source: ((u = i(n)) == null ? void 0 : u.url) ?? ((v = i(n)) == null ? void 0 : v.content) ?? o.source,
161
161
  variant: "button",
162
162
  watchMode: h.value,
@@ -166,18 +166,18 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
166
166
  e("div", ke, [
167
167
  e("div", Ie, [
168
168
  t[2] || (t[2] = M(" Import to: ")),
169
- m(se)
169
+ m(fe)
170
170
  ])
171
171
  ]),
172
172
  (L = i(n)) != null && L.url ? (l(), d("div", Le, [
173
173
  e("div", Me, [
174
- m(Z, {
174
+ m(ce, {
175
175
  modelValue: h.value,
176
176
  "onUpdate:modelValue": t[0] || (t[0] = (B) => h.value = B),
177
177
  disableToolTip: !0
178
178
  }, null, 8, ["modelValue"])
179
179
  ]),
180
- t[3] || (t[3] = e("div", { class: "pt-0 text-center text-balance font-medium text-xs text-c-3" }, " Automatically update your API client when the OpenAPI document content changes. ", -1))
180
+ t[3] || (t[3] = e("div", { class: "text-c-3 text-balance pt-0 text-center text-xs font-medium" }, " Automatically update your API client when the OpenAPI document content changes. ", -1))
181
181
  ])) : f("", !0)
182
182
  ], 64)) : f("", !0)
183
183
  ], 64))
@@ -186,15 +186,15 @@ const he = ["innerHTML"], xe = { class: "flex flex-col h-screen justify-center p
186
186
  e("div", Ue, [
187
187
  e("div", Ae, [
188
188
  e("a", Ce, [
189
- m(i(ce), {
189
+ m(i(te), {
190
190
  icon: "Logo",
191
191
  size: "xl"
192
192
  })
193
193
  ])
194
194
  ]),
195
- t[5] || (t[5] = e("span", { class: "text-c-2 leading-snug text-sm font-medium" }, [
195
+ t[5] || (t[5] = e("span", { class: "text-c-2 text-sm font-medium leading-snug" }, [
196
196
  e("a", {
197
- class: "hover:text-c-1 underline-offset-2 mb-1 inline-block",
197
+ class: "hover:text-c-1 mb-1 inline-block underline-offset-2",
198
198
  href: "https://scalar.com/download",
199
199
  target: "_blank"
200
200
  }, " Download Desktop App "),
@@ -1,4 +1,4 @@
1
- import { defineComponent as b, openBlock as n, createElementBlock as g, Fragment as B, createBlock as c, unref as l, withCtx as f, createTextVNode as d, createCommentVNode as F } from "vue";
1
+ import { defineComponent as b, openBlock as i, createElementBlock as g, Fragment as B, createBlock as c, unref as l, withCtx as f, createTextVNode as d, createCommentVNode as F } from "vue";
2
2
  import { isUrl as I } from "./utils/isUrl.js";
3
3
  import { useActiveEntities as U } from "../../store/active-entities.js";
4
4
  import { ScalarButton as y } from "@scalar/components";
@@ -14,59 +14,59 @@ const _ = /* @__PURE__ */ b({
14
14
  },
15
15
  emits: ["importFinished"],
16
16
  setup(k, { emit: w }) {
17
- const r = k, h = w, v = M(), { activeWorkspace: s } = U(), { importSpecFromUrl: C, importSpecFile: x } = T(), { toast: u } = q();
17
+ const r = k, h = w, v = M(), { activeWorkspace: n } = U(), { importSpecFromUrl: C, importSpecFile: x } = T(), { toast: u } = q();
18
18
  async function a() {
19
- var t, e, m;
19
+ var o, t, m;
20
20
  try {
21
21
  if (r.source) {
22
22
  if (I(r.source)) {
23
- const [o, i] = await C(
23
+ const [e, s] = await C(
24
24
  r.source,
25
- ((t = s.value) == null ? void 0 : t.uid) ?? "",
25
+ ((o = n.value) == null ? void 0 : o.uid) ?? "",
26
26
  {
27
- proxyUrl: (e = s.value) == null ? void 0 : e.proxyUrl,
27
+ proxyUrl: (t = n.value) == null ? void 0 : t.proxyUrl,
28
28
  watchMode: r.watchMode
29
29
  }
30
30
  );
31
- o || p(i);
31
+ e || p(s == null ? void 0 : s.collection);
32
32
  } else {
33
- const o = await x(
33
+ const e = await x(
34
34
  r.source,
35
- ((m = s.value) == null ? void 0 : m.uid) ?? ""
35
+ ((m = n.value) == null ? void 0 : m.uid) ?? ""
36
36
  );
37
- p(o);
37
+ p(e == null ? void 0 : e.collection);
38
38
  }
39
39
  u("Import successful", "info"), h("importFinished");
40
40
  }
41
- } catch (o) {
42
- console.error("[importCollection]", o);
43
- const i = (o == null ? void 0 : o.message) || "Unknown error";
44
- u(`Import failed: ${i}`, "error");
41
+ } catch (e) {
42
+ console.error("[importCollection]", e);
43
+ const s = (e == null ? void 0 : e.message) || "Unknown error";
44
+ u(`Import failed: ${s}`, "error");
45
45
  }
46
46
  }
47
- function p(t) {
48
- var e;
49
- t && v.push({
47
+ function p(o) {
48
+ var t;
49
+ o && v.push({
50
50
  name: "request",
51
51
  params: {
52
- workspace: (e = s.value) == null ? void 0 : e.uid,
53
- request: t == null ? void 0 : t.requests[0]
52
+ workspace: (t = n.value) == null ? void 0 : t.uid,
53
+ request: o == null ? void 0 : o.requests[0]
54
54
  }
55
55
  });
56
56
  }
57
- return (t, e) => t.source ? (n(), g(B, { key: 0 }, [
58
- t.variant === "button" ? (n(), c(l(y), {
57
+ return (o, t) => o.source ? (i(), g(B, { key: 0 }, [
58
+ o.variant === "button" ? (i(), c(l(y), {
59
59
  key: 0,
60
60
  class: "py-2.5 px-6 rounded-lg font-bold h-fit mt-3 w-full",
61
61
  size: "md",
62
62
  type: "button",
63
63
  onClick: a
64
64
  }, {
65
- default: f(() => e[0] || (e[0] = [
65
+ default: f(() => t[0] || (t[0] = [
66
66
  d(" Import Collection ")
67
67
  ])),
68
68
  _: 1
69
- })) : (n(), c(l(y), {
69
+ })) : (i(), c(l(y), {
70
70
  key: 1,
71
71
  class: "text-[21px] py-2.5 px-6 rounded-lg font-bold h-fit",
72
72
  size: "md",
@@ -74,7 +74,7 @@ const _ = /* @__PURE__ */ b({
74
74
  variant: "ghost",
75
75
  onClick: a
76
76
  }, {
77
- default: f(() => e[1] || (e[1] = [
77
+ default: f(() => t[1] || (t[1] = [
78
78
  d(" Try it in the browser ")
79
79
  ])),
80
80
  _: 1
@@ -1 +1 @@
1
- {"version":3,"file":"ScreenReader.vue.d.ts","sourceRoot":"","sources":["../../src/components/ScreenReader.vue"],"names":[],"mappings":"AAmCA,KAAK,WAAW,GAAG;IAEf,EAAE,CAAC,EAAE,OAAO,CAAA;CACb,CAAC;AAgBJ,iBAAS,cAAc;WA6CT,OAAO,IAA6B;;yBATrB,GAAG;yBACH,GAAG;;;;EAa/B;AASD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;QA7EZ,OAAO;6EAoFd,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAepG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"ScreenReader.vue.d.ts","sourceRoot":"","sources":["../../src/components/ScreenReader.vue"],"names":[],"mappings":"AAkCA,KAAK,WAAW,GAAG;IACf,EAAE,CAAC,EAAE,OAAO,CAAA;CACb,CAAC;AAgBJ,iBAAS,cAAc;WA6CT,OAAO,IAA6B;;yBATrB,GAAG;yBACH,GAAG;;;;EAa/B;AASD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;QA7EZ,OAAO;6EAoFd,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAepG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ServerDropdown.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Server/ServerDropdown.vue"],"names":[],"mappings":"AA+LA,OAAO,KAAK,EACV,UAAU,EACV,OAAO,IAAI,SAAS,EACpB,MAAM,EACP,MAAM,iCAAiC,CAAA;AAOxC,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE,UAAU,CAAA;IACtB,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,MAAM,EAAE,QAAQ,GAAG,WAAW,CAAA;IAC9B,qEAAqE;IACrE,MAAM,EAAE,MAAM,CAAA;CACf,CAAC;;AAuRF,wBAOG"}
1
+ {"version":3,"file":"ServerDropdown.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Server/ServerDropdown.vue"],"names":[],"mappings":"AA8LA,OAAO,KAAK,EACV,UAAU,EACV,OAAO,IAAI,SAAS,EACpB,MAAM,EACP,MAAM,iCAAiC,CAAA;AAUxC,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE,UAAU,CAAA;IACtB,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,MAAM,EAAE,QAAQ,GAAG,WAAW,CAAA;IAC9B,qEAAqE;IACrE,MAAM,EAAE,MAAM,CAAA;CACf,CAAC;;AAuRF,wBAOG"}
@@ -1,9 +1,9 @@
1
1
  import { defineComponent as L, computed as i, watch as W, openBlock as n, createBlock as c, unref as a, withCtx as u, createElementVNode as s, normalizeClass as h, createElementBlock as d, Fragment as m, renderList as k, createVNode as v, createCommentVNode as f, createTextVNode as j, toDisplayString as q } from "vue";
2
- import { useLayout as E } from "../../hooks/useLayout.js";
3
- import { useWorkspace as F } from "../../store/store.js";
4
- import { cva as I, ScalarPopover as M, ScalarDropdownDivider as P, ScalarIcon as x, ScalarFloatingBackdrop as T, ScalarButton as $, cx as G } from "@scalar/components";
2
+ import { cva as E, ScalarPopover as F, ScalarDropdownDivider as I, ScalarIcon as x, ScalarFloatingBackdrop as M, ScalarButton as P, cx as T } from "@scalar/components";
3
+ import { useLayout as $ } from "../../hooks/useLayout.js";
4
+ import { useWorkspace as G } from "../../store/store.js";
5
5
  import w from "./ServerDropdownItem.vue.js";
6
- const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }, Z = /* @__PURE__ */ L({
6
+ const H = ["onClick"], J = { class: "flex h-4 w-4 items-center justify-center" }, Z = /* @__PURE__ */ L({
7
7
  __name: "ServerDropdown",
8
8
  props: {
9
9
  collection: {},
@@ -13,7 +13,7 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
13
13
  target: {}
14
14
  },
15
15
  setup(l) {
16
- const { layout: C } = E(), { servers: p, collectionMutators: D, events: U, serverMutators: V } = F(), y = i(
16
+ const { layout: C } = $(), { servers: p, collectionMutators: D, events: U, serverMutators: V } = G(), y = i(
17
17
  () => {
18
18
  var e, r;
19
19
  return (r = (e = l.operation) == null ? void 0 : e.servers) == null ? void 0 : r.map((t) => {
@@ -63,7 +63,7 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
63
63
  if (!l.server) return;
64
64
  const t = l.server.variables || {};
65
65
  t[e] = { ...t[e], default: r }, V.edit(l.server.uid, "variables", t);
66
- }, A = I({
66
+ }, A = E({
67
67
  base: "gap-0.75 z-context-plus lg:text-sm text-xs whitespace-nowrap px-1.5 h-6.5",
68
68
  variants: {
69
69
  reference: {
@@ -72,7 +72,7 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
72
72
  }
73
73
  }
74
74
  });
75
- return (e, r) => (n(), c(a(M), {
75
+ return (e, r) => (n(), c(a(F), {
76
76
  class: "max-h-[inherit] p-0 text-sm",
77
77
  offset: e.layout === "reference" ? 6 : 0,
78
78
  placement: "bottom-start",
@@ -82,7 +82,7 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
82
82
  }, {
83
83
  popover: u(({ close: t }) => [
84
84
  s("div", {
85
- class: h(["custom-scroll flex p-1 flex-col gap-1 max-h-[inherit]", e.layout !== "reference" && "border-t"]),
85
+ class: h(["custom-scroll flex max-h-[inherit] flex-col gap-1 p-1", e.layout !== "reference" && "border-t"]),
86
86
  onClick: t
87
87
  }, [
88
88
  (n(!0), d(m, null, k(y.value, (o) => (n(), c(w, {
@@ -96,7 +96,7 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
96
96
  "onUpdate:variable": g
97
97
  }, null, 8, ["collection", "layout", "operation", "server", "serverOption"]))), 128)),
98
98
  z.value ? (n(), d(m, { key: 0 }, [
99
- v(a(P)),
99
+ v(a(I)),
100
100
  r[1] || (r[1] = s("div", { class: "text-xxs text-c-2 px-2.5 py-1" }, "Collection", -1))
101
101
  ], 64)) : f("", !0),
102
102
  (n(!0), d(m, null, k(b.value, (o) => (n(), c(w, {
@@ -111,7 +111,7 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
111
111
  }, null, 8, ["collection", "layout", "operation", "server", "serverOption"]))), 128)),
112
112
  a(C) !== "modal" ? (n(), d("button", {
113
113
  key: 1,
114
- class: "rounded text-xxs flex items-center gap-1.5 p-1.75 hover:bg-b-2 cursor-pointer",
114
+ class: "text-xxs p-1.75 hover:bg-b-2 flex cursor-pointer items-center gap-1.5 rounded",
115
115
  type: "button",
116
116
  onClick: B
117
117
  }, [
@@ -126,11 +126,11 @@ const H = ["onClick"], J = { class: "flex items-center justify-center h-4 w-4" }
126
126
  ], 10, H)
127
127
  ]),
128
128
  backdrop: u(() => [
129
- v(a(T), { class: "-top-[--scalar-address-bar-height] rounded-lg" })
129
+ v(a(M), { class: "-top-[--scalar-address-bar-height] rounded-lg" })
130
130
  ]),
131
131
  default: u(() => [
132
- v(a($), {
133
- class: h(a(G)(a(A)({ reference: e.layout === "reference" }))),
132
+ v(a(P), {
133
+ class: h(a(T)(a(A)({ reference: e.layout === "reference" }))),
134
134
  variant: "ghost"
135
135
  }, {
136
136
  default: u(() => [
@@ -4,7 +4,7 @@ type __VLS_Props = {
4
4
  operation: Operation | undefined;
5
5
  server: Server | undefined;
6
6
  serverOption: {
7
- id: string;
7
+ id: Server['uid'];
8
8
  label: string;
9
9
  };
10
10
  type: 'collection' | 'request';
@@ -1 +1 @@
1
- {"version":3,"file":"ServerDropdownItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Server/ServerDropdownItem.vue"],"names":[],"mappings":"AA0HA,OAAO,KAAK,EACV,UAAU,EACV,OAAO,IAAI,SAAS,EACpB,MAAM,EACP,MAAM,iCAAiC,CAAA;AAKxC,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE,UAAU,CAAA;IACtB,SAAS,EAAE,SAAS,GAAG,SAAS,CAAA;IAChC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,YAAY,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAA;IAC3C,IAAI,EAAE,YAAY,GAAG,SAAS,CAAA;IAC9B,MAAM,EAAE,QAAQ,GAAG,WAAW,CAAA;CAC/B,CAAC;;;;;;AAgMF,wBAQG"}
1
+ {"version":3,"file":"ServerDropdownItem.vue.d.ts","sourceRoot":"","sources":["../../../src/components/Server/ServerDropdownItem.vue"],"names":[],"mappings":"AA4HA,OAAO,KAAK,EACV,UAAU,EACV,OAAO,IAAI,SAAS,EACpB,MAAM,EACP,MAAM,iCAAiC,CAAA;AAQxC,KAAK,WAAW,GAAG;IACjB,UAAU,EAAE,UAAU,CAAA;IACtB,SAAS,EAAE,SAAS,GAAG,SAAS,CAAA;IAChC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,YAAY,EAAE;QACZ,EAAE,EAAE,MAAM,CAAC,KAAK,CAAC,CAAA;QACjB,KAAK,EAAE,MAAM,CAAA;KACd,CAAA;IACD,IAAI,EAAE,YAAY,GAAG,SAAS,CAAA;IAC9B,MAAM,EAAE,QAAQ,GAAG,WAAW,CAAA;CAC/B,CAAC;;;;;;AAgMF,wBAQG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./ServerDropdownItem.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ r(o, [["__scopeId", "data-v-fe4c1651"]]);
4
+ const p = /* @__PURE__ */ r(o, [["__scopeId", "data-v-8eba7808"]]);
5
5
  export {
6
6
  p as default
7
7
  };
@@ -1,8 +1,8 @@
1
- import { defineComponent as C, useId as O, computed as b, openBlock as l, createElementBlock as d, normalizeClass as V, createElementVNode as c, mergeProps as M, unref as a, createVNode as p, toDisplayString as E, withModifiers as I, createCommentVNode as f } from "vue";
2
- import N from "./ServerVariablesForm.vue.js";
3
- import { useWorkspace as q } from "../../store/store.js";
4
- import { ScalarListboxCheckbox as B, ScalarMarkdown as D } from "@scalar/components";
5
- const P = ["aria-expanded"], j = { class: "whitespace-nowrap text-ellipsis overflow-hidden" }, z = ["id"], L = { key: 0 }, U = { class: "description px-3 py-1.5 text-c-3" }, G = /* @__PURE__ */ C({
1
+ import { defineComponent as C, useId as O, computed as b, openBlock as n, createElementBlock as d, normalizeClass as V, createElementVNode as c, mergeProps as M, unref as a, createVNode as p, toDisplayString as E, withModifiers as I, createCommentVNode as f } from "vue";
2
+ import { ScalarListboxCheckbox as N, ScalarMarkdown as q } from "@scalar/components";
3
+ import B from "./ServerVariablesForm.vue.js";
4
+ import { useWorkspace as D } from "../../store/store.js";
5
+ const P = ["aria-expanded"], j = { class: "overflow-hidden text-ellipsis whitespace-nowrap" }, z = ["id"], L = { key: 0 }, U = { class: "description text-c-3 px-3 py-1.5" }, G = /* @__PURE__ */ C({
6
6
  __name: "ServerDropdownItem",
7
7
  props: {
8
8
  collection: {},
@@ -14,9 +14,9 @@ const P = ["aria-expanded"], j = { class: "whitespace-nowrap text-ellipsis overf
14
14
  },
15
15
  emits: ["update:variable"],
16
16
  setup(y, { emit: h }) {
17
- const t = y, S = h, u = O(), { collectionMutators: g, requestMutators: v, servers: k } = q(), x = (e, r) => {
17
+ const t = y, S = h, u = O(), { collectionMutators: g, requestMutators: v, servers: k } = D(), x = (e, r) => {
18
18
  var o, i;
19
- m(e) && t.layout !== "reference" && (r == null || r.stopPropagation()), t.type === "collection" && t.collection ? ((i = (o = t.operation) == null ? void 0 : o.servers) != null && i.length && v.edit(t.operation.uid, "selectedServerUid", ""), g.edit(
19
+ m(e) && t.layout !== "reference" && (r == null || r.stopPropagation()), t.type === "collection" && t.collection ? ((i = (o = t.operation) == null ? void 0 : o.servers) != null && i.length && v.edit(t.operation.uid, "selectedServerUid", null), g.edit(
20
20
  t.collection.uid,
21
21
  "selectedServerUid",
22
22
  e
@@ -30,7 +30,7 @@ const P = ["aria-expanded"], j = { class: "whitespace-nowrap text-ellipsis overf
30
30
  if (!e) return !1;
31
31
  const r = k[e];
32
32
  return Object.keys((r == null ? void 0 : r.variables) ?? {}).length > 0;
33
- }, n = b(
33
+ }, l = b(
34
34
  () => {
35
35
  var e;
36
36
  return s.value && m(((e = t.server) == null ? void 0 : e.uid) ?? "");
@@ -40,32 +40,32 @@ const P = ["aria-expanded"], j = { class: "whitespace-nowrap text-ellipsis overf
40
40
  };
41
41
  return (e, r) => {
42
42
  var o, i;
43
- return l(), d("div", {
44
- class: V(["min-h-fit rounded flex flex-col border group/item", { "border-transparent": !s.value }])
43
+ return n(), d("div", {
44
+ class: V(["group/item flex min-h-fit flex-col rounded border", { "border-transparent": !s.value }])
45
45
  }, [
46
- c("button", M(n.value ? { "aria-controls": a(u) } : {}, {
47
- "aria-expanded": n.value,
48
- class: ["cursor-pointer rounded flex items-center gap-1.5 min-h-8 px-1.5", s.value ? "text-c-1 bg-b-2" : "hover:bg-b-2"],
46
+ c("button", M(l.value ? { "aria-controls": a(u) } : {}, {
47
+ "aria-expanded": l.value,
48
+ class: ["flex min-h-8 cursor-pointer items-center gap-1.5 rounded px-1.5", s.value ? "text-c-1 bg-b-2" : "hover:bg-b-2"],
49
49
  type: "button",
50
50
  onClick: r[0] || (r[0] = (w) => x(e.serverOption.id, w))
51
51
  }), [
52
- p(a(B), { selected: s.value }, null, 8, ["selected"]),
52
+ p(a(N), { selected: s.value }, null, 8, ["selected"]),
53
53
  c("span", j, E(e.serverOption.label), 1)
54
54
  ], 16, P),
55
- n.value && t.layout !== "reference" ? (l(), d("div", {
55
+ l.value && t.layout !== "reference" ? (n(), d("div", {
56
56
  key: 0,
57
57
  id: a(u),
58
- class: "bg-b-2 border-t divide divide-y *:pl-4 rounded-b",
58
+ class: "bg-b-2 divide divide-y rounded-b border-t *:pl-4",
59
59
  onClick: r[1] || (r[1] = I(() => {
60
60
  }, ["stop"]))
61
61
  }, [
62
- p(N, {
62
+ p(B, {
63
63
  variables: (o = e.server) == null ? void 0 : o.variables,
64
64
  "onUpdate:variable": _
65
65
  }, null, 8, ["variables"]),
66
- (i = e.server) != null && i.description ? (l(), d("div", L, [
66
+ (i = e.server) != null && i.description ? (n(), d("div", L, [
67
67
  c("div", U, [
68
- p(a(D), {
68
+ p(a(q), {
69
69
  value: e.server.description
70
70
  }, null, 8, ["value"])
71
71
  ])