@scalar/api-client 2.2.21 → 2.2.23

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 (144) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
  3. package/dist/components/AddressBar/AddressBar.vue.js +2 -2
  4. package/dist/components/AddressBar/AddressBar.vue2.js +70 -71
  5. package/dist/components/AddressBar/AddressBarServer.vue.js +26 -26
  6. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  7. package/dist/components/CodeInput/CodeInput.vue.js +2 -2
  8. package/dist/components/CodeInput/CodeInput.vue2.js +46 -46
  9. package/dist/components/CodeInput/codeVariableWidget.d.ts +4 -4
  10. package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -1
  11. package/dist/components/CodeInput/codeVariableWidget.js +42 -38
  12. package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +25 -24
  13. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts +1 -1
  14. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts.map +1 -1
  15. package/dist/components/CommandPalette/CommandPaletteExample.vue.js +64 -55
  16. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
  17. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +110 -106
  18. package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +2 -2
  19. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +1 -1
  20. package/dist/components/CommandPalette/TheCommandPalette.vue.js +1 -1
  21. package/dist/components/CommandPalette/TheCommandPalette.vue2.js +38 -37
  22. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.d.ts.map +1 -1
  23. package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +52 -49
  24. package/dist/components/ImportCollection/DropEventListener.vue.d.ts.map +1 -1
  25. package/dist/components/ImportCollection/DropEventListener.vue.js +46 -43
  26. package/dist/components/ImportCollection/ImportCollectionModal.vue.js +40 -39
  27. package/dist/components/ImportCollection/ImportNowButton.vue.js +44 -42
  28. package/dist/components/ImportCollection/WorkspaceSelector.vue.js +76 -69
  29. package/dist/components/ScalarAsciiArt.vue.js +1 -1
  30. package/dist/components/ScalarAsciiArt.vue2.js +22 -19
  31. package/dist/components/Search/useSearch.d.ts.map +1 -1
  32. package/dist/components/Search/useSearch.js +57 -49
  33. package/dist/components/SideNav/SideNavRouterLink.vue.d.ts.map +1 -1
  34. package/dist/components/SideNav/SideNavRouterLink.vue.js +22 -19
  35. package/dist/components/Sidebar/Sidebar.vue.d.ts +2 -2
  36. package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
  37. package/dist/components/Sidebar/Sidebar.vue.js +2 -2
  38. package/dist/components/Sidebar/Sidebar.vue2.js +16 -16
  39. package/dist/components/Sidebar/SidebarListElement.vue.d.ts.map +1 -1
  40. package/dist/components/Sidebar/SidebarListElement.vue.js +2 -2
  41. package/dist/components/Sidebar/SidebarListElement.vue2.js +38 -36
  42. package/dist/components/Sidebar/SidebarToggle.vue.d.ts.map +1 -1
  43. package/dist/components/Sidebar/SidebarToggle.vue.js +3 -3
  44. package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
  45. package/dist/components/TopNav/TopNav.vue.js +71 -64
  46. package/dist/layouts/App/ApiClientApp.vue.js +4 -1
  47. package/dist/layouts/App/create-api-client-app.d.ts +2 -1
  48. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  49. package/dist/layouts/Modal/ApiClientModal.vue.js +2 -2
  50. package/dist/layouts/Modal/ApiClientModal.vue2.js +22 -19
  51. package/dist/layouts/Modal/create-api-client-modal.d.ts +4 -2
  52. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  53. package/dist/layouts/Web/ApiClientWeb.vue.js +4 -1
  54. package/dist/layouts/Web/create-api-client-web.d.ts +2 -1
  55. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  56. package/dist/libs/create-client.d.ts +12 -11
  57. package/dist/libs/create-client.d.ts.map +1 -1
  58. package/dist/libs/create-client.js +54 -47
  59. package/dist/libs/extractAttachmentFilename.d.ts +3 -0
  60. package/dist/libs/extractAttachmentFilename.d.ts.map +1 -1
  61. package/dist/libs/extractAttachmentFilename.js +7 -7
  62. package/dist/libs/importers/curl.d.ts.map +1 -1
  63. package/dist/libs/importers/curl.js +18 -18
  64. package/dist/libs/normalize-headers.d.ts.map +1 -1
  65. package/dist/libs/normalize-headers.js +2 -2
  66. package/dist/libs/parse-curl.js +39 -36
  67. package/dist/store/active-entities.d.ts +4 -4
  68. package/dist/store/active-entities.d.ts.map +1 -1
  69. package/dist/store/active-entities.js +88 -86
  70. package/dist/store/collections.d.ts.map +1 -1
  71. package/dist/store/collections.js +29 -29
  72. package/dist/store/request-example.d.ts.map +1 -1
  73. package/dist/store/request-example.js +27 -23
  74. package/dist/store/requests.d.ts.map +1 -1
  75. package/dist/store/requests.js +94 -77
  76. package/dist/store/security-schemes.d.ts.map +1 -1
  77. package/dist/store/security-schemes.js +27 -27
  78. package/dist/store/servers.d.ts.map +1 -1
  79. package/dist/store/servers.js +18 -18
  80. package/dist/store/store.d.ts +5 -5
  81. package/dist/store/store.d.ts.map +1 -1
  82. package/dist/store/store.js +53 -48
  83. package/dist/store/tags.d.ts.map +1 -1
  84. package/dist/store/tags.js +35 -33
  85. package/dist/style.css +1 -1
  86. package/dist/views/Cookies/CookieForm.vue.d.ts.map +1 -1
  87. package/dist/views/Cookies/CookieForm.vue.js +14 -9
  88. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  89. package/dist/views/Cookies/Cookies.vue2.js +39 -37
  90. package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
  91. package/dist/views/Environment/Environment.vue2.js +94 -89
  92. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  93. package/dist/views/Request/Request.vue.js +1 -1
  94. package/dist/views/Request/Request.vue2.js +118 -119
  95. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.d.ts.map +1 -1
  96. package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +28 -25
  97. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
  98. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +1 -1
  99. package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +38 -37
  100. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.d.ts.map +1 -1
  101. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +2 -2
  102. package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue2.js +76 -73
  103. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.js +2 -2
  104. package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue2.js +80 -80
  105. package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
  106. package/dist/views/Request/RequestSection/RequestBody.vue.js +1 -1
  107. package/dist/views/Request/RequestSection/RequestBody.vue2.js +192 -178
  108. package/dist/views/Request/RequestSection/RequestParams.vue.d.ts.map +1 -1
  109. package/dist/views/Request/RequestSection/RequestParams.vue.js +80 -73
  110. package/dist/views/Request/RequestSection/RequestPathParams.vue.d.ts.map +1 -1
  111. package/dist/views/Request/RequestSection/RequestPathParams.vue.js +50 -48
  112. package/dist/views/Request/RequestSidebar.vue.d.ts +3 -4
  113. package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
  114. package/dist/views/Request/RequestSidebar.vue.js +1 -1
  115. package/dist/views/Request/RequestSidebar.vue2.js +166 -164
  116. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  117. package/dist/views/Request/RequestSidebarItem.vue.js +2 -2
  118. package/dist/views/Request/RequestSidebarItem.vue2.js +168 -150
  119. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
  120. package/dist/views/Request/RequestSidebarItemMenu.vue.js +4 -4
  121. package/dist/views/Request/RequestSidebarItemMenu.vue2.js +80 -80
  122. package/dist/views/Request/RequestSubpageHeader.vue.d.ts +0 -1
  123. package/dist/views/Request/RequestSubpageHeader.vue.d.ts.map +1 -1
  124. package/dist/views/Request/RequestSubpageHeader.vue.js +2 -2
  125. package/dist/views/Request/RequestSubpageHeader.vue2.js +44 -49
  126. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  127. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +1 -1
  128. package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +1 -1
  129. package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -1
  130. package/dist/views/Request/components/WorkspaceDropdown.vue.js +166 -156
  131. package/dist/views/Request/handle-drag.d.ts.map +1 -1
  132. package/dist/views/Request/handle-drag.js +37 -31
  133. package/dist/views/Request/hooks/useOpenApiWatcher.js +27 -27
  134. package/dist/views/Request/libs/live-sync.d.ts.map +1 -1
  135. package/dist/views/Request/libs/live-sync.js +147 -130
  136. package/dist/views/Request/types/sidebar-item.d.ts +4 -1
  137. package/dist/views/Request/types/sidebar-item.d.ts.map +1 -1
  138. package/dist/views/Servers/ServerForm.vue.js +38 -35
  139. package/dist/views/Servers/Servers.vue2.js +38 -35
  140. package/dist/views/Settings/Settings.vue.d.ts.map +1 -1
  141. package/dist/views/Settings/Settings.vue2.js +15 -15
  142. package/dist/views/Settings/SettingsGeneral.vue.d.ts.map +1 -1
  143. package/dist/views/Settings/SettingsGeneral.vue.js +206 -174
  144. package/package.json +6 -6
