@scalar/api-client 2.26.2 → 2.29.1

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 (164) hide show
  1. package/CHANGELOG.md +218 -0
  2. package/dist/components/Server/ServerSelector.vue.js +6 -6
  3. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +6 -6
  4. package/dist/components/ViewLayout/ViewLayoutSection.vue.d.ts.map +1 -1
  5. package/dist/components/ViewLayout/ViewLayoutSection.vue.js +1 -1
  6. package/dist/libs/local-storage.js +3 -3
  7. package/dist/style.css +1 -1
  8. package/dist/v2/blocks/operation-block/helpers/build-request-body.d.ts.map +1 -1
  9. package/dist/v2/blocks/operation-block/helpers/build-request-body.js +29 -25
  10. package/dist/v2/blocks/operation-block/helpers/get-example.d.ts.map +1 -1
  11. package/dist/v2/blocks/operation-block/helpers/get-example.js +15 -15
  12. package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.d.ts +10 -0
  13. package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.d.ts.map +1 -0
  14. package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.js +4 -0
  15. package/dist/v2/blocks/request-block/RequestBlock.vue.js +1 -1
  16. package/dist/v2/blocks/request-block/RequestBlock.vue2.js +26 -26
  17. package/dist/v2/blocks/request-block/components/RequestBody.vue.d.ts.map +1 -1
  18. package/dist/v2/blocks/request-block/components/RequestBody.vue.js +2 -2
  19. package/dist/v2/blocks/request-block/components/RequestBody.vue2.js +88 -103
  20. package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts +2 -0
  21. package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts.map +1 -1
  22. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts +2 -0
  23. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts.map +1 -1
  24. package/dist/v2/blocks/request-block/helpers/get-default-headers.d.ts +1 -1
  25. package/dist/v2/blocks/request-block/helpers/get-default-headers.d.ts.map +1 -1
  26. package/dist/v2/blocks/request-block/helpers/get-default-headers.js +20 -19
  27. package/dist/v2/blocks/response-block/ResponseBlock.vue.js +1 -1
  28. package/dist/v2/blocks/response-block/ResponseBlock.vue2.js +7 -7
  29. package/dist/v2/blocks/response-block/components/ResponseEmpty.vue.d.ts.map +1 -1
  30. package/dist/v2/blocks/response-block/components/ResponseEmpty.vue.js +1 -1
  31. package/dist/v2/blocks/response-block/components/ResponseEmpty.vue2.js +31 -40
  32. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts +2 -0
  33. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts.map +1 -1
  34. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.js +52 -54
  35. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts +3 -2
  36. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts.map +1 -1
  37. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +106 -86
  38. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.d.ts +21 -0
  39. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.d.ts.map +1 -0
  40. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.js +91 -0
  41. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue2.js +4 -0
  42. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts.map +1 -1
  43. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.js +107 -93
  44. package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.d.ts.map +1 -1
  45. package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.js +87 -65
  46. package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.d.ts +36 -0
  47. package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.d.ts.map +1 -0
  48. package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.js +35 -0
  49. package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.d.ts +1 -1
  50. package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.d.ts.map +1 -1
  51. package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.js +18 -10
  52. package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.d.ts +5 -0
  53. package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.d.ts.map +1 -0
  54. package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.js +27 -0
  55. package/dist/v2/blocks/scalar-auth-selector-block/helpers/secret-types.d.ts +3 -1
  56. package/dist/v2/blocks/scalar-auth-selector-block/helpers/secret-types.d.ts.map +1 -1
  57. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts +4 -3
  58. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts.map +1 -1
  59. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.js +32 -40
  60. package/dist/v2/components/code-input/CodeInput.vue.d.ts.map +1 -1
  61. package/dist/v2/components/code-input/CodeInput.vue.js +2 -2
  62. package/dist/v2/components/layout/CollapsibleSection.vue.js +1 -1
  63. package/dist/v2/components/sidebar/Sidebar.vue.d.ts +2 -0
  64. package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  65. package/dist/v2/components/sidebar/Sidebar.vue.js +25 -24
  66. package/dist/v2/components/sidebar/SidebarMenu.vue.d.ts +2 -0
  67. package/dist/v2/components/sidebar/SidebarMenu.vue.d.ts.map +1 -1
  68. package/dist/v2/components/sidebar/SidebarMenu.vue.js +30 -30
  69. package/dist/v2/features/app/App.vue.d.ts +5 -0
  70. package/dist/v2/features/app/App.vue.d.ts.map +1 -1
  71. package/dist/v2/features/app/App.vue.js +80 -78
  72. package/dist/v2/features/app/app-events.d.ts +2 -1
  73. package/dist/v2/features/app/app-events.d.ts.map +1 -1
  74. package/dist/v2/features/app/app-events.js +89 -64
  75. package/dist/v2/features/app/app-state.d.ts.map +1 -1
  76. package/dist/v2/features/app/app-state.js +172 -151
  77. package/dist/v2/features/app/components/AppSidebar.vue.d.ts.map +1 -1
  78. package/dist/v2/features/app/components/AppSidebar.vue.js +3 -3
  79. package/dist/v2/features/app/components/AppSidebar.vue2.js +99 -97
  80. package/dist/v2/features/app/components/DesktopTabs.vue.d.ts.map +1 -1
  81. package/dist/v2/features/app/components/DesktopTabs.vue.js +4 -4
  82. package/dist/v2/features/app/components/DownloadAppButton.vue.d.ts.map +1 -1
  83. package/dist/v2/features/app/components/DownloadAppButton.vue.js +1 -1
  84. package/dist/v2/features/app/components/DownloadAppButton.vue2.js +9 -9
  85. package/dist/v2/features/app/components/SidebarItemMenu.vue.d.ts.map +1 -1
  86. package/dist/v2/features/app/components/SidebarItemMenu.vue.js +71 -43
  87. package/dist/v2/features/app/helpers/create-api-client-app.d.ts +11 -1
  88. package/dist/v2/features/app/helpers/create-api-client-app.d.ts.map +1 -1
  89. package/dist/v2/features/app/helpers/create-api-client-app.js +12 -10
  90. package/dist/v2/features/app/helpers/routes.d.ts +2 -0
  91. package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
  92. package/dist/v2/features/app/helpers/routes.js +11 -11
  93. package/dist/v2/features/app/hooks/use-theme.d.ts +42 -0
  94. package/dist/v2/features/app/hooks/use-theme.d.ts.map +1 -0
  95. package/dist/v2/features/app/hooks/use-theme.js +34 -0
  96. package/dist/v2/features/collection/DocumentCollection.vue.d.ts.map +1 -1
  97. package/dist/v2/features/collection/DocumentCollection.vue.js +27 -26
  98. package/dist/v2/features/collection/WorkspaceCollection.vue.d.ts +1 -6
  99. package/dist/v2/features/collection/WorkspaceCollection.vue.d.ts.map +1 -1
  100. package/dist/v2/features/collection/WorkspaceCollection.vue.js +41 -22
  101. package/dist/v2/features/collection/components/Authentication.vue.d.ts.map +1 -1
  102. package/dist/v2/features/collection/components/Authentication.vue.js +2 -2
  103. package/dist/v2/features/collection/components/Authentication.vue2.js +49 -40
  104. package/dist/v2/features/collection/components/Cookies.vue.d.ts.map +1 -1
  105. package/dist/v2/features/collection/components/Cookies.vue.js +26 -13
  106. package/dist/v2/features/collection/components/Environment.vue.d.ts.map +1 -1
  107. package/dist/v2/features/collection/components/Environment.vue.js +27 -15
  108. package/dist/v2/features/collection/components/LabelInput.vue.d.ts +3 -0
  109. package/dist/v2/features/collection/components/LabelInput.vue.d.ts.map +1 -1
  110. package/dist/v2/features/collection/components/LabelInput.vue.js +2 -2
  111. package/dist/v2/features/collection/components/LabelInput.vue2.js +20 -16
  112. package/dist/v2/features/collection/components/Overview.vue.d.ts.map +1 -1
  113. package/dist/v2/features/collection/components/Overview.vue.js +2 -2
  114. package/dist/v2/features/collection/components/Overview.vue2.js +68 -61
  115. package/dist/v2/features/collection/components/Servers.vue.d.ts.map +1 -1
  116. package/dist/v2/features/collection/components/Servers.vue.js +93 -88
  117. package/dist/v2/features/collection/components/Settings.vue.d.ts.map +1 -1
  118. package/dist/v2/features/collection/components/Settings.vue.js +19 -17
  119. package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.d.ts +7 -2
  120. package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.d.ts.map +1 -1
  121. package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.js +70 -71
  122. package/dist/v2/features/command-palette/components/{CommandPaletteDocument.vue.d.ts → CommandPaletteOpenApiDocument.vue.d.ts} +3 -3
  123. package/dist/v2/features/command-palette/components/CommandPaletteOpenApiDocument.vue.d.ts.map +1 -0
  124. package/dist/v2/features/command-palette/components/{CommandPaletteDocument.vue.js → CommandPaletteOpenApiDocument.vue.js} +15 -15
  125. package/dist/v2/features/command-palette/components/CommandPaletteOpenApiDocument.vue2.js +4 -0
  126. package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.d.ts +2 -2
  127. package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.d.ts.map +1 -1
  128. package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.js +10 -10
  129. package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.d.ts +27 -5
  130. package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.d.ts.map +1 -1
  131. package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.js +80 -53
  132. package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts +34 -9
  133. package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts.map +1 -1
  134. package/dist/v2/features/command-palette/hooks/use-command-palette-state.js +50 -44
  135. package/dist/v2/features/environments/EnvironmentsList.vue.js +1 -1
  136. package/dist/v2/features/global-cookies/components/CookiesTable.vue.d.ts.map +1 -1
  137. package/dist/v2/features/global-cookies/components/CookiesTable.vue.js +2 -2
  138. package/dist/v2/features/global-cookies/components/CookiesTable.vue2.js +8 -8
  139. package/dist/v2/features/modal/Modal.vue.d.ts.map +1 -1
  140. package/dist/v2/features/modal/Modal.vue.js +15 -15
  141. package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
  142. package/dist/v2/features/operation/Operation.vue.js +30 -33
  143. package/dist/v2/features/settings/CollectionSettings.vue.d.ts +10 -7
  144. package/dist/v2/features/settings/CollectionSettings.vue.d.ts.map +1 -1
  145. package/dist/v2/features/settings/CollectionSettings.vue.js +183 -149
  146. package/dist/v2/features/settings/DocumentSettings.vue.d.ts.map +1 -1
  147. package/dist/v2/features/settings/DocumentSettings.vue.js +88 -79
  148. package/dist/v2/features/settings/components/Section.vue.d.ts +2 -1
  149. package/dist/v2/features/settings/components/Section.vue.d.ts.map +1 -1
  150. package/dist/v2/features/settings/components/Section.vue.js +26 -15
  151. package/dist/v2/features/settings/helpers/get-theme-colors.d.ts +4 -3
  152. package/dist/v2/features/settings/helpers/get-theme-colors.d.ts.map +1 -1
  153. package/dist/v2/features/settings/helpers/get-theme-colors.js +6 -7
  154. package/dist/v2/helpers/handle-hotkeys.d.ts.map +1 -1
  155. package/dist/v2/helpers/handle-hotkeys.js +2 -2
  156. package/dist/v2/hooks/use-global-hot-keys.d.ts +3 -1
  157. package/dist/v2/hooks/use-global-hot-keys.d.ts.map +1 -1
  158. package/dist/v2/hooks/use-global-hot-keys.js +8 -6
  159. package/dist/v2/workspace-events.d.ts.map +1 -1
  160. package/dist/v2/workspace-events.js +132 -115
  161. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  162. package/package.json +17 -16
  163. package/dist/v2/features/command-palette/components/CommandPaletteDocument.vue.d.ts.map +0 -1
  164. package/dist/v2/features/command-palette/components/CommandPaletteDocument.vue2.js +0 -4
