@scalar/api-client 2.26.1 → 2.27.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 (158) hide show
  1. package/CHANGELOG.md +102 -0
  2. package/dist/components/Server/ServerSelector.vue.js +6 -6
  3. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +6 -6
  4. package/dist/style.css +1 -1
  5. package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts +1 -1
  6. package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts.map +1 -1
  7. package/dist/v2/blocks/operation-block/OperationBlock.vue.js +48 -43
  8. package/dist/v2/blocks/operation-block/components/Header.vue.js +2 -2
  9. package/dist/v2/blocks/operation-block/components/Header.vue2.js +10 -10
  10. package/dist/v2/blocks/operation-block/helpers/build-request-body.d.ts.map +1 -1
  11. package/dist/v2/blocks/operation-block/helpers/build-request-body.js +29 -25
  12. package/dist/v2/blocks/operation-block/helpers/get-example.d.ts.map +1 -1
  13. package/dist/v2/blocks/operation-block/helpers/get-example.js +15 -15
  14. package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.d.ts +10 -0
  15. package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.d.ts.map +1 -0
  16. package/dist/v2/blocks/operation-block/helpers/get-selected-body-content-type.js +4 -0
  17. package/dist/v2/blocks/operation-block/helpers/send-request.d.ts +1 -1
  18. package/dist/v2/blocks/operation-block/helpers/send-request.d.ts.map +1 -1
  19. package/dist/v2/blocks/operation-block/helpers/send-request.js +1 -1
  20. package/dist/v2/blocks/request-block/RequestBlock.vue.d.ts +1 -1
  21. package/dist/v2/blocks/request-block/RequestBlock.vue.d.ts.map +1 -1
  22. package/dist/v2/blocks/request-block/RequestBlock.vue.js +1 -1
  23. package/dist/v2/blocks/request-block/RequestBlock.vue2.js +101 -100
  24. package/dist/v2/blocks/request-block/components/RequestBody.vue.d.ts.map +1 -1
  25. package/dist/v2/blocks/request-block/components/RequestBody.vue.js +2 -2
  26. package/dist/v2/blocks/request-block/components/RequestBody.vue2.js +62 -69
  27. package/dist/v2/blocks/request-block/components/RequestParams.vue.js +6 -6
  28. package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts +36 -2
  29. package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts.map +1 -1
  30. package/dist/v2/blocks/request-block/components/RequestTable.vue.js +1 -1
  31. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts +38 -3
  32. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts.map +1 -1
  33. package/dist/v2/blocks/request-block/helpers/get-default-headers.js +1 -1
  34. package/dist/v2/blocks/response-block/ResponseBlock.vue.d.ts +1 -1
  35. package/dist/v2/blocks/response-block/ResponseBlock.vue.d.ts.map +1 -1
  36. package/dist/v2/blocks/response-block/ResponseBlock.vue.js +1 -1
  37. package/dist/v2/blocks/response-block/ResponseBlock.vue2.js +68 -69
  38. package/dist/v2/blocks/response-block/components/ResponseEmpty.vue.d.ts.map +1 -1
  39. package/dist/v2/blocks/response-block/components/ResponseEmpty.vue.js +1 -1
  40. package/dist/v2/blocks/response-block/components/ResponseEmpty.vue2.js +31 -40
  41. package/dist/v2/blocks/scalar-address-bar-block/components/EnvironmentSelector.vue.d.ts.map +1 -1
  42. package/dist/v2/blocks/scalar-address-bar-block/components/EnvironmentSelector.vue.js +35 -41
  43. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.d.ts.map +1 -1
  44. package/dist/v2/blocks/scalar-auth-selector-block/components/AuthSelector.vue.js +37 -41
  45. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts +3 -2
  46. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts.map +1 -1
  47. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +107 -87
  48. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.d.ts +21 -0
  49. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.d.ts.map +1 -0
  50. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue.js +91 -0
  51. package/dist/v2/blocks/scalar-auth-selector-block/components/OpenIDConnect.vue2.js +4 -0
  52. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts.map +1 -1
  53. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.js +107 -93
  54. package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.d.ts.map +1 -1
  55. package/dist/v2/blocks/scalar-auth-selector-block/helpers/extract-security-scheme-secrets.js +87 -65
  56. package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.d.ts +36 -0
  57. package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.d.ts.map +1 -0
  58. package/dist/v2/blocks/scalar-auth-selector-block/helpers/fetch-openid-connect-discovery.js +35 -0
  59. package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.d.ts +1 -1
  60. package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.d.ts.map +1 -1
  61. package/dist/v2/blocks/scalar-auth-selector-block/helpers/merge-security.js +18 -10
  62. package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.d.ts +5 -0
  63. package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.d.ts.map +1 -0
  64. package/dist/v2/blocks/scalar-auth-selector-block/helpers/openid-discovery-to-flows.js +27 -0
  65. package/dist/v2/blocks/scalar-auth-selector-block/helpers/secret-types.d.ts +3 -1
  66. package/dist/v2/blocks/scalar-auth-selector-block/helpers/secret-types.d.ts.map +1 -1
  67. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts +1 -2
  68. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.d.ts.map +1 -1
  69. package/dist/v2/blocks/scalar-auth-selector-block/helpers/security-scheme.js +29 -37
  70. package/dist/v2/components/layout/CollapsibleSection.vue.js +1 -1
  71. package/dist/v2/components/modals/ModalClientContainer.vue.d.ts +2 -2
  72. package/dist/v2/components/modals/ModalClientContainer.vue.d.ts.map +1 -1
  73. package/dist/v2/components/modals/ModalClientContainer.vue.js +1 -1
  74. package/dist/v2/components/modals/ModalClientContainer.vue2.js +45 -42
  75. package/dist/v2/components/sidebar/Sidebar.vue.d.ts +2 -0
  76. package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  77. package/dist/v2/components/sidebar/Sidebar.vue.js +25 -24
  78. package/dist/v2/components/sidebar/SidebarMenu.vue.d.ts +2 -0
  79. package/dist/v2/components/sidebar/SidebarMenu.vue.d.ts.map +1 -1
  80. package/dist/v2/components/sidebar/SidebarMenu.vue.js +30 -30
  81. package/dist/v2/features/app/App.vue.d.ts +6 -1
  82. package/dist/v2/features/app/App.vue.d.ts.map +1 -1
  83. package/dist/v2/features/app/App.vue.js +48 -46
  84. package/dist/v2/features/app/app-events.d.ts +1 -1
  85. package/dist/v2/features/app/app-events.d.ts.map +1 -1
  86. package/dist/v2/features/app/app-events.js +95 -56
  87. package/dist/v2/features/app/components/AppSidebar.vue.d.ts.map +1 -1
  88. package/dist/v2/features/app/components/AppSidebar.vue.js +3 -3
  89. package/dist/v2/features/app/components/AppSidebar.vue2.js +111 -105
  90. package/dist/v2/features/app/helpers/create-api-client-app.d.ts +12 -2
  91. package/dist/v2/features/app/helpers/create-api-client-app.d.ts.map +1 -1
  92. package/dist/v2/features/app/helpers/create-api-client-app.js +12 -10
  93. package/dist/v2/features/app/helpers/routes.d.ts +3 -1
  94. package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
  95. package/dist/v2/features/app/hooks/use-theme.d.ts +42 -0
  96. package/dist/v2/features/app/hooks/use-theme.d.ts.map +1 -0
  97. package/dist/v2/features/app/hooks/use-theme.js +34 -0
  98. package/dist/v2/features/app/index.d.ts +0 -1
  99. package/dist/v2/features/app/index.d.ts.map +1 -1
  100. package/dist/v2/features/collection/DocumentCollection.vue.d.ts.map +1 -1
  101. package/dist/v2/features/collection/DocumentCollection.vue.js +27 -26
  102. package/dist/v2/features/collection/WorkspaceCollection.vue.js +13 -12
  103. package/dist/v2/features/collection/components/Authentication.vue.d.ts.map +1 -1
  104. package/dist/v2/features/collection/components/Authentication.vue.js +2 -2
  105. package/dist/v2/features/collection/components/Authentication.vue2.js +49 -40
  106. package/dist/v2/features/collection/components/Cookies.vue.d.ts.map +1 -1
  107. package/dist/v2/features/collection/components/Cookies.vue.js +26 -13
  108. package/dist/v2/features/collection/components/Environment.vue.d.ts.map +1 -1
  109. package/dist/v2/features/collection/components/Environment.vue.js +27 -15
  110. package/dist/v2/features/collection/components/Overview.vue.d.ts.map +1 -1
  111. package/dist/v2/features/collection/components/Overview.vue.js +2 -2
  112. package/dist/v2/features/collection/components/Overview.vue2.js +68 -61
  113. package/dist/v2/features/collection/components/Servers.vue.d.ts.map +1 -1
  114. package/dist/v2/features/collection/components/Servers.vue.js +93 -88
  115. package/dist/v2/features/collection/components/Settings.vue.d.ts.map +1 -1
  116. package/dist/v2/features/collection/components/Settings.vue.js +19 -17
  117. package/dist/v2/features/environments/EnvironmentsList.vue.js +1 -1
  118. package/dist/v2/features/global-cookies/components/CookiesTable.vue.d.ts.map +1 -1
  119. package/dist/v2/features/global-cookies/components/CookiesTable.vue.js +2 -2
  120. package/dist/v2/features/global-cookies/components/CookiesTable.vue2.js +8 -8
  121. package/dist/v2/features/modal/Modal.vue.d.ts +1 -1
  122. package/dist/v2/features/modal/Modal.vue.d.ts.map +1 -1
  123. package/dist/v2/features/modal/Modal.vue.js +15 -15
  124. package/dist/v2/features/modal/helpers/create-api-client-modal.d.ts +1 -1
  125. package/dist/v2/features/modal/helpers/create-api-client-modal.d.ts.map +1 -1
  126. package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
  127. package/dist/v2/features/operation/Operation.vue.js +31 -34
  128. package/dist/v2/features/settings/CollectionSettings.vue.d.ts +10 -7
  129. package/dist/v2/features/settings/CollectionSettings.vue.d.ts.map +1 -1
  130. package/dist/v2/features/settings/CollectionSettings.vue.js +183 -149
  131. package/dist/v2/features/settings/DocumentSettings.vue.d.ts.map +1 -1
  132. package/dist/v2/features/settings/DocumentSettings.vue.js +88 -79
  133. package/dist/v2/features/settings/components/Section.vue.d.ts +2 -1
  134. package/dist/v2/features/settings/components/Section.vue.d.ts.map +1 -1
  135. package/dist/v2/features/settings/components/Section.vue.js +26 -15
  136. package/dist/v2/features/settings/helpers/get-theme-colors.d.ts +4 -3
  137. package/dist/v2/features/settings/helpers/get-theme-colors.d.ts.map +1 -1
  138. package/dist/v2/features/settings/helpers/get-theme-colors.js +6 -7
  139. package/dist/v2/helpers/handle-hotkeys.d.ts.map +1 -1
  140. package/dist/v2/helpers/handle-hotkeys.js +2 -2
  141. package/dist/v2/helpers/index.d.ts +0 -1
  142. package/dist/v2/helpers/index.d.ts.map +1 -1
  143. package/dist/v2/hooks/use-global-hot-keys.d.ts +3 -1
  144. package/dist/v2/hooks/use-global-hot-keys.d.ts.map +1 -1
  145. package/dist/v2/hooks/use-global-hot-keys.js +8 -6
  146. package/dist/v2/workspace-events.d.ts.map +1 -1
  147. package/dist/v2/workspace-events.js +10 -0
  148. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  149. package/dist/views/Request/RequestSidebar.vue.js +2 -2
  150. package/dist/views/Request/RequestSidebar.vue2.js +139 -155
  151. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  152. package/dist/views/Request/RequestSidebarItem.vue.js +2 -2
  153. package/dist/views/Request/RequestSidebarItem.vue2.js +104 -101
  154. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  155. package/package.json +20 -18
  156. package/dist/v2/helpers/plugins.d.ts +0 -65
  157. package/dist/v2/helpers/plugins.d.ts.map +0 -1
  158. package/dist/v2/helpers/plugins.js +0 -11