@@ -1,25 +1,25 @@
1
- import { defineComponent as ce, useId as me, reactive as pe, watch as A, onMounted as fe, onBeforeUnmount as be, computed as he, ref as ve, openBlock as r, createElementBlock as S, Fragment as C, withDirectives as F, createVNode as u, unref as s, normalizeClass as f, createSlots as Se, withCtx as d, createElementVNode as i, createBlock as l, createCommentVNode as b, isRef as ye, withKeys as x, withModifiers as h, vShow as K, renderList as N, createTextVNode as $, toDisplayString as Re, nextTick as ge } from "vue";
2
- import ke from "../../assets/rabbit.ascii.js";
3
- import we from "../../assets/rabbitjump.ascii.js";
4
- import Ie from "../../components/EnvironmentSelector/EnvironmentSelector.vue.js";
5
- import Ce from "../../components/HttpMethod/HttpMethod.vue.js";
6
- import U from "../../components/ScalarAsciiArt.vue.js";
7
- import { useSearch as xe } from "../../components/Search/useSearch.js";
1
+ import { defineComponent as ce, useId as pe, reactive as me, watch as A, onMounted as fe, onBeforeUnmount as be, computed as ve, ref as he, openBlock as r, createElementBlock as k, Fragment as $, withDirectives as F, createVNode as p, unref as t, normalizeClass as v, createSlots as Se, withCtx as c, createElementVNode as i, createBlock as u, createCommentVNode as h, isRef as ge, withKeys as O, withModifiers as S, vShow as K, renderList as N, createTextVNode as D, toDisplayString as ke, nextTick as Re } from "vue";
2
+ import ye from "../../assets/rabbit.ascii.js";
3
+ import xe from "../../assets/rabbitjump.ascii.js";
4
+ import we from "../../components/EnvironmentSelector/EnvironmentSelector.vue.js";
5
+ import Ie from "../../components/HttpMethod/HttpMethod.vue.js";
6
+ import L from "../../components/ScalarAsciiArt.vue.js";
7
+ import { useSearch as Ce } from "../../components/Search/useSearch.js";
8
8
  import $e from "../../components/Sidebar/SidebarButton.vue.js";