@@ -1,13 +1,14 @@
1
- import { defineComponent as L, mergeModels as I, computed as k, capitalize as R, useModel as W, ref as V, createElementBlock as c, openBlock as u, createVNode as d, createBlock as x, createCommentVNode as p, unref as i, createSlots as j, withCtx as r, createTextVNode as b, createElementVNode as l, withKeys as w, withModifiers as v, toDisplayString as F, renderSlot as G, normalizeClass as H, Fragment as h, nextTick as U } from "vue";
2
- import { useModal as J, ScalarSidebarItem as O, ScalarIconButton as Y, ScalarButton as $, ScalarModal as Q } from "@scalar/components";
1
+ import { defineComponent as L, mergeModels as W, computed as k, capitalize as R, useModel as h, ref as V, createElementBlock as p, openBlock as u, createVNode as d, createBlock as w, createCommentVNode as m, unref as i, createSlots as j, withCtx as r, createTextVNode as b, createElementVNode as l, withKeys as g, withModifiers as v, toDisplayString as F, renderSlot as G, normalizeClass as H, Fragment as I, nextTick as U } from "vue";
2
+ import { useModal as J, ScalarSidebarItem as $, ScalarIconButton as Y, ScalarButton as E, ScalarModal as Q } from "@scalar/components";
3
3
  import { isMacOS as X } from "@scalar/helpers/general/is-mac-os";
