@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,14 +1,14 @@
1
- import { defineComponent as ne, useCssVars as oe, computed as c, ref as le, resolveComponent as re, openBlock as d, createElementBlock as k, normalizeClass as m, unref as s, createVNode as h, withCtx as g, createBlock as v, withModifiers as w, createElementVNode as l, toDisplayString as M, createCommentVNode as b, createTextVNode as A, renderSlot as ae, Fragment as ue, renderList as de } from "vue";
2
- import { useActiveEntities as pe } from "../../store/active-entities.js";
3
- import { ScalarButton as q, ScalarIcon as y, ScalarTooltip as fe } from "@scalar/components";
4
- import { Draggable as ce } from "@scalar/draggable";
5
- import { useRouter as me, RouterLink as ge } from "vue-router";
6
- import { PathId as ve } from "../../routes.js";
7
- import be from "../../components/HttpMethod/HttpMethod.vue.js";
8
- import { useSidebar as he } from "../../hooks/useSidebar.js";
9
- import { getModifiers as ye } from "../../libs/hot-keys.js";
10
- import { useWorkspace as xe } from "../../store/store.js";
11
- const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { class: "flex flex-row gap-1 items-center" }, qe = { class: "relative" }, Ue = { class: "flex items-start" }, De = ["aria-expanded"], Ce = { class: "flex h-5 items-center justify-center max-w-[14px]" }, Re = { class: "flex flex-1 flex-row justify-between" }, Te = { class: "break-all line-clamp-1 font-medium text-left w-full" }, Ie = { class: "relative flex justify-end h-fit" }, Me = { class: "grid gap-1.5 pointer-events-none max-w-10 w-content shadow-lg rounded bg-b-1 z-100 p-2 text-xxs leading-5 z-10 text-c-1" }, Ee = { class: "flex items-center text-c-2" }, $e = { class: "text-pretty break-all" }, ze = { key: 2 }, B = "hover:bg-sidebar-active-b indent-padding-left", Ye = /* @__PURE__ */ ne({
1
+ import { defineComponent as le, useCssVars as oe, computed as f, ref as ae, resolveComponent as ue, openBlock as u, createElementBlock as U, normalizeClass as c, unref as n, createVNode as y, withCtx as m, createBlock as v, withModifiers as q, createElementVNode as l, toDisplayString as E, createCommentVNode as g, createTextVNode as V, renderSlot as de, Fragment as pe, renderList as fe } from "vue";
2
+ import { useActiveEntities as ce } from "../../store/active-entities.js";
3
+ import { ScalarButton as D, ScalarIcon as x, ScalarTooltip as me } from "@scalar/components";
4
+ import { Draggable as ve } from "@scalar/draggable";
5
+ import { useRouter as ge, RouterLink as be } from "vue-router";
6
+ import { PathId as he } from "../../routes.js";
7
+ import ye from "../../components/HttpMethod/HttpMethod.vue.js";
8
+ import { useSidebar as xe } from "../../hooks/useSidebar.js";
9
+ import { getModifiers as ke } from "../../libs/hot-keys.js";
10
+ import { useWorkspace as we } from "../../store/store.js";
11
+ const Ue = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, qe = { class: "flex flex-row gap-1 items-center" }, De = { class: "relative" }, Ce = { class: "flex items-start" }, Re = ["aria-expanded"], Te = { class: "flex h-5 items-center justify-center max-w-[14px]" }, Ie = { class: "flex flex-1 flex-row justify-between" }, Me = { class: "break-all line-clamp-1 font-medium text-left w-full" }, Ee = { class: "relative flex justify-end h-fit" }, $e = { class: "grid gap-1.5 pointer-events-none max-w-10 w-content shadow-lg rounded bg-b-1 z-100 p-2 text-xxs leading-5 z-10 text-c-1" }, ze = { class: "flex items-center text-c-2" }, Se = { class: "text-pretty break-all" }, Ne = { key: 2 }, W = "hover:bg-sidebar-active-b indent-padding-left", Le = /* @__PURE__ */ le({
12
12
  __name: "RequestSidebarItem",
13
13
  props: {
14
14
  isDraggable: { type: Boolean, default: !1 },
@@ -18,27 +18,27 @@ const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { c
18
18
  menuItem: {}
19
19
  },
20
20
  emits: ["onDragEnd", "newTab", "openMenu"],
21
- setup(V, { emit: W }) {
21
+ setup(F, { emit: Y }) {
22
22
  oe((e) => ({
23
- b4d0afaa: Q.value,
24
- c4444c9a: X.value
23
+ "519a14d7": Z.value,
24
+ e7fbc4f2: _.value
25
25
  }));
26
- const n = V, F = W, { activeCollection: Y, activeRequest: E, activeRouterParams: H, activeWorkspace: U } = pe(), {
27
- collections: D,
28
- tags: L,
29
- isReadOnly: f,
30
- requests: $,
31
- requestExamples: C,
32
- collectionMutators: R,
33
- tagMutators: z,
34
- requestMutators: S,
35
- requestExampleMutators: N,
36
- events: G
37
- } = xe(), J = me(), { collapsedSidebarFolders: T, toggleSidebarFolder: K } = he(), i = c(() => {
38
- var o, p;
39
- const e = D[n.uid], t = L[n.uid], r = $[n.uid], a = C[n.uid];
26
+ const s = F, H = Y, { activeCollection: L, activeRequest: $, activeRouterParams: G, activeWorkspace: k } = ce(), {
27
+ collections: C,
28
+ tags: J,
29
+ isReadOnly: p,
30
+ requests: z,
31
+ requestExamples: R,
32
+ collectionMutators: T,
33
+ tagMutators: S,
34
+ requestMutators: N,
35
+ requestExampleMutators: O,
36
+ events: K
37
+ } = we(), Q = ge(), { collapsedSidebarFolders: I, toggleSidebarFolder: X } = xe(), i = f(() => {
38
+ var r, d, b, w;
39
+ const e = C[s.uid], t = J[s.uid], o = z[s.uid], a = R[s.uid];
40
40
  return e ? {
41
- title: ((o = e.info) == null ? void 0 : o.title) ?? "Unknown title",
41
+ title: ((r = e.info) == null ? void 0 : r.title) ?? "Unknown title",
42
42
  entity: e,
43
43
  resourceTitle: "Collection",
44
44
  children: e.children,
@@ -46,148 +46,166 @@ const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { c
46
46
  documentUrl: e.documentUrl,
47
47
  watchMode: e.watchMode,
48
48
  warning: "This cannot be undone. You’re about to delete the collection and all folders and requests inside it.",
49
- edit: (u, x) => {
50
- R.edit(e.uid, "info.title", u), x && R.edit(e.uid, "x-scalar-icon", x);
49
+ edit: (h, B) => {
50
+ T.edit(e.uid, "info.title", h), B && T.edit(e.uid, "x-scalar-icon", B);
51
51
  },
52
- delete: () => R.delete(e, U.value)
52
+ delete: () => {
53
+ k.value && T.delete(e, k.value);
54
+ }
53
55
  } : t ? {
54
56
  title: t.name,
55
57
  entity: t,
56
58
  resourceTitle: "Tag",
57
59
  children: t.children,
58
60
  warning: "This cannot be undone. You’re about to delete the tag and all requests inside it",
59
- edit: (u) => z.edit(t.uid, "name", u),
60
- delete: () => z.delete(t, n.parentUids[0])
61
- } : r ? {
62
- title: r.summary ?? r.path,
61
+ edit: (h) => S.edit(t.uid, "name", h),
62
+ delete: () => {
63
+ s.parentUids[0] && S.delete(t, s.parentUids[0]);
64
+ }
65
+ } : o ? {
66
+ title: o.summary ?? o.path,
63
67
  link: {
64
68
  name: "request",
65
69
  params: {
66
- workspace: U.value.uid,
67
- request: r.uid
70
+ workspace: (d = k.value) == null ? void 0 : d.uid,
71
+ request: o.uid
68
72
  }
69
73
  },
70
- method: r.method,
71
- entity: r,
74
+ method: o.method,
75
+ entity: o,
72
76
  resourceTitle: "Request",
73
77
  warning: "This cannot be undone. You’re about to delete the request.",
74
- children: r.examples.slice(1),
75
- edit: (u) => S.edit(r.uid, "summary", u),
76
- delete: () => S.delete(r, n.parentUids[0])
77
- } : {
78
+ children: o.examples.slice(1),
79
+ edit: (h) => N.edit(o.uid, "summary", h),
80
+ delete: () => {
81
+ s.parentUids[0] && N.delete(o, s.parentUids[0]);
82
+ }
83
+ } : a ? {
78
84
  title: a.name,
79
85
  link: {
80
86
  name: "request.examples",
81
87
  params: {
82
- workspace: U.value.uid,
88
+ workspace: (b = k.value) == null ? void 0 : b.uid,
83
89
  request: a.requestUid,
84
90
  examples: a.uid
85
91
  }
86
92
  },
87
- method: (p = $[a.requestUid]) == null ? void 0 : p.method,
93
+ method: (w = z[a.requestUid]) == null ? void 0 : w.method,
88
94
  entity: a,
89
95
  resourceTitle: "Example",
90
96
  warning: "This cannot be undone. You’re about to delete the example from the request.",
91
97
  children: [],
92
- edit: (u) => N.edit(a.uid, "name", u),
93
- delete: () => N.delete(a)
98
+ edit: (h) => O.edit(a.uid, "name", h),
99
+ delete: () => O.delete(a)
100
+ } : {
101
+ title: "Unknown",
102
+ entity: {
103
+ uid: "",
104
+ type: "unknown"
105
+ },
106
+ resourceTitle: "Unknown",
107
+ children: [],
108
+ edit: () => {
109
+ },
110
+ delete: () => {
111
+ }
94
112
  };
95
- }), O = c(
113
+ }), P = f(
96
114
  () => i.value.entity.type === "collection" && i.value.title === "Drafts"
97
- ), Q = c(() => n.parentUids.length ? f ? `${(n.parentUids.length - 1) * 12}px` : `${n.parentUids.length * 12}px` : "12px"), X = c(() => n.parentUids.length ? f ? `${(n.parentUids.length - 1) * 12}px` : `${n.parentUids.length * 12}px` : "0px"), Z = c(
115
+ ), Z = f(() => s.parentUids.length ? p ? `${(s.parentUids.length - 1) * 12}px` : `${s.parentUids.length * 12}px` : "12px"), _ = f(() => s.parentUids.length ? p ? `${(s.parentUids.length - 1) * 12}px` : `${s.parentUids.length * 12}px` : "0px"), ee = f(
98
116
  () => {
99
117
  var e;
100
- return T[n.uid] || ((e = E.value) == null ? void 0 : e.uid) === n.uid && i.value.entity.examples.length > 1;
118
+ return I[s.uid] || ((e = $.value) == null ? void 0 : e.uid) === s.uid && i.value.entity.examples.length > 1;
101
119
  }
102
- ), _ = c(
120
+ ), te = f(
103
121
  () => {
104
122
  var e;
105
- return H.value[ve.Request] === "default" && ((e = E.value) == null ? void 0 : e.uid) === n.uid;
123
+ return G.value[he.Request] === "default" && ((e = $.value) == null ? void 0 : e.uid) === s.uid;
106
124
  }
107
- ), I = le(null), P = c(() => {
125
+ ), M = ae(null), j = f(() => {
108
126
  let e = 0.5, t = 0.5;
109
- if (!I.value) return { ceiling: e, floor: t };
110
- const { draggingItem: r } = I.value;
111
- return !D[r == null ? void 0 : r.id] && i.value.entity.type === "collection" ? (e = 1, t = 0) : i.value.entity.type === "tag" && (e = 0.8, t = 0.2), { ceiling: e, floor: t };
112
- }), ee = (e, t) => !(f || C[t.id] || D[e.id]), te = (e, t) => {
113
- e && (ye(["default"]).some((o) => e[o]) ? F("newTab", t.title || "", t.entity.uid) : t.link && J.push(t.link));
127
+ if (!M.value) return { ceiling: e, floor: t };
128
+ const { draggingItem: o } = M.value;
129
+ return !C[o == null ? void 0 : o.id] && i.value.entity.type === "collection" ? (e = 1, t = 0) : i.value.entity.type === "tag" && (e = 0.8, t = 0.2), { ceiling: e, floor: t };
130
+ }), ie = (e, t) => !(p || R[t.id] || C[e.id]), ne = (e, t) => {
131
+ e && (ke(["default"]).some((r) => e[r]) ? H("newTab", t.title || "", t.entity.uid) : t.link && Q.push(t.link));
114
132
  };
115
- function j() {
116
- G.commandPalette.emit({
133
+ function A() {
134
+ K.commandPalette.emit({
117
135
  commandName: "Create Request",
118
136
  metaData: {
119
- itemUid: n.uid,
120
- parentUid: n.parentUids[0]
137
+ itemUid: s.uid,
138
+ parentUid: s.parentUids[0]
121
139
  }
122
140
  });
123
141
  }
124
- const ie = c(() => {
125
- const { uid: e, watchModeStatus: t } = Y.value || {};
142
+ const se = f(() => {
143
+ const { uid: e, watchModeStatus: t } = L.value || {};
126
144
  return e !== i.value.entity.uid ? "text-c-3" : t === "WATCHING" ? "text-c-1" : t === "ERROR" ? "text-red" : "text-c-3";
127
- }), se = c(() => i.value.title == "Drafts" && !f && i.value.children.length > 0);
145
+ }), re = f(() => i.value.title == "Drafts" && !p && i.value.children.length > 0);
128
146
  return (e, t) => {
129
- const r = re("RequestSidebarItem", !0);
130
- return d(), k("li", {
131
- class: m(["relative flex flex-row", [
132
- s(f) && e.parentUids.length > 1 || !s(f) && e.parentUids.length ? "before:bg-border before:pointer-events-none before:z-1 before:absolute before:left-[calc(.75rem_+_.5px)] before:top-0 before:h-[calc(100%_+_.5px)] last:before:h-full before:w-[.5px] mb-[.5px] last:mb-0 indent-border-line-offset" : ""
147
+ const o = ue("RequestSidebarItem", !0);
148
+ return u(), U("li", {
149
+ class: c(["relative flex flex-row", [
150
+ n(p) && e.parentUids.length > 1 || !n(p) && e.parentUids.length ? "before:bg-border before:pointer-events-none before:z-1 before:absolute before:left-[calc(.75rem_+_.5px)] before:top-0 before:h-[calc(100%_+_.5px)] last:before:h-full before:w-[.5px] mb-[.5px] last:mb-0 indent-border-line-offset" : ""
133
151
  ]])
134
152
  }, [
135
- h(s(ce), {
153
+ y(n(ve), {
136
154
  id: i.value.entity.uid,
137
155
  ref_key: "draggableRef",
138
- ref: I,
139
- ceiling: P.value.ceiling,
156
+ ref: M,
157
+ ceiling: j.value.ceiling,
140
158
  class: "flex flex-1 flex-col gap-[.5px] text-sm",
141
- floor: P.value.floor,
159
+ floor: j.value.floor,
142
160
  isDraggable: e.isDraggable,
143
161
  isDroppable: e.isDroppable,
144
162
  parentIds: e.parentUids,
145
163
  onOnDragEnd: t[9] || (t[9] = (...a) => e.$emit("onDragEnd", ...a))
146
164
  }, {
147
- default: g(() => {
165
+ default: m(() => {
148
166
  var a;
149
167
  return [
150
- i.value.link ? (d(), v(s(ge), {
168
+ i.value.link ? (u(), v(n(be), {
151
169
  key: 0,
152
170
  class: "group no-underline",
153
171
  to: i.value.link,
154
- onClick: t[1] || (t[1] = w(
155
- (o) => te(o, i.value),
172
+ onClick: t[1] || (t[1] = q(
173
+ (r) => ne(r, i.value),
156
174
  ["prevent"]
157
175
  ))
158
176
  }, {
159
- default: g(({ isExactActive: o }) => {
160
- var p, u;
177
+ default: m(({ isExactActive: r }) => {
178
+ var d, b;
161
179
  return [
162
180
  l("div", {
163
- class: m(["relative flex min-h-8 cursor-pointer flex-row items-start justify-between gap-0.5 py-1.5 pr-2 rounded w-full", [
164
- B,
165
- o || _.value ? "bg-sidebar-active-b text-sidebar-active-c transition-none" : "text-sidebar-c-2"
181
+ class: c(["relative flex min-h-8 cursor-pointer flex-row items-start justify-between gap-0.5 py-1.5 pr-2 rounded w-full", [
182
+ W,
183
+ r || te.value ? "bg-sidebar-active-b text-sidebar-active-c transition-none" : "text-sidebar-c-2"
166
184
  ]])
167
185
  }, [
168
- l("span", ke, M(i.value.title), 1),
169
- l("div", we, [
170
- l("div", qe, [
171
- s(f) ? b("", !0) : (d(), v(s(q), {
186
+ l("span", Ue, E(i.value.title), 1),
187
+ l("div", qe, [
188
+ l("div", De, [
189
+ n(p) ? g("", !0) : (u(), v(n(D), {
172
190
  key: 0,
173
- class: m(["hidden px-0.5 py-0 hover:bg-b-3 opacity-0 group-hover:opacity-100 group-hover:flex group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100 aspect-square h-fit", {
174
- flex: ((u = (p = e.menuItem) == null ? void 0 : p.item) == null ? void 0 : u.entity.uid) === i.value.entity.uid && e.menuItem.open
191
+ class: c(["hidden px-0.5 py-0 hover:bg-b-3 opacity-0 group-hover:opacity-100 group-hover:flex group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100 aspect-square h-fit", {
192
+ flex: ((b = (d = e.menuItem) == null ? void 0 : d.item) == null ? void 0 : b.entity.uid) === i.value.entity.uid && e.menuItem.open
175
193
  }]),
176
194
  size: "sm",
177
195
  type: "button",
178
196
  variant: "ghost",
179
- onClick: t[0] || (t[0] = w(
180
- (x) => e.$emit("openMenu", {
197
+ onClick: t[0] || (t[0] = q(
198
+ (w) => e.$emit("openMenu", {
181
199
  item: i.value,
182
200
  parentUids: e.parentUids,
183
- targetRef: x.currentTarget,
201
+ targetRef: w.currentTarget,
184
202
  open: !e.menuItem.open
185
203
  }),
186
204
  ["stop", "prevent"]
187
205
  ))
188
206
  }, {
189
- default: g(() => [
190
- h(s(y), {
207
+ default: m(() => [
208
+ y(n(x), {
191
209
  icon: "Ellipses",
192
210
  size: "md"
193
211
  })
@@ -195,84 +213,84 @@ const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { c
195
213
  _: 1
196
214
  }, 8, ["class"]))
197
215
  ]),
198
- l("span", Ue, [
199
- t[10] || (t[10] = A("   ")),
216
+ l("span", Ce, [
217
+ t[10] || (t[10] = V("   ")),
200
218
  t[11] || (t[11] = l("span", { class: "sr-only" }, "HTTP Method:", -1)),
201
- i.value.method ? (d(), v(s(be), {
219
+ i.value.method ? (u(), v(n(ye), {
202
220
  key: 0,
203
221
  class: "font-bold",
204
222
  method: i.value.method
205
- }, null, 8, ["method"])) : b("", !0)
223
+ }, null, 8, ["method"])) : g("", !0)
206
224
  ])
207
225
  ])
208
226
  ], 2)
209
227
  ];
210
228
  }),
211
229
  _: 1
212
- }, 8, ["to"])) : !s(f) || e.parentUids.length ? (d(), k("button", {
230
+ }, 8, ["to"])) : !n(p) || e.parentUids.length ? (u(), U("button", {
213
231
  key: 1,
214
- "aria-expanded": s(T)[i.value.entity.uid],
215
- class: m(["hover:bg-b-2 group relative flex w-full flex-row justify-start gap-1.5 rounded p-1.5 focus-visible:z-10", [B]]),
232
+ "aria-expanded": n(I)[i.value.entity.uid],
233
+ class: c(["hover:bg-b-2 group relative flex w-full flex-row justify-start gap-1.5 rounded p-1.5 focus-visible:z-10", [W]]),
216
234
  type: "button",
217
- onClick: t[4] || (t[4] = (o) => s(K)(i.value.entity.uid))
235
+ onClick: t[4] || (t[4] = (r) => n(X)(i.value.entity.uid))
218
236
  }, [
219
- l("span", Ce, [
220
- ae(e.$slots, "leftIcon", {}, () => [
237
+ l("span", Te, [
238
+ de(e.$slots, "leftIcon", {}, () => [
221
239
  l("div", {
222
- class: m({
223
- "rotate-90": s(T)[i.value.entity.uid]
240
+ class: c({
241
+ "rotate-90": n(I)[i.value.entity.uid]
224
242
  })
225
243
  }, [
226
- h(s(y), {
244
+ y(n(x), {
227
245
  class: "text-c-3 text-sm",
228
246
  icon: "ChevronRight",
229
247
  size: "md"
230
248
  })
231
249
  ], 2)
232
250
  ], !0),
233
- t[12] || (t[12] = A("   "))
251
+ t[12] || (t[12] = V("   "))
234
252
  ]),
235
- l("div", Re, [
236
- l("span", Te, M(i.value.title), 1),
237
- l("div", Ie, [
253
+ l("div", Ie, [
254
+ l("span", Me, E(i.value.title), 1),
255
+ l("div", Ee, [
238
256
  l("div", {
239
- class: m(["items-center opacity-0 gap-px group-hover:opacity-100 group-hover:flex group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
257
+ class: c(["items-center opacity-0 gap-px group-hover:opacity-100 group-hover:flex group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
240
258
  flex: e.menuItem.open,
241
259
  hidden: !e.menuItem.open || ((a = e.menuItem.item) == null ? void 0 : a.entity.uid) !== i.value.entity.uid
242
260
  }])
243
261
  }, [
244
- !s(f) && !O.value || O.value && se.value ? (d(), v(s(q), {
262
+ !n(p) && !P.value || P.value && re.value ? (u(), v(n(D), {
245
263
  key: 0,
246
264
  class: "px-0.5 py-0 hover:bg-b-3 hover:text-c-1 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100 aspect-square h-fit",
247
265
  size: "sm",
248
266
  variant: "ghost",
249
- onClick: t[2] || (t[2] = w(
250
- (o) => e.$emit("openMenu", {
267
+ onClick: t[2] || (t[2] = q(
268
+ (r) => e.$emit("openMenu", {
251
269
  item: i.value,
252
270
  parentUids: e.parentUids,
253
- targetRef: o.currentTarget.parentNode,
271
+ targetRef: r.currentTarget.parentNode,
254
272
  open: !0
255
273
  }),
256
274
  ["stop", "prevent"]
257
275
  ))
258
276
  }, {
259
- default: g(() => [
260
- h(s(y), {
277
+ default: m(() => [
278
+ y(n(x), {
261
279
  icon: "Ellipses",
262
280
  size: "md"
263
281
  })
264
282
  ]),
265
283
  _: 1
266
- })) : b("", !0),
267
- s(f) ? b("", !0) : (d(), v(s(q), {
284
+ })) : g("", !0),
285
+ n(p) ? g("", !0) : (u(), v(n(D), {
268
286
  key: 1,
269
287
  class: "px-0.5 py-0 hover:bg-b-3 hover:text-c-1 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100 aspect-square h-fit",
270
288
  size: "sm",
271
289
  variant: "ghost",
272
- onClick: t[3] || (t[3] = w((o) => j(), ["stop", "prevent"]))
290
+ onClick: t[3] || (t[3] = q((r) => A(), ["stop", "prevent"]))
273
291
  }, {
274
- default: g(() => [
275
- h(s(y), {
292
+ default: m(() => [
293
+ y(n(x), {
276
294
  icon: "Add",
277
295
  size: "md",
278
296
  thickness: "2"
@@ -281,52 +299,52 @@ const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { c
281
299
  _: 1
282
300
  }))
283
301
  ], 2),
284
- i.value.watchMode ? (d(), v(s(fe), {
302
+ i.value.watchMode ? (u(), v(n(me), {
285
303
  key: 0,
286
304
  side: "right",
287
305
  sideOffset: 12
288
306
  }, {
289
- trigger: g(() => [
290
- h(s(y), {
291
- class: m(["ml-0.5 text-sm", ie.value]),
307
+ trigger: m(() => [
308
+ y(n(x), {
309
+ class: c(["ml-0.5 text-sm", se.value]),
292
310
  icon: "Watch",
293
311
  size: "md",
294
312
  thickness: "2"
295
313
  }, null, 8, ["class"])
296
314
  ]),
297
- content: g(() => [
298
- l("div", Me, [
299
- l("div", Ee, [
300
- l("p", $e, " Watching: " + M(i.value.documentUrl), 1)
315
+ content: m(() => [
316
+ l("div", $e, [
317
+ l("div", ze, [
318
+ l("p", Se, " Watching: " + E(i.value.documentUrl), 1)
301
319
  ])
302
320
  ])
303
321
  ]),
304
322
  _: 1
305
- })) : b("", !0),
323
+ })) : g("", !0),
306
324
  t[13] || (t[13] = l("span", null, " ", -1))
307
325
  ])
308
326
  ])
309
- ], 10, De)) : b("", !0),
310
- Z.value ? (d(), k("ul", ze, [
311
- (d(!0), k(ue, null, de(i.value.children, (o) => (d(), v(r, {
312
- key: o,
313
- isDraggable: !s(C)[o],
314
- isDroppable: ee,
327
+ ], 10, Re)) : g("", !0),
328
+ ee.value ? (u(), U("ul", Ne, [
329
+ (u(!0), U(pe, null, fe(i.value.children, (r) => (u(), v(o, {
330
+ key: r,
331
+ isDraggable: !n(R)[r],
332
+ isDroppable: ie,
315
333
  menuItem: e.menuItem,
316
334
  parentUids: [...e.parentUids, e.uid],
317
- uid: o,
318
- onNewTab: t[5] || (t[5] = (p, u) => e.$emit("newTab", p, u)),
319
- onOnDragEnd: t[6] || (t[6] = (...p) => e.$emit("onDragEnd", ...p)),
320
- onOpenMenu: t[7] || (t[7] = (p) => e.$emit("openMenu", p))
335
+ uid: r,
336
+ onNewTab: t[5] || (t[5] = (d, b) => e.$emit("newTab", d, b)),
337
+ onOnDragEnd: t[6] || (t[6] = (...d) => e.$emit("onDragEnd", ...d)),
338
+ onOpenMenu: t[7] || (t[7] = (d) => e.$emit("openMenu", d))
321
339
  }, null, 8, ["isDraggable", "menuItem", "parentUids", "uid"]))), 128)),
322
- i.value.children.length === 0 ? (d(), v(s(q), {
340
+ i.value.children.length === 0 ? (u(), v(n(D), {
323
341
  key: 0,
324
- class: m(["mb-[.5px] flex gap-1.5 h-8 text-c-1 py-0 justify-start text-xs w-full hover:bg-b-2", e.parentUids.length ? "pl-9" : ""]),
342
+ class: c(["mb-[.5px] flex gap-1.5 h-8 text-c-1 py-0 justify-start text-xs w-full hover:bg-b-2", e.parentUids.length ? "pl-9" : ""]),
325
343
  variant: "ghost",
326
- onClick: t[8] || (t[8] = (o) => j())
344
+ onClick: t[8] || (t[8] = (r) => A())
327
345
  }, {
328
- default: g(() => [
329
- h(s(y), {
346
+ default: m(() => [
347
+ y(n(x), {
330
348
  class: "mx-0.5 h-2.5 w-2.5",
331
349
  icon: "Add",
332
350
  thickness: "3"
@@ -334,8 +352,8 @@ const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { c
334
352
  t[14] || (t[14] = l("span", null, "Add Request", -1))
335
353
  ]),
336
354
  _: 1
337
- }, 8, ["class"])) : b("", !0)
338
- ])) : b("", !0)
355
+ }, 8, ["class"])) : g("", !0)
356
+ ])) : g("", !0)
339
357
  ];
340
358
  }),
341
359
  _: 3
@@ -345,5 +363,5 @@ const ke = { class: "break-all line-clamp-1 font-medium w-full pl-2" }, we = { c
345
363
  }
346
364
  });
347
365
  export {
348
- Ye as default
366
+ Le as default
349
367
  };
@@ -1 +1 @@
1
- {"version":3,"file":"RequestSidebarItemMenu.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItemMenu.vue"],"names":[],"mappings":"AA8QA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAe5D,KAAK,WAAW,GAAG;IAAE,QAAQ,EAAE,eAAe,CAAA;CAAE,CAAC;;;;;;;;;;AA+iBjD,wBAOG"}
1
+ {"version":3,"file":"RequestSidebarItemMenu.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItemMenu.vue"],"names":[],"mappings":"AA+QA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAgB5D,KAAK,WAAW,GAAG;IAAE,QAAQ,EAAE,eAAe,CAAA;CAAE,CAAC;;;;;;;;;;AA+iBjD,wBAOG"}
@@ -1,7 +1,7 @@
1
- import t from "./RequestSidebarItemMenu.vue2.js";
1
+ import e from "./RequestSidebarItemMenu.vue2.js";
2
2
  /* empty css */
3
- import e from "../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ e(t, [["__scopeId", "data-v-4505d1d7"]]);
3
+ import t from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ t(e, [["__scopeId", "data-v-99ca1ebd"]]);
5
5
  export {
6
- a as default
6
+ m as default
7
7
  };