9
- import qe from "../../components/Sidebar/SidebarToggle.vue.js";
9
+ import Oe from "../../components/Sidebar/SidebarToggle.vue.js";
10
10
  import { useActiveEntities as De } from "../../store/active-entities.js";
11
- import { createInitialRequest as Me } from "../../store/requests.js";
12
- import Ve from "./RequestSidebarItemMenu.vue.js";
13
- import { dragHandlerFactory as Te } from "./handle-drag.js";
14
- import { ScalarIcon as q, ScalarSearchInput as Pe, ScalarSearchResultList as Ee, ScalarSearchResultItem as Be, ScalarButton as Oe } from "@scalar/components";
11
+ import { createInitialRequest as qe } from "../../store/requests.js";
12
+ import Me from "./RequestSidebarItemMenu.vue.js";
13
+ import { dragHandlerFactory as Ve } from "./handle-drag.js";
14
+ import { ScalarIcon as q, ScalarSearchInput as Te, ScalarSearchResultList as Pe, ScalarSearchResultItem as Ee, ScalarButton as Be } from "@scalar/components";
15
15
  import { LibraryIcon as We } from "@scalar/icons";
16
16
  import { useToasts as ze } from "@scalar/use-toasts";
17
17
  import { useRouter as Ae } from "vue-router";
18
18
  import Fe from "./RequestSidebarItem.vue.js";
19
19
  import Ke from "../../components/Sidebar/Sidebar.vue.js";
20
20
  import Ne from "./components/WorkspaceDropdown.vue.js";
21
- import { useLayout as Ue } from "../../hooks/useLayout.js";
22
- import { useWorkspace as Le } from "../../store/store.js";
21
+ import { useLayout as Le } from "../../hooks/useLayout.js";
22
+ import { useWorkspace as Ue } from "../../store/store.js";
23
23
  import { useSidebar as He } from "../../hooks/useSidebar.js";