4
- import { ScalarIconPlus as Z, ScalarIconDotsThree as _, ScalarIconGlobe as ee } from "@scalar/icons";
5
- import { LibraryIcon as te } from "@scalar/icons/library";
4
+ import { ScalarIconPlus as Z, ScalarIconDotsThree as _ } from "@scalar/icons";
5
+ import { LibraryIcon as ee } from "@scalar/icons/library";
6
6
  import { getParentEntry as S } from "@scalar/workspace-store/navigation";
7
- import ae from "../../../../assets/rabbit.ascii.js";
8
- import oe from "../../../../assets/rabbitjump.ascii.js";
9
- import E from "../../../../components/ScalarAsciiArt.vue.js";
10
- import ne from "../../../../components/Sidebar/Actions/DeleteSidebarListElement.vue.js";
7
+ import te from "../../../../assets/rabbit.ascii.js";
8
+ import ae from "../../../../assets/rabbitjump.ascii.js";
9
+ import O from "../../../../components/ScalarAsciiArt.vue.js";
10
+ import oe from "../../../../components/Sidebar/Actions/DeleteSidebarListElement.vue.js";
11
+ import ne from "./DownloadAppButton.vue.js";
11
12
  import ie from "./SidebarItemMenu.vue.js";
12
13
  import { dragHandleFactory as se } from "../../../helpers/drag-handle-factory.js";
13
14
  import re from "../../../components/sidebar/Sidebar.vue.js";