@@ -1,89 +1,84 @@
1
- import { defineComponent as ve, useId as he, reactive as be, ref as W, watch as C, onMounted as ge, onBeforeUnmount as Se, computed as I, createElementBlock as v, openBlock as a, Fragment as $, withDirectives as ke, createBlock as u, createCommentVNode as m, createVNode as h, unref as t, normalizeClass as b, createSlots as Re, withCtx as d, createElementVNode as n, createTextVNode as D, toDisplayString as A, withKeys as q, withModifiers as g, isRef as ye, renderList as H, vShow as xe } from "vue";
2
- import { ScalarButton as we, ScalarIcon as M, ScalarSidebarSearchInput as Ce, ScalarSearchResultList as Ie, ScalarSearchResultItem as $e } from "@scalar/components";
3
- import { LibraryIcon as De } from "@scalar/icons/library";
4
- import { useToasts as qe } from "@scalar/use-toasts";
5
- import { useRouter as Me } from "vue-router";
6
- import Te from "../../assets/rabbit.ascii.js";
7
- import Pe from "../../assets/rabbitjump.ascii.js";
8
- import _e from "../../components/EnvironmentSelector/EnvironmentSelector.vue.js";
9
- import Ve from "../../components/HttpMethod/HttpMethod.vue.js";
1
+ import { defineComponent as pe, useId as ve, reactive as be, ref as z, watch as I, onMounted as he, onBeforeUnmount as ge, computed as C, createElementBlock as v, openBlock as r, Fragment as $, withDirectives as Se, createBlock as u, createCommentVNode as m, createVNode as b, unref as t, normalizeClass as S, createSlots as ke, withCtx as d, createElementVNode as n, createTextVNode as D, toDisplayString as A, withKeys as q, withModifiers as h, isRef as Re, renderList as F, vShow as ye } from "vue";
2
+ import { ScalarButton as we, ScalarIcon as H, ScalarSidebarSearchInput as xe, ScalarSearchResultList as Ie, ScalarSearchResultItem as Ce } from "@scalar/components";
3
+ import { LibraryIcon as $e } from "@scalar/icons/library";
4
+ import { useToasts as De } from "@scalar/use-toasts";
5
+ import { useRouter as qe } from "vue-router";
6
+ import Me from "../../assets/rabbit.ascii.js";
7
+ import Te from "../../assets/rabbitjump.ascii.js";
8
+ import Pe from "../../components/EnvironmentSelector/EnvironmentSelector.vue.js";
9
+ import _e from "../../components/HttpMethod/HttpMethod.vue.js";
10
10
  import K from "../../components/ScalarAsciiArt.vue.js";