24
24
  const je = { class: "flex items-center h-[48px] px-3 top-0 bg-b-1 sticky z-20" }, Ge = {
25
25
  key: 1,
@@ -30,224 +30,226 @@ const je = { class: "flex items-center h-[48px] px-3 top-0 bg-b-1 sticky z-20" }
30
30
  }, Qe = {
31
31
  key: 1,
32
32
  class: "contents"
33
- }, Xe = { class: "empty-sidebar-item-content px-2.5 py-2.5" }, Ye = { class: "w-[60px] h-[68px] m-auto rabbit-ascii mt-2 relative" }, gt = /* @__PURE__ */ ce({
33
+ }, Xe = { class: "empty-sidebar-item-content px-2.5 py-2.5" }, Ye = { class: "w-[60px] h-[68px] m-auto rabbit-ascii mt-2 relative" }, Rt = /* @__PURE__ */ ce({
34
34
  __name: "RequestSidebar",
35
35
  props: {
36
- showSidebar: { type: Boolean },
37
- isReadonly: { type: Boolean }
36
+ isSidebarOpen: { type: Boolean }
38
37
  },
39
- emits: ["update:modelValue", "update:showSidebar", "newTab", "clearDrafts"],
40
- setup(L, { emit: H }) {
41
- const D = L, M = H, { layout: V } = Ue();
42
- console.log("layout", V);
43
- const T = Le(), {
44
- activeWorkspaceCollections: m,
45
- activeRequest: j,
46
- activeWorkspaceRequests: R,
47
- activeWorkspace: g
48
- } = De(), { findRequestParents: G, isReadOnly: J, events: y, requestMutators: P, requests: Q } = T, { handleDragEnd: X, isDroppable: Y } = Te(
49
- g,
50
- T
38
+ emits: ["update:modelValue", "update:isSidebarOpen", "newTab", "clearDrafts"],
39
+ setup(U, { emit: H }) {
40
+ const j = U, M = H, { layout: G } = Le(), V = Ue(), {
41
+ activeWorkspaceCollections: f,
42
+ activeRequest: J,
43
+ activeWorkspaceRequests: y,
44
+ activeWorkspace: x
45
+ } = De(), { findRequestParents: Q, isReadOnly: l, events: R, requestMutators: T, requests: P } = V, { handleDragEnd: X, isDroppable: Y } = Ve(
46
+ x,
47
+ V
51
48
  ), { collapsedSidebarFolders: Z, setCollapsedSidebarFolder: _ } = He(), { replace: E } = Ae(), ee = () => {
52
- y.commandPalette.emit({
49
+ R.commandPalette.emit({
53
50
  commandName: "Import from OpenAPI/Swagger/Postman"
54
51
  });
55
- }, B = me(), { toast: te } = ze(), v = pe({ open: !1 });
52
+ }, B = pe(), { toast: te } = ze(), g = me({ open: !1 });
56
53
  A(
57
- j,
58
- (e) => {
59
- e && G(e).forEach(
60
- (t) => _(t, !0)
54
+ J,
55
+ (s) => {
56
+ s && Q(s).forEach(
57
+ (e) => _(e, !0)
61
58
  );
62
59
  },
63
60
  { immediate: !0 }
64
61
  );
65
62
  const {
66
- searchText: c,
67
- searchResultsWithPlaceholderResults: k,
68
- selectedSearchResult: w,
69
- onSearchResultClick: oe,
70
- fuseSearch: se,
71
- searchInputRef: I,
63
+ searchText: m,
64
+ searchResultsWithPlaceholderResults: w,
65
+ selectedSearchResult: I,
66
+ onSearchResultClick: se,
67
+ fuseSearch: oe,
68
+ searchInputRef: C,
72
69
  searchResultRefs: ae,
73
- navigateSearchResults: O,
70
+ navigateSearchResults: W,
74
71
  selectSearchResult: re
75
- } = xe(), W = (e) => {
76
- var t;
77
- e && (e.toggleSidebar && M("update:showSidebar", D.showSidebar), e.focusRequestSearch && ((t = I.value) == null || t.focus()));
72
+ } = Ce(), z = (s) => {
73
+ var e;
74
+ s && (s.toggleSidebar && M("update:isSidebarOpen", j.isSidebarOpen), s.focusRequestSearch && ((e = C.value) == null || e.focus()));
78
75
  };
79
- fe(() => y.hotKeys.on(W)), be(() => {
80
- y.hotKeys.off(W);
76
+ fe(() => R.hotKeys.on(z)), be(() => {
77
+ R.hotKeys.off(z);
81
78
  });
82
- const ne = (e) => {
83
- if (e != null && e.documentUrl) {
84
- e.watchMode = !e.watchMode;
85
- const t = m.value.find(
86
- (o) => o.uid === e.entity.uid
79
+ const ne = (s) => {
80
+ if (s != null && s.documentUrl) {
81
+ s.watchMode = !s.watchMode;
82
+ const e = f.value.find(
83
+ (o) => o.uid === s.entity.uid
87
84
  );
88
- t && (t.watchMode = e.watchMode);
85
+ e && (e.watchMode = s.watchMode);
89
86
  }
90
87
  };
91
88
  A(
92
- () => m.value.map((e) => e.watchMode),
93
- (e, t) => {
94
- e.forEach((o, a) => {
95
- var n;
96
- if (!D.isReadonly && o !== t[a]) {
97
- const ue = `${(n = m.value[a].info) == null ? void 0 : n.title}: Watch Mode ${o ? "enabled" : "disabled"}`;
89
+ () => f.value.map((s) => s.watchMode),
90
+ (s, e) => {
91
+ s.forEach((o, n) => {
92
+ var a;
93
+ if (!l && o !== e[n]) {
94
+ const d = f.value[n];
95
+ if (!d) return;
96
+ const ue = `${(a = d.info) == null ? void 0 : a.title}: Watch Mode ${o ? "enabled" : "disabled"}`;
98
97
  te(ue, "info");
99
98
  }
100
99
  });
101
100
  }
102
101
  );
103
- const ie = he(() => {
104
- var t;
105
- const e = k.value[w.value];
106
- return (t = e == null ? void 0 : e.item) != null && t.id ? `#search-input-${e.item.id}` : void 0;
102
+ const ie = ve(() => {
103
+ var e;
104
+ const s = w.value[I.value];
105
+ return (e = s == null ? void 0 : s.item) != null && e.id ? `#search-input-${s.item.id}` : void 0;
107
106
  }), le = () => {
108
- const e = m.value.find(
109
- (o) => {
110
- var a;
111
- return ((a = o.info) == null ? void 0 : a.title) === "Drafts";
107
+ var o, n;
108
+ const s = f.value.find(
109
+ (a) => {
110
+ var d;
111
+ return ((d = a.info) == null ? void 0 : d.title) === "Drafts";
112
112
  }
113
113
  );
114
- if (e && e.requests.forEach((o) => {
115
- P.delete(Q[o], e.uid);
116
- }), R.value.length) {
117
- const o = m.value[0], a = o == null ? void 0 : o.requests[0];
118
- a && E(`/workspace/${g.value.uid}/request/${a}`);
114
+ if (s && s.requests.forEach((a) => {
115
+ P[a] && T.delete(P[a], s.uid);
116
+ }), y.value.length) {
117
+ const a = f.value[0], d = a == null ? void 0 : a.requests[0];
118
+ d && E(
119
+ `/workspace/${(n = x.value) == null ? void 0 : n.uid}/request/${d}`
120
+ );
119
121
  } else {
120
- const { request: o } = Me();
121
- e && (P.add(o, e.uid), E(`/workspace/${g.value.uid}/request/${o.uid}`));
122
+ const { request: a } = qe();
123
+ s && (T.add(a, s.uid), E(`/workspace/${(o = x.value) == null ? void 0 : o.uid}/request/${a.uid}`));
122
124
  }
123
- }, p = ve(!1), de = () => {
124
- p.value = !p.value, p.value || (c.value = ""), p.value && ge(() => {
125
- var e;
126
- (e = I.value) == null || e.focus();
125
+ }, b = he(!1), de = () => {
126
+ b.value = !b.value, b.value || (m.value = ""), b.value && Re(() => {
127
+ var s;
128
+ (s = C.value) == null || s.focus();
127
129
  });
128
130
  };
129
- return (e, t) => (r(), S(C, null, [
130
- F(u(s(Ke), {
131
- class: f([e.showSidebar ? "sidebar-active-width" : ""]),
132
- showSidebar: e.showSidebar,
133
- "onUpdate:showSidebar": t[10] || (t[10] = (o) => e.$emit("update:showSidebar", o))
131
+ return (s, e) => (r(), k($, null, [
132
+ F(p(t(Ke), {
133
+ class: v([s.isSidebarOpen ? "sidebar-active-width" : ""]),
134
+ isSidebarOpen: s.isSidebarOpen,
135
+ "onUpdate:isSidebarOpen": e[10] || (e[10] = (o) => s.$emit("update:isSidebarOpen", o))
134
136
  }, Se({
135
- content: d(() => [
137
+ content: c(() => [
136
138
  i("div", je, [
137
- u(qe, {
138
- class: f(["gitbook-hidden xl:hidden", [{ "!flex": s(V) === "modal" }]]),
139
- modelValue: e.showSidebar,
140
- "onUpdate:modelValue": t[0] || (t[0] = (o) => e.$emit("update:showSidebar", o))
139
+ p(Oe, {
140
+ class: v(["xl:hidden", [{ "!flex": t(G) === "modal" }]]),
141
+ modelValue: s.isSidebarOpen,
142
+ "onUpdate:modelValue": e[0] || (e[0] = (o) => s.$emit("update:isSidebarOpen", o))
141
143
  }, null, 8, ["class", "modelValue"]),
142
- e.isReadonly ? b("", !0) : (r(), l(s(Ne), { key: 0 })),
143
- e.isReadonly ? b("", !0) : (r(), S("span", Ge, "/")),
144
- e.isReadonly ? b("", !0) : (r(), l(Ie, { key: 2 })),
144
+ t(l) ? h("", !0) : (r(), u(t(Ne), { key: 0 })),
145
+ t(l) ? h("", !0) : (r(), k("span", Ge, " / ")),
146
+ t(l) ? h("", !0) : (r(), u(we, { key: 2 })),
145
147
  i("button", {
146
148
  class: "ml-auto",
147
149
  type: "button",
148
150
  onClick: de
149
151
  }, [
150
- u(s(q), {
152
+ p(t(q), {
151
153
  class: "text-c-3 text-sm hover:bg-b-2 p-1.75 rounded-lg max-w-8 max-h-8",
152
154
  icon: "Search"
153
155
  })
154
156
  ])
155
157
  ]),
156
158
  F(i("div", Je, [
157
- u(s(Pe), {
159
+ p(t(Te), {
158
160
  ref_key: "searchInputRef",
159
- ref: I,
160
- modelValue: s(c),
161
- "onUpdate:modelValue": t[1] || (t[1] = (o) => ye(c) ? c.value = o : null),
161
+ ref: C,
162
+ modelValue: t(m),
163
+ "onUpdate:modelValue": e[1] || (e[1] = (o) => ge(m) ? m.value = o : null),
162
164
  "aria-activedescendant": ie.value,
163
- "aria-controls": s(B),
165
+ "aria-controls": t(B),
164
166
  sidebar: "",
165
- onBlur: t[2] || (t[2] = (o) => p.value = s(c).length > 0),
166
- onInput: s(se),
167
+ onBlur: e[2] || (e[2] = (o) => b.value = t(m).length > 0),
168
+ onInput: t(oe),
167
169
  onKeydown: [
168
- t[3] || (t[3] = x(h((o) => s(O)("down"), ["stop"]), ["down"])),
169
- t[4] || (t[4] = x(h((o) => s(re)(), ["stop"]), ["enter"])),
170
- t[5] || (t[5] = x(h((o) => s(O)("up"), ["stop"]), ["up"]))
170
+ e[3] || (e[3] = O(S((o) => t(W)("down"), ["stop"]), ["down"])),
171
+ e[4] || (e[4] = O(S((o) => t(re)(), ["stop"]), ["enter"])),
172
+ e[5] || (e[5] = O(S((o) => t(W)("up"), ["stop"]), ["up"]))
171
173
  ]
172
174
  }, null, 8, ["modelValue", "aria-activedescendant", "aria-controls", "onInput"])
173
175
  ], 512), [
174
- [K, p.value || s(c)]
176
+ [K, b.value || t(m)]
175
177
  ]),
176
178
  i("div", {
177
- class: f(["flex flex-1 flex-col overflow-visible px-3 pb-3 pt-0", {
178
- "pb-14": !e.isReadonly
179
+ class: v(["flex flex-1 flex-col overflow-visible px-3 pb-3 pt-0", {
180
+ "pb-14": !t(l)
179
181
  }]),
180
- onDragenter: t[8] || (t[8] = h(() => {
182
+ onDragenter: e[8] || (e[8] = S(() => {
181
183
  }, ["prevent"])),
182
- onDragover: t[9] || (t[9] = h(() => {
184
+ onDragover: e[9] || (e[9] = S(() => {
183
185
  }, ["prevent"]))
184
186
  }, [
185
- s(c) ? (r(), l(s(Ee), {
187
+ t(m) ? (r(), u(t(Pe), {
186
188
  key: 0,
187
- id: s(B),
189
+ id: t(B),
188
190
  "aria-label": "Search Results",
189
191
  class: "gap-px",
190
- noResults: !s(k).length
192
+ noResults: !t(w).length
191
193
  }, {
192
- default: d(() => [
193
- (r(!0), S(C, null, N(s(k), (o, a) => (r(), l(s(Be), {
194
+ default: c(() => [
195
+ (r(!0), k($, null, N(t(w), (o, n) => (r(), u(t(Ee), {
194
196
  id: `#search-input-${o.item.id}`,
195
197
  key: o.refIndex,
196
198
  ref_for: !0,
197
- ref: (n) => s(ae)[a] = n,
198
- active: s(w) === a,
199
+ ref: (a) => t(ae)[n] = a,
200
+ active: t(I) === n,
199
201
  class: "px-2",
200
202
  href: o.item.link,
201
- onClick: h((n) => s(oe)(o), ["prevent"]),
202
- onFocus: (n) => w.value = a
203
+ onClick: S((a) => t(se)(o), ["prevent"]),
204
+ onFocus: (a) => I.value = n
203
205
  }, {
204
- addon: d(() => [
205
- t[12] || (t[12] = i("span", { class: "sr-only" }, "HTTP Method:", -1)),
206
- u(Ce, {
206
+ addon: c(() => [
207
+ e[12] || (e[12] = i("span", { class: "sr-only" }, "HTTP Method:", -1)),
208
+ p(Ie, {
207
209
  class: "font-bold",
208
210
  method: o.item.httpVerb ?? "get"
209
211
  }, null, 8, ["method"])
210
212
  ]),
211
- default: d(() => [
212
- $(Re(o.item.title) + " ", 1)
213
+ default: c(() => [
214
+ D(ke(o.item.title) + " ", 1)
213
215
  ]),
214
216
  _: 2
215
217
  }, 1032, ["id", "active", "href", "onClick", "onFocus"]))), 128))
216
218
  ]),
217
219
  _: 1
218
- }, 8, ["id", "noResults"])) : (r(), S("nav", Qe, [
219
- (r(!0), S(C, null, N(s(m), (o) => {
220
- var a;
221
- return r(), l(Fe, {
220
+ }, 8, ["id", "noResults"])) : (r(), k("nav", Qe, [
221
+ (r(!0), k($, null, N(t(f), (o) => {
222
+ var n;
223
+ return r(), u(Fe, {
222
224
  key: o.uid,
223
- isDraggable: !e.isReadonly && ((a = o.info) == null ? void 0 : a.title) !== "Drafts",
224
- isDroppable: s(Y),
225
- menuItem: v,
225
+ isDraggable: !t(l) && ((n = o.info) == null ? void 0 : n.title) !== "Drafts",
226
+ isDroppable: t(Y),
227
+ menuItem: g,
226
228
  parentUids: [],
227
229
  uid: o.uid,
228
- onNewTab: t[6] || (t[6] = (n, z) => M("newTab", { name: n, uid: z })),
229
- onOnDragEnd: s(X),
230
- onOpenMenu: t[7] || (t[7] = (n) => Object.assign(v, n))
230
+ onNewTab: e[6] || (e[6] = (a, d) => M("newTab", { name: a, uid: d })),
231
+ onOnDragEnd: t(X),
232
+ onOpenMenu: e[7] || (e[7] = (a) => Object.assign(g, a))
231
233
  }, {
232
- leftIcon: d(() => {
233
- var n;
234
+ leftIcon: c(() => {
235
+ var a;
234
236
  return [
235
- ((n = o.info) == null ? void 0 : n.title) === "Drafts" ? (r(), l(s(q), {
237
+ ((a = o.info) == null ? void 0 : a.title) === "Drafts" ? (r(), u(t(q), {
236
238
  key: 0,
237
239
  class: "text-sidebar-c-2 group-hover:hidden",
238
240
  icon: "Scribble",
239
241
  thickness: "2.25"
240
- })) : (r(), l(s(We), {
242
+ })) : (r(), u(t(We), {
241
243
  key: 1,
242
244
  class: "min-w-3.5 text-sidebar-c-2 size-3.5 stroke-2 group-hover:hidden",
243
245
  src: o["x-scalar-icon"] || "interface-content-folder"
244
246
  }, null, 8, ["src"])),
245
247
  i("div", {
246
- class: f({
247
- "rotate-90": s(Z)[o.uid]
248
+ class: v({
249
+ "rotate-90": t(Z)[o.uid]
248
250
  })
249
251
  }, [
250
- u(s(q), {
252
+ p(t(q), {
251
253
  class: "text-c-3 hidden text-sm group-hover:block",
252
254
  icon: "ChevronRight",
253
255
  size: "md"
@@ -261,47 +263,47 @@ const je = { class: "flex items-center h-[48px] px-3 top-0 bg-b-1 sticky z-20" }
261
263
  ]))
262
264
  ], 34)
263
265
  ]),
264
- button: d(() => [
266
+ button: c(() => [
265
267
  i("div", {
266
- class: f({
267
- "empty-sidebar-item": s(R).length <= 1
268
+ class: v({
269
+ "empty-sidebar-item": t(y).length <= 1
268
270
  })
269
271
  }, [
270
272
  i("div", Xe, [
271
273
  i("div", Ye, [
272
- u(U, {
273
- art: s(ke),
274
+ p(L, {
275
+ art: t(ye),
274
276
  class: "font-bold rabbitsit"
275
277
  }, null, 8, ["art"]),
276
- u(U, {
277
- art: s(we),
278
+ p(L, {
279
+ art: t(xe),
278
280
  class: "font-bold absolute top-0 left-0 rabbitjump"
279
281
  }, null, 8, ["art"])
280
282
  ]),
281
- t[13] || (t[13] = i("div", { class: "text-center text-balance text-sm mb-2 mt-2" }, [
283
+ e[13] || (e[13] = i("div", { class: "text-center text-balance text-sm mb-2 mt-2" }, [
282
284
  i("b", { class: "font-medium" }, "Let's Get Started"),
283
285
  i("p", { class: "mt-2" }, " Create request, folder, collection or import from OpenAPI/Postman ")
284
286
  ], -1))
285
287
  ]),
286
- e.isReadonly ? b("", !0) : (r(), l(s(Oe), {
288
+ t(l) ? h("", !0) : (r(), u(t(Be), {
287
289
  key: 0,
288
- class: f(["mb-1.5 w-full h-fit hidden opacity-0 p-1.5", {
289
- "flex opacity-100": s(R).length <= 1
290
+ class: v(["mb-1.5 w-full h-fit hidden opacity-0 p-1.5", {
291
+ "flex opacity-100": t(y).length <= 1
290
292
  }]),
291
293
  onClick: ee
292
294
  }, {
293
- default: d(() => t[14] || (t[14] = [
294
- $(" Import Collection ")
295
+ default: c(() => e[14] || (e[14] = [
296
+ D(" Import Collection ")
295
297
  ])),
296
298
  _: 1
297
299
  }, 8, ["class"])),
298
- e.isReadonly ? b("", !0) : (r(), l($e, {
300
+ t(l) ? h("", !0) : (r(), u($e, {
299
301
  key: 1,
300
- click: s(y).commandPalette.emit,
302
+ click: t(R).commandPalette.emit,
301
303
  hotkey: "K"
302
304
  }, {
303
- title: d(() => t[15] || (t[15] = [
304
- $("Add Item")
305
+ title: c(() => e[15] || (e[15] = [
306
+ D("Add Item")
305
307
  ])),
306
308
  _: 1
307
309
  }, 8, ["click"]))
@@ -309,24 +311,24 @@ const je = { class: "flex items-center h-[48px] px-3 top-0 bg-b-1 sticky z-20" }
309
311
  ]),
310
312
  _: 2
311
313
  }, [
312
- e.isReadonly ? void 0 : {
314
+ t(l) ? void 0 : {
313
315
  name: "header",
314
- fn: d(() => []),
316
+ fn: c(() => []),
315
317
  key: "0"
316
318
  }
317
- ]), 1032, ["class", "showSidebar"]), [
318
- [K, e.showSidebar]
319
+ ]), 1032, ["class", "isSidebarOpen"]), [
320
+ [K, s.isSidebarOpen]
319
321
  ]),
320
- !s(J) && v ? (r(), l(Ve, {
322
+ !t(l) && g ? (r(), u(Me, {
321
323
  key: 0,
322
- menuItem: v,
324
+ menuItem: g,
323
325
  onClearDrafts: le,
324
- onCloseMenu: t[11] || (t[11] = (o) => v.open = !1),
326
+ onCloseMenu: e[11] || (e[11] = (o) => g.open = !1),
325
327
  onToggleWatchMode: ne
326
- }, null, 8, ["menuItem"])) : b("", !0)
328
+ }, null, 8, ["menuItem"])) : h("", !0)
327
329
  ], 64));
328
330
  }
329
331
  });
330
332
  export {
331
- gt as default
333
+ Rt as default
332
334
  };
@@ -1 +1 @@
1
- {"version":3,"file":"RequestSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItem.vue"],"names":[],"mappings":"AAifA,OAAO,KAAK,EAAe,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEzE,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,YAAY,EACjB,KAAK,WAAW,EACjB,MAAM,mBAAmB,CAAA;AAO1B,KAAK,WAAW,GAAG;IACf;;;;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;AA+OJ,iBAAS,cAAc;WAggBT,OAAO,IAA6B;;oBAjuBpC,IAAI;;oBAAJ,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qCArDlB,KAtcW;;;;;;;oCAscX,KA/bsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCAsvB6B,GAAG,8CAA8C,GAAG,yBACpF,GAAG,6DAAmC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAme3D;AAkCD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;iBApyBH,OAAO;uFA6yBvB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"RequestSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItem.vue"],"names":[],"mappings":"AAugBA,OAAO,KAAK,EAAe,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEzE,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,YAAY,EACjB,KAAK,WAAW,EACjB,MAAM,mBAAmB,CAAA;AAO1B,KAAK,WAAW,GAAG;IACf;;;;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;AAqQJ,iBAAS,cAAc;WAggBT,OAAO,IAA6B;;oBAvvBpC,IAAI;;oBAAJ,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qCArDlB,KA5dW;;;;;;;oCA4dX,KArdsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wCA+wBuD,GAAG,8CAGrD,GAAG,yBAAyB,GAAG,6DAC3C,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmfjB;AAkCD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;;;iBA1zBH,OAAO;uFAm0BvB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAgBpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -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-390bf191"]]);
5
+ const p = /* @__PURE__ */ o(t, [["__scopeId", "data-v-29c563a2"]]);
6
6
  export {
7
- a as default
7
+ p as default
8
8
  };