@@ -17,9 +18,9 @@ const le = { class: "flex" }, de = {
17
18
  }, ue = {
18
19
  key: 0,
19
20
  class: "empty-sidebar-item-content overflow-hidden px-2.5 py-2.5"
20
- }, me = { class: "rabbit-ascii relative m-auto mt-2 h-[68px] w-[60px]" }, ce = { class: "gap-1.5 p-2" }, pe = { class: "text-sidebar-c-2 rounded border px-1.25 py-1 text-xs leading-none font-medium uppercase" }, We = /* @__PURE__ */ L({
21
+ }, me = { class: "rabbit-ascii relative m-auto mt-2 h-[68px] w-[60px]" }, ce = { class: "flex flex-col gap-1.5 p-2" }, pe = { class: "text-sidebar-c-2 rounded border px-1.25 py-1 text-xs leading-none font-medium uppercase" }, Ie = /* @__PURE__ */ L({
21
22
  __name: "AppSidebar",
22
- props: /* @__PURE__ */ I({
23
+ props: /* @__PURE__ */ W({
23
24
  layout: {},
24
25
  sidebarState: {},
25
26
  isWorkspaceOpen: { type: Boolean },
@@ -36,104 +37,104 @@ const le = { class: "flex" }, de = {
36
37
  },
37
38
  sidebarWidthModifiers: {}
38
39
  }),
39
- emits: /* @__PURE__ */ I(["click:workspace", "selectItem", "select:workspace", "create:workspace"], ["update:isSidebarOpen", "update:sidebarWidth"]),
40
- setup(o, { emit: A }) {
41
- const f = A, D = k(() => R(o.activeWorkspace.label)), M = W(o, "isSidebarOpen"), B = W(o, "sidebarWidth"), g = k(() => o.sidebarState.items.value.length <= 1), C = k(
40
+ emits: /* @__PURE__ */ W(["click:workspace", "selectItem", "select:workspace", "create:workspace"], ["update:isSidebarOpen", "update:sidebarWidth"]),
41
+ setup(a, { emit: A }) {
42
+ const f = A, D = k(() => R(a.activeWorkspace.label)), M = h(a, "isSidebarOpen"), B = h(a, "sidebarWidth"), x = k(() => a.sidebarState.items.value.length <= 1), C = k(
42
43
  () => se({
43
- store: o.store,
44
- sidebarState: o.sidebarState
44
+ store: a.store,
45
+ sidebarState: a.sidebarState
45
46
  })
46
- ), N = (a, e) => C.value.handleDragEnd(a, e), T = (a, e) => C.value.isDroppable(a, e), s = V(null), y = J(), K = k(() => {
47
- const a = s.value?.item;
48
- return a?.type === "document" ? "This cannot be undone. You're about to delete the document and all tags and operations inside it." : `Are you sure you want to delete this ${a?.type ?? "item"}? This action cannot be undone.`;
47
+ ), N = (o, e) => C.value.handleDragEnd(o, e), T = (o, e) => C.value.isDroppable(o, e), s = V(null), y = J(), K = k(() => {
48
+ const o = s.value?.item;
49
+ return o?.type === "document" ? "This cannot be undone. You're about to delete the document and all tags and operations inside it." : `Are you sure you want to delete this ${o?.type ?? "item"}? This action cannot be undone.`;
49
50
  }), z = () => {
50
- const a = s.value?.item;
51
- if (!a)
51
+ const o = s.value?.item;
52
+ if (!o)
52
53
  return;
53
- const e = o.sidebarState.getEntryById(a.id), t = S("document", e), n = S("operation", e);
54
+ const e = a.sidebarState.getEntryById(o.id), t = S("document", e), n = S("operation", e);
54
55
  if (t) {
55
- if (a.type === "document")
56
- o.eventBus.emit("document:delete:document", { name: t.name });
57
- else if (a.type === "tag")
58
- o.eventBus.emit("tag:delete:tag", {
56
+ if (o.type === "document")
57
+ a.eventBus.emit("document:delete:document", { name: t.name });
58
+ else if (o.type === "tag")
59
+ a.eventBus.emit("tag:delete:tag", {
59
60
  documentName: t.name,
60
- name: a.name
61
+ name: o.name
61
62
  });
62
- else if (a.type === "operation") {
63
+ else if (o.type === "operation") {
63
64
  if (!n)
64
65
  return;
65
- o.eventBus.emit("operation:delete:operation", {
66
+ a.eventBus.emit("operation:delete:operation", {
66
67
  meta: {
67
68
  method: n.method,
68
69
  path: n.path
69
70
  },
70
71
  documentName: t.name
71
72
  });
72
- } else if (a.type === "example") {
73
+ } else if (o.type === "example") {
73
74
  if (!n)
74
75
  return;
75
- o.eventBus.emit("operation:delete:example", {
76
+ a.eventBus.emit("operation:delete:example", {
76
77
  meta: {
77
78
  method: n.method,
78
79
  path: n.path,
79
- exampleKey: a.name
80
+ exampleKey: o.name
80
81
  },
81
82
  documentName: t.name
82
83
  });
83
84
  }
84
85
  y.hide(), s.value = null;
85
86
  }
86
- }, m = async (a, e) => {
87
+ }, c = async (o, e) => {
87
88
  if (s.value?.showMenu)
88
89
  return;
89
- const t = a.currentTarget;
90
+ const t = o.currentTarget;
90
91
  s.value = { item: e, el: t, showMenu: !0 }, await U();
91
- const n = a instanceof MouseEvent ? new MouseEvent(a.type, a) : new KeyboardEvent(a.type, a);
92
+ const n = o instanceof MouseEvent ? new MouseEvent(o.type, o) : new KeyboardEvent(o.type, o);
92
93
  s.value?.el.dispatchEvent(n);
93
94
  }, P = () => {
94
95
  s.value && (s.value.showMenu = !1);
95
- }, q = (a) => {
96
- const e = o.sidebarState.getEntryById(a.id), t = S("document", e), n = S("tag", e);
97
- o.eventBus.emit("ui:open:command-palette", {
96
+ }, q = (o) => {
97
+ const e = a.sidebarState.getEntryById(o.id), t = S("document", e), n = S("tag", e);
98
+ a.eventBus.emit("ui:open:command-palette", {
98
99
  action: "create-request",
99
100
  payload: {
100
- documentId: t?.id,
101
+ documentName: t?.name,
101
102
  tagId: n?.name
102
103
  }
103
104
  });
104
105
  };
105
- return (a, e) => (u(), c("div", le, [
106
+ return (o, e) => (u(), p("div", le, [
106
107
  d(i(re), {
107
108
  isSidebarOpen: M.value,
108
109
  "onUpdate:isSidebarOpen": e[3] || (e[3] = (t) => M.value = t),
109
110
  sidebarWidth: B.value,
110
111
  "onUpdate:sidebarWidth": e[4] || (e[4] = (t) => B.value = t),
111
- activeWorkspace: o.activeWorkspace,
112
- documents: Object.values(o.store.workspace.documents),
112
+ activeWorkspace: a.activeWorkspace,
113
+ documents: Object.values(a.store.workspace.documents),
113
114
  isDroppable: T,
114
- layout: o.layout,
115
- sidebarState: o.sidebarState,
116
- workspaces: o.workspaces,
115
+ layout: a.layout,
116
+ sidebarState: a.sidebarState,
117
+ workspaces: a.workspaces,
117
118
  "onCreate:workspace": e[5] || (e[5] = (t) => f("create:workspace")),
118
- onReorder: e[6] || (e[6] = (t, n) => N(t, n)),
119
- "onSelect:workspace": e[7] || (e[7] = (t) => f("select:workspace", t)),
120
- onSelectItem: e[8] || (e[8] = (t) => f("selectItem", t))
119
+ "onNavigate:to:settings": e[6] || (e[6] = (t) => a.eventBus.emit("ui:navigate", { page: "workspace", path: "settings" })),
120
+ onReorder: e[7] || (e[7] = (t, n) => N(t, n)),
121
+ "onSelect:workspace": e[8] || (e[8] = (t) => f("select:workspace", t)),
122
+ onSelectItem: e[9] || (e[9] = (t) => f("selectItem", t))
121
123
  }, j({
122
124
  sidebarMenuActions: r(() => [
123
- G(a.$slots, "sidebarMenuActions", {}, void 0, !0)
125
+ G(o.$slots, "sidebarMenuActions", {}, void 0, !0)
124
126
  ]),
125
127
  workspaceButton: r(() => [
126
- d(i(O), {
128
+ d(i($), {
127
129
  is: "button",
128
- active: o.isWorkspaceOpen,
129
- icon: i(ee),
130
+ active: a.isWorkspaceOpen,
130
131
  onClick: e[0] || (e[0] = (t) => f("click:workspace"))
131
132
  }, {
132
133
  default: r(() => [
133
134
  b(F(D.value), 1)
134
135
  ]),
135
136
  _: 1
136
- }, 8, ["active", "icon"])
137
+ }, 8, ["active"])
137
138
  ]),
138
139
  decorator: r(({ item: t }) => [
139
140
  d(i(Y), {
@@ -143,33 +144,33 @@ const le = { class: "flex" }, de = {
143
144
  label: "More options",
144
145
  size: "sm",
145
146
  weight: "bold",
146
- onClick: v((n) => m(n, t), ["stop"]),
147
+ onClick: v((n) => c(n, t), ["stop"]),
147
148
  onKeydown: [
148
- w(v((n) => m(n, t), ["stop"]), ["down"]),
149
- w(v((n) => m(n, t), ["stop"]), ["enter"]),
150
- w(v((n) => m(n, t), ["stop"]), ["space"]),
151
- w(v((n) => m(n, t), ["stop"]), ["up"])
149
+ g(v((n) => c(n, t), ["stop"]), ["down"]),
150
+ g(v((n) => c(n, t), ["stop"]), ["enter"]),
151
+ g(v((n) => c(n, t), ["stop"]), ["space"]),
152
+ g(v((n) => c(n, t), ["stop"]), ["up"])
152
153
  ]
153
154
  }, null, 8, ["icon", "onClick", "onKeydown"])
154
155
  ]),
155
156
  icon: r(({ item: t }) => [
156
- t.type === "document" && o.store.workspace.documents[t.name]?.["x-scalar-is-dirty"] === !0 ? (u(), c("div", de, [
157
- d(i(te), {
157
+ t.type === "document" && a.store.workspace.documents[t.name]?.["x-scalar-is-dirty"] === !0 ? (u(), p("div", de, [
158
+ d(i(ee), {
158
159
  class: "block",
159
160
  src: "icon" in t && t.icon || "interface-content-folder"
160
161
  }, null, 8, ["src"]),
161
- e[11] || (e[11] = l("div", { class: "bg-orange absolute -top-1.25 -right-1.25 flex h-2.5 w-2.5 items-center justify-center rounded-full text-[9px] font-bold text-white" }, " ! ", -1))
162
- ])) : p("", !0)
162
+ e[12] || (e[12] = l("div", { class: "bg-orange absolute -top-1.25 -right-1.25 flex h-2.5 w-2.5 items-center justify-center rounded-full text-[9px] font-bold text-white" }, " ! ", -1))
163
+ ])) : m("", !0)
163
164
  ]),
164
165
  empty: r(({ item: t }) => [
165
- d(i(O), {
166
+ d(i($), {
166
167
  is: "button",
167
168
  onClick: (n) => q(t)
168
169
  }, {
169
170
  icon: r(() => [
170
171
  d(i(Z))
171
172
  ]),
172
- default: r(() => [...e[12] || (e[12] = [
173
+ default: r(() => [...e[13] || (e[13] = [
173
174
  b("Add operation", -1)
174
175
  ])]),
175
176
  _: 1
@@ -177,101 +178,102 @@ const le = { class: "flex" }, de = {
177
178
  ]),
178
179
  _: 2
179
180
  }, [
180
- o.layout !== "modal" ? {
181
+ a.layout !== "modal" ? {
181
182
  name: "footer",
182
183
  fn: r(() => [
183
184
  l("div", {
184
185
  class: H({
185
- "empty-sidebar-item border-t": g.value
186
+ "empty-sidebar-item border-t": x.value
186
187
  })
187
188
  }, [
188
- g.value ? (u(), c("div", ue, [
189
+ x.value ? (u(), p("div", ue, [
189
190
  l("div", me, [
190
- d(E, {
191
- art: i(ae),
191
+ d(O, {
192
+ art: i(te),
192
193
  class: "rabbitsit font-bold"
193
194
  }, null, 8, ["art"]),
194
- d(E, {
195
- art: i(oe),
195
+ d(O, {
196
+ art: i(ae),
196
197
  class: "rabbitjump absolute top-0 left-0 font-bold"
197
198
  }, null, 8, ["art"])
198
199
  ]),
199
- e[13] || (e[13] = l("div", { class: "mt-2 mb-2 text-center text-sm text-balance" }, [
200
+ e[14] || (e[14] = l("div", { class: "mt-2 mb-2 text-center text-sm text-balance" }, [
200
201
  l("b", { class: "font-medium" }, "Let's Get Started"),
201
202
  l("p", { class: "mt-2 leading-3" }, " Create request, folder, collection or import from OpenAPI/Postman ")
202
203
  ], -1))
203
- ])) : p("", !0),
204
+ ])) : m("", !0),
204
205
  l("div", ce, [
205
- g.value ? (u(), x(i($), {
206
+ x.value ? (u(), w(i(E), {
206
207
  key: 0,
207
208
  class: "w-full",
208
209
  size: "sm",
209
- onClick: e[1] || (e[1] = (t) => o.eventBus.emit("ui:open:command-palette", {
210
+ onClick: e[1] || (e[1] = (t) => a.eventBus.emit("ui:open:command-palette", {
210
211
  action: "import-from-openapi-swagger-postman-curl",
211
212
  payload: void 0
212
213
  }))
213
214
  }, {
214
- default: r(() => [...e[14] || (e[14] = [
215
+ default: r(() => [...e[15] || (e[15] = [
215
216
  b(" Import Collection ", -1)
216
217
  ])]),
217
218
  _: 1
218
- })) : p("", !0),
219
- d(i($), {
219
+ })) : m("", !0),
220
+ d(i(E), {
220
221
  class: "w-full",
221
222
  hotkey: "K",
222
223
  size: "sm",
223
224
  variant: "outlined",
224
- onClick: e[2] || (e[2] = (t) => o.eventBus.emit("ui:open:command-palette"))
225
+ onClick: e[2] || (e[2] = (t) => a.eventBus.emit("ui:open:command-palette"))
225
226
  }, {
226
227
  default: r(() => [
227
- e[20] || (e[20] = b(" Add Item   ", -1)),
228
+ e[21] || (e[21] = b(" Add Item   ", -1)),
228
229
  l("span", pe, [
229
- i(X)() ? (u(), c(h, { key: 0 }, [
230
- e[15] || (e[15] = l("span", { class: "sr-only" }, "Command", -1)),
231
- e[16] || (e[16] = l("span", { "aria-hidden": "true" }, "⌘", -1))
232
- ], 64)) : (u(), c(h, { key: 1 }, [
233
- e[17] || (e[17] = l("span", { class: "sr-only" }, "CTRL", -1)),
234
- e[18] || (e[18] = l("span", { "aria-hidden": "true" }, "⌃", -1))
230
+ i(X)() ? (u(), p(I, { key: 0 }, [
231
+ e[16] || (e[16] = l("span", { class: "sr-only" }, "Command", -1)),
232
+ e[17] || (e[17] = l("span", { "aria-hidden": "true" }, "⌘", -1))
233
+ ], 64)) : (u(), p(I, { key: 1 }, [
234
+ e[18] || (e[18] = l("span", { class: "sr-only" }, "CTRL", -1)),
235
+ e[19] || (e[19] = l("span", { "aria-hidden": "true" }, "⌃", -1))
235
236
  ], 64)),
236
- e[19] || (e[19] = b(" K ", -1))
237
+ e[20] || (e[20] = b(" K ", -1))
237
238
  ])
238
239
  ]),
239
240
  _: 1
240
- })
241
+ }),
242
+ a.layout === "web" ? (u(), w(ne, { key: 1 })) : m("", !0)
241
243
  ])
242
244
  ], 2)
243
245
  ]),
244
246
  key: "0"
245
247
  } : void 0
246
248
  ]), 1032, ["isSidebarOpen", "sidebarWidth", "activeWorkspace", "documents", "layout", "sidebarState", "workspaces"]),
247
- s.value?.showMenu ? (u(), x(ie, {
249
+ s.value?.showMenu ? (u(), w(ie, {
248
250
  key: 0,
249
- eventBus: o.eventBus,
251
+ eventBus: a.eventBus,
250
252
  item: s.value.item,
251
- sidebarState: o.sidebarState,
253
+ sidebarState: a.sidebarState,
252
254
  target: s.value.el,
253
255
  onCloseMenu: P,
254
- onShowDeleteModal: e[9] || (e[9] = (t) => i(y).show())
255
- }, null, 8, ["eventBus", "item", "sidebarState", "target"])) : p("", !0),
256
- s.value ? (u(), x(i(Q), {
256
+ onShowDeleteModal: e[10] || (e[10] = (t) => i(y).show())
257
+ }, null, 8, ["eventBus", "item", "sidebarState", "target"])) : m("", !0),
258
+ s.value ? (u(), w(i(Q), {
257
259
  key: 1,
258
260
  size: "xxs",
259
261
  state: i(y),
260
262
  title: `Delete ${s.value.item.title}`
261
263
  }, {
262
264
  default: r(() => [
263
- d(ne, {
265
+ d(oe, {
264
266
  variableName: s.value.item.title,
265
267
  warningMessage: K.value,
266
- onClose: e[10] || (e[10] = (t) => i(y).hide()),
268
+ onClose: e[11] || (e[11] = (t) => i(y).hide()),
267
269
  onDelete: z
268
270
  }, null, 8, ["variableName", "warningMessage"])
269
271
  ]),
270
272
  _: 1
271
- }, 8, ["state", "title"])) : p("", !0)
273
+ }, 8, ["state", "title"])) : m("", !0)
272
274
  ]));
273
275
  }
274
276
  });
275
277
  export {
276
- We as default
278
+ Ie as default
277
279
  };
@@ -1 +1 @@
1
- {"version":3,"file":"DesktopTabs.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/DesktopTabs.vue"],"names":[],"mappings":"AA4EA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,oEAAoE,CAAA;AAK7F,KAAK,WAAW,GAAG;IACjB,iBAAiB;IACjB,IAAI,EAAE,GAAG,EAAE,CAAA;IACX,+BAA+B;IAC/B,cAAc,EAAE,MAAM,CAAA;IACtB,0DAA0D;IAC1D,QAAQ,EAAE,iBAAiB,CAAA;CAC5B,CAAC;AAyJF,QAAA,MAAM,YAAY,kSAEhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"DesktopTabs.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/DesktopTabs.vue"],"names":[],"mappings":"AA2EA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,oEAAoE,CAAA;AAK7F,KAAK,WAAW,GAAG;IACjB,iBAAiB;IACjB,IAAI,EAAE,GAAG,EAAE,CAAA;IACX,+BAA+B;IAC/B,cAAc,EAAE,MAAM,CAAA;IACtB,0DAA0D;IAC1D,QAAQ,EAAE,iBAAiB,CAAA;CAC5B,CAAC;AAwJF,QAAA,MAAM,YAAY,kSAEhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -1,7 +1,7 @@
1
- import { defineComponent as v, computed as d, createElementBlock as l, openBlock as n, createElementVNode as h, Fragment as T, renderList as p, createBlock as C, createVNode as k, unref as g } from "vue";
1
+ import { defineComponent as v, computed as d, createElementBlock as l, openBlock as n, createElementVNode as h, Fragment as T, renderList as C, createBlock as k, createVNode as p, unref as g } from "vue";
2
2
  import { ScalarIcon as f } from "@scalar/components";
3
3
  import B from "./DesktopTab.vue.js";
4
- const y = { class: "mac:pl-[72px] t-app__top-nav z-1 flex h-10 items-center gap-2 px-2" }, U = /* @__PURE__ */ v({
4
+ const y = { class: "t-app__top-nav z-1 flex h-10 items-center gap-2 px-2" }, U = /* @__PURE__ */ v({
5
5
  __name: "DesktopTabs",
6
6
  props: {
7
7
  tabs: {},
@@ -21,7 +21,7 @@ const y = { class: "mac:pl-[72px] t-app__top-nav z-1 flex h-10 items-center gap-
21
21
  e.eventBus.emit("tabs:copy:url", { index: t });
22
22
  };
23
23
  return (t, S) => (n(), l("nav", y, [
24
- (n(!0), l(T, null, p(e.tabs, (m, a) => (n(), C(B, {
24
+ (n(!0), l(T, null, C(e.tabs, (m, a) => (n(), k(B, {
25
25
  key: a,
26
26
  active: a === e.activeTabIndex,
27
27
  hotkey: !o.value && a < 9 ? String(a + 1) : void 0,
@@ -38,7 +38,7 @@ const y = { class: "mac:pl-[72px] t-app__top-nav z-1 flex h-10 items-center gap-
38
38
  type: "button",
39
39
  onClick: s
40
40
  }, [
41
- k(g(f), {
41
+ p(g(f), {
42
42
  icon: "Add",
43
43
  size: "sm",
44
44
  thickness: "2.5"
@@ -1 +1 @@
1
- {"version":3,"file":"DownloadAppButton.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/DownloadAppButton.vue"],"names":[],"mappings":"AA4FA,QAAA,MAAM,YAAY,+QAChB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"DownloadAppButton.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/DownloadAppButton.vue"],"names":[],"mappings":"AAiGA,QAAA,MAAM,YAAY,+QAChB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
@@ -1,7 +1,7 @@
1
1
  import o from "./DownloadAppButton.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-d9bec97b"]]);
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-9c21e4d7"]]);
5
5
  export {
6
6
  m as default
7
7
  };
@@ -1,19 +1,19 @@
1
- import { defineComponent as t, createElementBlock as e, openBlock as n, createVNode as a, createElementVNode as p, unref as m } from "vue";
1
+ import { defineComponent as e, createElementBlock as o, openBlock as n, createVNode as a, createElementVNode as m, unref as l } from "vue";
2
2
  import { ScalarIconDownloadSimple as r } from "@scalar/icons";
3
- const l = {
4
- class: "download-app-button flex flex-row gap-2 rounded !px-3 !py-1.5 sm:px-3",
3
+ const s = {
4
+ class: "download-app-button flex w-full flex-row items-center justify-center gap-2 rounded px-3.5 py-2 text-sm leading-5 font-medium",
5
5
  href: "https://scalar.com/download?utm_source=web_client&utm_medium=download_button&utm_campaign=topnav",
6
6
  target: "_blank",
7
7
  type: "button"
8
- }, _ = /* @__PURE__ */ t({
8
+ }, i = /* @__PURE__ */ e({
9
9
  __name: "DownloadAppButton",
10
- setup(s) {
11
- return (d, o) => (n(), e("a", l, [
12
- a(m(r), { size: "sm" }),
13
- o[0] || (o[0] = p("span", { class: "sr-only text-sm font-medium sm:not-sr-only" }, " Download App ", -1))
10
+ setup(p) {
11
+ return (d, t) => (n(), o("a", s, [
12
+ a(l(r), { size: "sm" }),
13
+ t[0] || (t[0] = m("span", { class: "sr-only text-sm font-medium sm:not-sr-only" }, " Download App ", -1))
14
14
  ]));
15
15
  }
16
16
  });
17
17
  export {
18
- _ as default
18
+ i as default
19
19
  };
@@ -1 +1 @@
1
- {"version":3,"file":"SidebarItemMenu.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/SidebarItemMenu.vue"],"names":[],"mappings":"AAiLA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AACnD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AAEvE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAA;AAGhF,KAAK,WAAW,GAAG;IACjB,4CAA4C;IAC5C,IAAI,EAAE,cAAc,CAAA;IACpB,sCAAsC;IACtC,QAAQ,EAAE,iBAAiB,CAAA;IAC3B,qDAAqD;IACrD,YAAY,EAAE,YAAY,CAAC,cAAc,CAAC,CAAA;IAC1C,sDAAsD;IACtD,MAAM,EAAE,WAAW,CAAA;CACpB,CAAC;AAsVF,QAAA,MAAM,YAAY;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
1
+ {"version":3,"file":"SidebarItemMenu.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/SidebarItemMenu.vue"],"names":[],"mappings":"AA2MA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAA;AACnD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AAEvE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAA;AAGhF,KAAK,WAAW,GAAG;IACjB,4CAA4C;IAC5C,IAAI,EAAE,cAAc,CAAA;IACpB,sCAAsC;IACtC,QAAQ,EAAE,iBAAiB,CAAA;IAC3B,qDAAqD;IACrD,YAAY,EAAE,YAAY,CAAC,cAAc,CAAC,CAAA;IAC1C,sDAAsD;IACtD,MAAM,EAAE,WAAW,CAAA;CACpB,CAAC;AA+YF,QAAA,MAAM,YAAY;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}