11
- import { useSearch as Ee } from "../../components/Search/useSearch.js";
12
- import Le from "../../components/Sidebar/SidebarButton.vue.js";
13
- import { useLayout as Ne } from "../../hooks/useLayout.js";
14
- import { useSidebar as Oe } from "../../hooks/useSidebar.js";
11
+ import { useSearch as Ve } from "../../components/Search/useSearch.js";
12
+ import Ee from "../../components/Sidebar/SidebarButton.vue.js";
13
+ import { useLayout as Le } from "../../hooks/useLayout.js";
14
+ import { useSidebar as Ne } from "../../hooks/useSidebar.js";
15
15
  import { PathId as U } from "../../routes.js";
16
- import { useActiveEntities as ze } from "../../store/active-entities.js";
16
+ import { useActiveEntities as Oe } from "../../store/active-entities.js";
17
17
  import { createInitialRequest as Be } from "../../store/requests.js";
18
- import { dragHandlerFactory as Fe } from "./handle-drag.js";
19
- import We from "./RequestSidebarItemMenu.vue.js";
18
+ import { dragHandlerFactory as We } from "./handle-drag.js";
19
+ import ze from "./RequestSidebarItemMenu.vue.js";
20
20
  import { isGettingStarted as Ae } from "./RequestSection/helpers/getting-started.js";
21
- import He from "./RequestSidebarItem.vue.js";
22
- import { useWorkspace as Ke } from "../../store/store.js";
23
- import Ue from "../../components/Sidebar/Sidebar.vue.js";
24
- import Ge from "./components/WorkspaceDropdown.vue.js";
25
- const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je = {
21
+ import Fe from "./RequestSidebarItem.vue.js";
22
+ import { useWorkspace as He } from "../../store/store.js";
23
+ import Ke from "../../components/Sidebar/Sidebar.vue.js";
24
+ import Ue from "./components/WorkspaceDropdown.vue.js";
25
+ const Ge = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, je = {
26
26
  key: 1,
27
27
  class: "text-c-3"
28
- }, Qe = ["aria-pressed"], Xe = { class: "sr-only" }, Ye = {
28
+ }, Je = ["aria-pressed"], Qe = { class: "sr-only" }, Xe = {
29
29
  key: 0,
30
30
  class: "search-button-fade sticky top-12 z-10 px-3 py-2.5 pt-0 focus-within:z-20",
31
31
  role: "search"
32
- }, Ze = {
32
+ }, Ye = {
33
33
  key: 1,
34
34
  class: "contents"
35
- }, et = {
35
+ }, Ze = {
36
36
  key: 0,
37
37
  class: "empty-sidebar-item-content px-2.5 py-2.5"
38
- }, tt = { class: "rabbit-ascii relative m-auto mt-2 h-[68px] w-[60px]" }, $t = /* @__PURE__ */ ve({
38
+ }, et = { class: "rabbit-ascii relative m-auto mt-2 h-[68px] w-[60px]" }, Ct = /* @__PURE__ */ pe({
39
39
  __name: "RequestSidebar",
40
40
  emits: ["newTab", "clearDrafts"],
41
- setup(ot, { emit: G }) {
42
- const j = G, {
43
- collapsedSidebarFolders: J,
44
- isSidebarOpen: T,
45
- setCollapsedSidebarFolder: Q,
46
- toggleSidebarOpen: X
47
- } = Oe(), { layout: l } = Ne(), P = Ke(), {
48
- activeCollection: _,
41
+ setup(tt, { emit: G }) {
42
+ const j = G, { isSidebarOpen: M, setCollapsedSidebarFolder: J, toggleSidebarOpen: Q } = Ne(), { layout: l } = Le(), T = He(), {
43
+ activeCollection: P,
49
44
  activeWorkspaceCollections: c,
50
- activeRequest: Y,
51
- activeWorkspaceRequests: V,
52
- activeWorkspace: Z
53
- } = ze(), { findRequestParents: ee, events: k, requestMutators: E, requests: y } = P, { handleDragEnd: te, isDroppable: oe } = Fe(
54
- Z,
55
- P
56
- ), { replace: L } = Me(), se = () => {
45
+ activeRequest: X,
46
+ activeWorkspaceRequests: _,
47
+ activeWorkspace: Y
48
+ } = Oe(), { findRequestParents: Z, events: k, requestMutators: V, requests: y } = T, { handleDragEnd: ee, isDroppable: te } = We(
49
+ Y,
50
+ T
51
+ ), { replace: E } = qe(), oe = () => {
57
52
  k.commandPalette.emit({
58
53
  commandName: "Import from OpenAPI/Swagger/Postman/cURL"
59
54
  });
60
- }, N = he(), { toast: re } = qe(), S = be({ open: !1 }), f = W(!1);
61
- C(
62
- Y,
55
+ }, L = ve(), { toast: se } = De(), g = be({ open: !1 }), f = z(!1);
56
+ I(
57
+ X,
63
58
  (s) => {
64
- s && ee(s).forEach(
65
- (e) => Q(e, !0)
59
+ s && Z(s).forEach(
60
+ (e) => J(e, !0)
66
61
  );
67
62
  },
68
63
  { immediate: !0 }
69
64
  );
70
65
  const {
71
66
  searchText: p,
72
- searchResultsWithPlaceholderResults: x,
73
- selectedSearchResult: w,
67
+ searchResultsWithPlaceholderResults: w,
68
+ selectedSearchResult: x,
74
69
  onSearchResultClick: ae,
75
- fuseSearch: le,
76
- searchInputRef: O,
77
- searchResultRefs: ne,
78
- navigateSearchResults: z,
79
- selectSearchResult: ie
80
- } = Ee(), B = W(), F = (s) => {
81
- s && (s.toggleSidebar && X(), s.focusRequestSearch && O.value?.focus());
70
+ fuseSearch: re,
71
+ searchInputRef: N,
72
+ searchResultRefs: le,
73
+ navigateSearchResults: O,
74
+ selectSearchResult: ne
75
+ } = Ve(), B = z(), W = (s) => {
76
+ s && (s.toggleSidebar && Q(), s.focusRequestSearch && N.value?.focus());
82
77
  };
83
- ge(() => k.hotKeys.on(F)), Se(() => {
84
- k.hotKeys.off(F);
78
+ he(() => k.hotKeys.on(W)), ge(() => {
79
+ k.hotKeys.off(W);
85
80
  });
86
- const ue = (s) => {
81
+ const ie = (s) => {
87
82
  if (s?.documentUrl) {
88
83
  s.watchMode = !s.watchMode;
89
84
  const e = c.value.find(
@@ -92,48 +87,48 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
92
87
  e && (e.watchMode = s.watchMode);
93
88
  }
94
89
  };
95
- C(
90
+ I(
96
91
  () => c.value.map(
97
92
  (s) => s.watchMode
98
93
  ),
99
94
  (s, e) => {
100
- s.forEach((o, r) => {
101
- if (l !== "modal" && o !== e[r] && c.value[r]?.info?.title !== "Drafts" && c.value[r]) {
102
- const i = c.value[r];
95
+ s.forEach((o, a) => {
96
+ if (l !== "modal" && o !== e[a] && c.value[a]?.info?.title !== "Drafts" && c.value[a]) {
97
+ const i = c.value[a];
103
98
  if (!i)
104
99
  return;
105
- const pe = `${i.info?.title}: Watch Mode ${o ? "enabled" : "disabled"}`;
106
- re(pe, "info");
100
+ const fe = `${i.info?.title}: Watch Mode ${o ? "enabled" : "disabled"}`;
101
+ se(fe, "info");
107
102
  }
108
103
  });
109
104
  }
110
105
  );
111
- const ce = I(() => {
112
- const s = x.value;
106
+ const ue = C(() => {
107
+ const s = w.value;
113
108
  if (!s.length)
114
109
  return "No results found";
115
- const e = s[w.value]?.item;
110
+ const e = s[x.value]?.item;
116
111
  if (!e)
117
112
  return "No result selected";
118
- const o = p.value.length ? `${s.length} result${s.length === 1 ? "" : "s"} found, ` : "", r = `, HTTP Method ${e.httpVerb}, Path ${e.path}`, i = `${e.title} ${r}`;
113
+ const o = p.value.length ? `${s.length} result${s.length === 1 ? "" : "s"} found, ` : "", a = `, HTTP Method ${e.httpVerb}, Path ${e.path}`, i = `${e.title} ${a}`;
119
114
  return `${o}Selected: ${i}`;
120
- }), de = () => {
115
+ }), ce = () => {
121
116
  const s = c.value.find(
122
117
  (o) => o.info?.title === "Drafts"
123
118
  );
124
119
  if (s && s.requests.forEach((o) => {
125
- y[o] && E.delete(y[o], s.uid);
126
- }), V.value.length) {
127
- const r = c.value[0]?.requests[0];
128
- r && L({
120
+ y[o] && V.delete(y[o], s.uid);
121
+ }), _.value.length) {
122
+ const a = c.value[0]?.requests[0];
123
+ a && E({
129
124
  name: "request",
130
125
  params: {
131
- [U.Request]: r
126
+ [U.Request]: a
132
127
  }
133
128
  });
134
129
  } else {
135
130
  const { request: o } = Be();
136
- s && (E.add(o, s.uid), L({
131
+ s && (V.add(o, s.uid), E({
137
132
  name: "request",
138
133
  params: {
139
134
  [U.Request]: o.uid
@@ -141,31 +136,31 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
141
136
  }));
142
137
  }
143
138
  };
144
- C(f, (s) => {
139
+ I(f, (s) => {
145
140
  s || (p.value = "");
146
141
  });
147
- const R = I(
142
+ const R = C(
148
143
  () => Ae(
149
144
  c.value,
150
- V.value,
145
+ _.value,
151
146
  y
152
147
  )
153
- ), me = I(() => l === "modal" && _.value ? [_.value] : c.value);
154
- function fe(s) {
148
+ ), de = C(() => l === "modal" && P.value ? [P.value] : c.value);
149
+ function me(s) {
155
150
  !p.value && s.relatedTarget !== B.value && (f.value = !1);
156
151
  }
157
- return (s, e) => (a(), v($, null, [
158
- ke(h(t(Ue), {
159
- class: b([t(T) ? "sidebar-active-width" : ""])
160
- }, Re({
152
+ return (s, e) => (r(), v($, null, [
153
+ Se(b(t(Ke), {
154
+ class: S([t(M) ? "sidebar-active-width" : ""])
155
+ }, ke({
161
156
  content: d(() => [
162
- n("div", je, [
157
+ n("div", Ge, [
163
158
  n("div", {
164
- class: b(["size-8", { "xl:hidden": t(l) !== "modal" }])
159
+ class: S(["size-8", { "xl:hidden": t(l) !== "modal" }])
165
160
  }, null, 2),
166
- t(l) !== "modal" ? (a(), u(t(Ge), { key: 0 })) : m("", !0),
167
- t(l) !== "modal" ? (a(), v("span", Je, " / ")) : m("", !0),
168
- t(l) !== "modal" ? (a(), u(_e, { key: 2 })) : m("", !0),
161
+ t(l) !== "modal" ? (r(), u(t(Ue), { key: 0 })) : m("", !0),
162
+ t(l) !== "modal" ? (r(), v("span", je, " / ")) : m("", !0),
163
+ t(l) !== "modal" ? (r(), u(Pe, { key: 2 })) : m("", !0),
169
164
  n("button", {
170
165
  ref_key: "searchToggleRef",
171
166
  ref: B,
@@ -174,33 +169,33 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
174
169
  type: "button",
175
170
  onClick: e[0] || (e[0] = (o) => f.value = !f.value)
176
171
  }, [
177
- n("span", Xe, A(f.value ? "Hide" : "Show") + " search ", 1),
178
- h(t(M), {
172
+ n("span", Qe, A(f.value ? "Hide" : "Show") + " search ", 1),
173
+ b(t(H), {
179
174
  class: "text-c-3 hover:bg-b-2 max-h-8 max-w-8 rounded-lg p-1.75 text-sm",
180
175
  icon: "Search"
181
176
  })
182
- ], 8, Qe)
177
+ ], 8, Je)
183
178
  ]),
184
- f.value ? (a(), v("div", Ye, [
185
- h(t(Ce), {
179
+ f.value ? (r(), v("div", Xe, [
180
+ b(t(xe), {
186
181
  ref_key: "searchInputRef",
187
- ref: O,
182
+ ref: N,
188
183
  modelValue: t(p),
189
- "onUpdate:modelValue": e[1] || (e[1] = (o) => ye(p) ? p.value = o : null),
184
+ "onUpdate:modelValue": e[1] || (e[1] = (o) => Re(p) ? p.value = o : null),
190
185
  autofocus: "",
191
- "aria-controls": t(N),
192
- label: ce.value,
193
- onInput: t(le),
186
+ "aria-controls": t(L),
187
+ label: ue.value,
188
+ onInput: t(re),
194
189
  onKeydown: [
195
- e[2] || (e[2] = q(g((o) => t(z)("down"), ["stop"]), ["down"])),
196
- e[3] || (e[3] = q(g((o) => t(ie)(), ["stop"]), ["enter"])),
197
- e[4] || (e[4] = q(g((o) => t(z)("up"), ["stop"]), ["up"]))
190
+ e[2] || (e[2] = q(h((o) => t(O)("down"), ["stop"]), ["down"])),
191
+ e[3] || (e[3] = q(h((o) => t(ne)(), ["stop"]), ["enter"])),
192
+ e[4] || (e[4] = q(h((o) => t(O)("up"), ["stop"]), ["up"]))
198
193
  ],
199
- onBlur: fe
194
+ onBlur: me
200
195
  }, null, 8, ["modelValue", "aria-controls", "label", "onInput"])
201
196
  ])) : m("", !0),
202
197
  n("div", {
203
- class: b(["gap-1/2 flex flex-1 flex-col overflow-visible overflow-y-auto px-3 pt-0 pb-3", [
198
+ class: S(["gap-1/2 flex flex-1 flex-col overflow-visible overflow-y-auto px-3 pt-0 pb-3", [
204
199
  {
205
200
  "pb-14": t(l) !== "modal"
206
201
  },
@@ -208,33 +203,33 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
208
203
  "h-[calc(100%-273.5px)]": R.value
209
204
  }
210
205
  ]]),
211
- onDragenter: e[7] || (e[7] = g(() => {
206
+ onDragenter: e[7] || (e[7] = h(() => {
212
207
  }, ["prevent"])),
213
- onDragover: e[8] || (e[8] = g(() => {
208
+ onDragover: e[8] || (e[8] = h(() => {
214
209
  }, ["prevent"]))
215
210
  }, [
216
- t(p) ? (a(), u(t(Ie), {
211
+ t(p) ? (r(), u(t(Ie), {
217
212
  key: 0,
218
- id: t(N),
213
+ id: t(L),
219
214
  "aria-label": "Search Results",
220
215
  class: "gap-px",
221
- noResults: !t(x).length
216
+ noResults: !t(w).length
222
217
  }, {
223
218
  default: d(() => [
224
- (a(!0), v($, null, H(t(x), (o, r) => (a(), u(t($e), {
219
+ (r(!0), v($, null, F(t(w), (o, a) => (r(), u(t(Ce), {
225
220
  id: `#search-input-${o.item.id}`,
226
221
  key: o.refIndex,
227
222
  ref_for: !0,
228
- ref: (i) => t(ne)[r] = i,
229
- selected: t(w) === r,
223
+ ref: (i) => t(le)[a] = i,
224
+ selected: t(x) === a,
230
225
  class: "px-2",
231
226
  href: o.item.link,
232
- onClick: g((i) => t(ae)(o), ["prevent"]),
233
- onFocus: (i) => w.value = r
227
+ onClick: h((i) => t(ae)(o), ["prevent"]),
228
+ onFocus: (i) => x.value = a
234
229
  }, {
235
230
  addon: d(() => [
236
231
  e[10] || (e[10] = n("span", { class: "sr-only" }, "HTTP Method:", -1)),
237
- h(Ve, {
232
+ b(_e, {
238
233
  class: "font-bold",
239
234
  method: o.item.httpVerb ?? "get"
240
235
  }, null, 8, ["method"])
@@ -246,40 +241,29 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
246
241
  }, 1032, ["id", "selected", "href", "onClick", "onFocus"]))), 128))
247
242
  ]),
248
243
  _: 1
249
- }, 8, ["id", "noResults"])) : (a(), v("nav", Ze, [
250
- (a(!0), v($, null, H(me.value, (o) => (a(), u(He, {
244
+ }, 8, ["id", "noResults"])) : (r(), v("nav", Ye, [
245
+ (r(!0), v($, null, F(de.value, (o) => (r(), u(Fe, {
251
246
  key: o.uid,
252
247
  isDraggable: t(l) !== "modal" && o.info?.title !== "Drafts",
253
- isDroppable: t(oe),
254
- menuItem: S,
248
+ isDroppable: t(te),
249
+ menuItem: g,
255
250
  parentUids: [],
256
251
  uid: o.uid,
257
- onNewTab: e[5] || (e[5] = (r, i) => j("newTab", { name: r, uid: i })),
258
- onOnDragEnd: t(te),
259
- onOpenMenu: e[6] || (e[6] = (r) => Object.assign(S, r))
252
+ onNewTab: e[5] || (e[5] = (a, i) => j("newTab", { name: a, uid: i })),
253
+ onOnDragEnd: t(ee),
254
+ onOpenMenu: e[6] || (e[6] = (a) => Object.assign(g, a))
260
255
  }, {
261
256
  leftIcon: d(() => [
262
- o.info?.title === "Drafts" ? (a(), u(t(M), {
257
+ o.info?.title === "Drafts" ? (r(), u(t(H), {
263
258
  key: 0,
264
- class: "text-sidebar-c-2 group-hover:hidden",
259
+ class: "text-sidebar-c-2",
265
260
  icon: "Scribble",
266
261
  thickness: "2.25"
267
- })) : (a(), u(t(De), {
262
+ })) : (r(), u(t($e), {
268
263
  key: 1,
269
- class: "text-sidebar-c-2 size-3.5 min-w-3.5 stroke-2 group-hover:hidden",
264
+ class: "text-sidebar-c-2 size-3.5 min-w-3.5 stroke-2",
270
265
  src: o["x-scalar-icon"] || "interface-content-folder"
271
- }, null, 8, ["src"])),
272
- n("div", {
273
- class: b({
274
- "rotate-90": t(J)[o.uid]
275
- })
276
- }, [
277
- h(t(M), {
278
- class: "text-c-3 hover:text-c-1 hidden text-sm group-hover:block",
279
- icon: "ChevronRight",
280
- size: "md"
281
- })
282
- ], 2)
266
+ }, null, 8, ["src"]))
283
267
  ]),
284
268
  _: 2
285
269
  }, 1032, ["isDraggable", "isDroppable", "menuItem", "uid", "onOnDragEnd"]))), 128))
@@ -288,18 +272,18 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
288
272
  ]),
289
273
  button: d(() => [
290
274
  n("div", {
291
- class: b({
275
+ class: S({
292
276
  "empty-sidebar-item": R.value
293
277
  })
294
278
  }, [
295
- R.value ? (a(), v("div", et, [
296
- n("div", tt, [
297
- h(K, {
298
- art: t(Te),
279
+ R.value ? (r(), v("div", Ze, [
280
+ n("div", et, [
281
+ b(K, {
282
+ art: t(Me),
299
283
  class: "rabbitsit font-bold"
300
284
  }, null, 8, ["art"]),
301
- h(K, {
302
- art: t(Pe),
285
+ b(K, {
286
+ art: t(Te),
303
287
  class: "rabbitjump absolute top-0 left-0 font-bold"
304
288
  }, null, 8, ["art"])
305
289
  ]),
@@ -308,19 +292,19 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
308
292
  n("p", { class: "mt-2" }, " Create request, folder, collection or import from OpenAPI/Postman ")
309
293
  ], -1))
310
294
  ])) : m("", !0),
311
- t(l) !== "modal" ? (a(), u(t(we), {
295
+ t(l) !== "modal" ? (r(), u(t(we), {
312
296
  key: 1,
313
- class: b(["mb-1.5 hidden h-fit w-full p-1.5 opacity-0", {
297
+ class: S(["mb-1.5 hidden h-fit w-full p-1.5 opacity-0", {
314
298
  "flex opacity-100": R.value
315
299
  }]),
316
- onClick: se
300
+ onClick: oe
317
301
  }, {
318
302
  default: d(() => [...e[12] || (e[12] = [
319
303
  D(" Import Collection ", -1)
320
304
  ])]),
321
305
  _: 1
322
306
  }, 8, ["class"])) : m("", !0),
323
- t(l) !== "modal" ? (a(), u(Le, {
307
+ t(l) !== "modal" ? (r(), u(Ee, {
324
308
  key: 2,
325
309
  click: t(k).commandPalette.emit,
326
310
  hotkey: "K"
@@ -340,18 +324,18 @@ const je = { class: "bg-b-1 sticky top-0 z-20 flex h-12 items-center px-3" }, Je
340
324
  key: "0"
341
325
  } : void 0
342
326
  ]), 1032, ["class"]), [
343
- [xe, t(T)]
327
+ [ye, t(M)]
344
328
  ]),
345
- t(l) !== "modal" && S ? (a(), u(We, {
329
+ t(l) !== "modal" && g ? (r(), u(ze, {
346
330
  key: 0,
347
- menuItem: S,
348
- onClearDrafts: de,
349
- onCloseMenu: e[9] || (e[9] = (o) => S.open = !1),
350
- onToggleWatchMode: ue
331
+ menuItem: g,
332
+ onClearDrafts: ce,
333
+ onCloseMenu: e[9] || (e[9] = (o) => g.open = !1),
334
+ onToggleWatchMode: ie
351
335
  }, null, 8, ["menuItem"])) : m("", !0)
352
336
  ], 64));
353
337
  }
354
338
  });
355
339
  export {
356
- $t as default
340
+ Ct as default
357
341
  };
@@ -1 +1 @@
1
- {"version":3,"file":"RequestSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItem.vue"],"names":[],"mappings":"AAksBA,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,YAAY,EACjB,KAAK,WAAW,EACjB,MAAM,mBAAmB,CAAA;AAa1B,OAAO,KAAK,EAAe,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEzE,KAAK,WAAW,GAAG;IACjB;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB;;;;OAIG;IACH,WAAW,CAAC,EAAE,cAAc,CAAC,aAAa,CAAC,CAAA;IAC3C,oEAAoE;IACpE,UAAU,EAAE,MAAM,EAAE,CAAA;IACpB,0DAA0D;IAC1D,GAAG,EAAE,MAAM,CAAA;IACX,2CAA2C;IAC3C,QAAQ,EAAE,eAAe,CAAA;CAC1B,CAAC;AAiBF,KAAK,WAAW,GAAG;IACjB,QAAQ,IAAI,IAAI,CAAA;CACjB,CAAC;AA6xCF,QAAA,MAAM,UAAU;;;;;;;;kFAGd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"RequestSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItem.vue"],"names":[],"mappings":"AAssBA,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,YAAY,EACjB,KAAK,WAAW,EACjB,MAAM,mBAAmB,CAAA;AAa1B,OAAO,KAAK,EAAe,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEzE,KAAK,WAAW,GAAG;IACjB;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB;;;;OAIG;IACH,WAAW,CAAC,EAAE,cAAc,CAAC,aAAa,CAAC,CAAA;IAC3C,oEAAoE;IACpE,UAAU,EAAE,MAAM,EAAE,CAAA;IACpB,0DAA0D;IAC1D,GAAG,EAAE,MAAM,CAAA;IACX,2CAA2C;IAC3C,QAAQ,EAAE,eAAe,CAAA;CAC1B,CAAC;AAiBF,KAAK,WAAW,GAAG;IACjB,QAAQ,IAAI,IAAI,CAAA;CACjB,CAAC;AA8zCF,QAAA,MAAM,UAAU;;;;;;;;kFAGd,CAAC;AACH,QAAA,MAAM,YAAY,EAAS,eAAe,CAAC,OAAO,UAAU,EAAE,WAAW,CAAC,CAAC;wBACtD,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KACV,CAAA;CACD,CAAC"}
@@ -2,7 +2,7 @@ import t from "./RequestSidebarItem.vue2.js";
2
2
  /* empty css */
3
3
  /* empty css */
4
4
  import o from "../../_virtual/_plugin-vue_export-helper.js";
5
- const a = /* @__PURE__ */ o(t, [["__scopeId", "data-v-f6414b95"]]);
5
+ const p = /* @__PURE__ */ o(t, [["__scopeId", "data-v-24d396a0"]]);
6
6
  export {
7
- a as default
7
+ p as default
8
8
  };