@scalar/api-client 2.2.57 → 2.2.60

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 (75) hide show
  1. package/CHANGELOG.md +51 -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 +88 -80
  5. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  6. package/dist/components/CodeInput/CodeInput.vue.js +1 -1
  7. package/dist/components/CodeInput/CodeInput.vue2.js +93 -81
  8. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +2 -0
  9. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
  10. package/dist/components/IconSelector.vue.d.ts.map +1 -1
  11. package/dist/components/IconSelector.vue.js +1 -0
  12. package/dist/components/SectionFilter.vue.d.ts +23 -0
  13. package/dist/components/SectionFilter.vue.d.ts.map +1 -0
  14. package/dist/components/SectionFilter.vue.js +7 -0
  15. package/dist/components/SectionFilter.vue2.js +67 -0
  16. package/dist/components/SectionFilterButton.vue.d.ts +22 -0
  17. package/dist/components/SectionFilterButton.vue.d.ts.map +1 -0
  18. package/dist/components/SectionFilterButton.vue.js +23 -0
  19. package/dist/components/SectionFilterButton.vue2.js +4 -0
  20. package/dist/components/Server/ServerDropdown.vue.d.ts.map +1 -1
  21. package/dist/components/Server/ServerDropdown.vue.js +1 -0
  22. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
  23. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +62 -44
  24. package/dist/layouts/App/create-api-client-app.d.ts +16 -5
  25. package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
  26. package/dist/layouts/Modal/create-api-client-modal.d.ts +32 -10
  27. package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
  28. package/dist/layouts/Web/create-api-client-web.d.ts +16 -5
  29. package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
  30. package/dist/libs/create-client.d.ts +15 -4
  31. package/dist/libs/create-client.d.ts.map +1 -1
  32. package/dist/libs/find-request.d.ts +1 -0
  33. package/dist/libs/find-request.d.ts.map +1 -1
  34. package/dist/libs/send-request/create-request-operation.test.d.ts +1 -0
  35. package/dist/libs/send-request/create-request-operation.test.d.ts.map +1 -1
  36. package/dist/store/active-entities.d.ts +1 -0
  37. package/dist/store/active-entities.d.ts.map +1 -1
  38. package/dist/store/events.d.ts +4 -0
  39. package/dist/store/events.d.ts.map +1 -1
  40. package/dist/store/events.js +4 -0
  41. package/dist/store/requests.d.ts +15 -4
  42. package/dist/store/requests.d.ts.map +1 -1
  43. package/dist/store/store.d.ts +15 -4
  44. package/dist/store/store.d.ts.map +1 -1
  45. package/dist/style.css +1 -1
  46. package/dist/views/Components/CodeSnippet/helpers/get-snippet.d.ts.map +1 -1
  47. package/dist/views/Components/CodeSnippet/helpers/get-snippet.js +10 -10
  48. package/dist/views/Request/RequestSection/RequestBody.vue.js +3 -3
  49. package/dist/views/Request/RequestSection/RequestBody.vue2.js +1 -1
  50. package/dist/views/Request/RequestSection/RequestCodeExample.test.d.ts +2 -0
  51. package/dist/views/Request/RequestSection/RequestCodeExample.test.d.ts.map +1 -0
  52. package/dist/views/Request/RequestSection/RequestCodeExample.vue.d.ts.map +1 -1
  53. package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +2 -2
  54. package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +36 -36
  55. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  56. package/dist/views/Request/RequestSection/RequestSection.vue.js +2 -2
  57. package/dist/views/Request/RequestSection/RequestSection.vue2.js +103 -83
  58. package/dist/views/Request/RequestSidebarItem.vue.d.ts +2 -1
  59. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  60. package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
  61. package/dist/views/Request/RequestSidebarItem.vue2.js +81 -81
  62. package/dist/views/Request/ResponseSection/ResponseBody.vue.js +1 -1
  63. package/dist/views/Request/ResponseSection/ResponseBody.vue2.js +9 -9
  64. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.d.ts.map +1 -1
  65. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.js +2 -2
  66. package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue2.js +26 -21
  67. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  68. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  69. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +1 -1
  70. package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +80 -65
  71. package/package.json +15 -15
  72. package/dist/components/ContextBar.vue.d.ts +0 -11
  73. package/dist/components/ContextBar.vue.d.ts.map +0 -1
  74. package/dist/components/ContextBar.vue.js +0 -7
  75. package/dist/components/ContextBar.vue2.js +0 -47
@@ -1,16 +1,16 @@
1
- import { defineComponent as ve, useCssVars as ge, computed as b, ref as be, resolveComponent as ye, openBlock as u, createElementBlock as C, normalizeClass as y, unref as n, createVNode as v, withCtx as c, createBlock as f, withModifiers as U, createElementVNode as s, toDisplayString as D, createCommentVNode as m, createTextVNode as E, renderSlot as X, Fragment as Z, renderList as he } from "vue";
2
- import { ScalarButton as R, ScalarIcon as h, ScalarSidebarGroupToggle as _, ScalarTooltip as ee } from "@scalar/components";
3
- import { Draggable as xe } from "@scalar/draggable";
4
- import { shouldIgnoreEntity as te } from "@scalar/oas-utils/helpers";
5
- import { useRouter as ke, RouterLink as ie } from "vue-router";
6
- import { useLayout as we } from "../../hooks/useLayout.js";
7
- import { useSidebar as Ue } from "../../hooks/useSidebar.js";
8
- import { useActiveEntities as qe } from "../../store/active-entities.js";
1
+ import { defineComponent as ve, useCssVars as ge, computed as b, ref as be, resolveComponent as ye, openBlock as u, createElementBlock as C, normalizeClass as y, unref as n, createVNode as v, withCtx as c, createBlock as f, withModifiers as U, createElementVNode as s, toDisplayString as D, createCommentVNode as m, createTextVNode as E, renderSlot as Z, Fragment as _, renderList as he, nextTick as xe } from "vue";
2
+ import { ScalarButton as R, ScalarIcon as h, ScalarSidebarGroupToggle as ee, ScalarTooltip as te } from "@scalar/components";
3
+ import { Draggable as ke } from "@scalar/draggable";
4
+ import { shouldIgnoreEntity as ie } from "@scalar/oas-utils/helpers";
5
+ import { useRouter as we, RouterLink as ne } from "vue-router";
6
+ import { useLayout as Ue } from "../../hooks/useLayout.js";
7
+ import { useSidebar as qe } from "../../hooks/useSidebar.js";
8
+ import { useActiveEntities as Ce } from "../../store/active-entities.js";
9
9
  import { PathId as S } from "../../routes.js";
10
- import Ce from "../../components/HttpMethod/HttpMethod.vue.js";
11
- import { getModifiers as De } from "../../libs/hot-keys.js";
12
- import { useWorkspace as Re } from "../../store/store.js";
13
- const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { class: "flex flex-row items-center gap-1" }, ze = { class: "relative" }, Me = { class: "flex items-start" }, $e = ["aria-expanded"], Ee = { class: "flex flex-1 flex-row justify-between font-medium" }, Se = { class: "line-clamp-1 w-full break-all text-left" }, Be = { class: "relative flex h-fit justify-end" }, je = { class: "w-content bg-b-1 z-100 text-xxs text-c-1 pointer-events-none z-10 grid max-w-10 gap-1.5 rounded p-2 leading-5 shadow-lg" }, We = { class: "text-c-2 flex items-center" }, Ne = { class: "text-pretty break-all" }, Oe = ["aria-expanded"], Ae = { class: "flex h-5 max-w-[14px] items-center justify-center" }, Pe = { class: "flex flex-1 flex-row justify-between" }, Ve = { class: "line-clamp-1 w-full break-all text-left font-medium" }, Fe = { class: "relative flex h-fit justify-end" }, Ye = { class: "w-content bg-b-1 z-100 text-xxs text-c-1 pointer-events-none z-10 grid max-w-10 gap-1.5 rounded p-2 leading-5 shadow-lg" }, He = { class: "text-c-2 flex items-center" }, Le = { class: "text-pretty break-all" }, Ge = { key: 3 }, P = "hover:bg-sidebar-active-b indent-padding-left", ot = /* @__PURE__ */ ve({
10
+ import De from "../../components/HttpMethod/HttpMethod.vue.js";
11
+ import { getModifiers as Re } from "../../libs/hot-keys.js";
12
+ import { useWorkspace as Ie } from "../../store/store.js";
13
+ const Te = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, ze = { class: "flex flex-row items-center gap-1" }, Me = { class: "relative" }, $e = { class: "flex items-start" }, Ee = ["aria-expanded"], Se = { class: "flex flex-1 flex-row justify-between font-medium" }, Be = { class: "line-clamp-1 w-full break-all text-left" }, je = { class: "relative flex h-fit justify-end" }, We = { class: "w-content bg-b-1 z-100 text-xxs text-c-1 pointer-events-none z-10 grid max-w-10 gap-1.5 rounded p-2 leading-5 shadow-lg" }, Ae = { class: "text-c-2 flex items-center" }, Ne = { class: "text-pretty break-all" }, Oe = ["aria-expanded"], Pe = { class: "flex h-5 max-w-[14px] items-center justify-center" }, Ve = { class: "flex flex-1 flex-row justify-between" }, Fe = { class: "line-clamp-1 w-full break-all text-left font-medium" }, Ye = { class: "relative flex h-fit justify-end" }, He = { class: "w-content bg-b-1 z-100 text-xxs text-c-1 pointer-events-none z-10 grid max-w-10 gap-1.5 rounded p-2 leading-5 shadow-lg" }, Le = { class: "text-c-2 flex items-center" }, Ge = { class: "text-pretty break-all" }, Ke = { key: 3 }, P = "hover:bg-sidebar-active-b indent-padding-left", at = /* @__PURE__ */ ve({
14
14
  __name: "RequestSidebarItem",
15
15
  props: {
16
16
  isDraggable: { type: Boolean, default: !1 },
@@ -20,23 +20,23 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
20
20
  menuItem: {}
21
21
  },
22
22
  emits: ["onDragEnd", "newTab", "openMenu"],
23
- setup(l, { emit: ne }) {
23
+ setup(l, { emit: se }) {
24
24
  ge((e) => ({
25
- "98b93bde": re.value,
26
- "24740e0d": ue.value
25
+ f1b25d28: re.value,
26
+ "30af9cd2": ue.value
27
27
  }));
28
- const se = ne, { activeCollection: le, activeRequest: V, activeRouterParams: oe, activeWorkspace: q } = qe(), {
28
+ const le = se, { activeCollection: oe, activeRequest: V, activeRouterParams: ae, activeWorkspace: q } = Ce(), {
29
29
  collections: T,
30
30
  tags: z,
31
31
  requests: B,
32
32
  requestExamples: j,
33
33
  collectionMutators: W,
34
34
  tagMutators: F,
35
- requestMutators: N,
35
+ requestMutators: A,
36
36
  requestExampleMutators: Y,
37
- events: ae
38
- } = Re(), x = ke(), { collapsedSidebarFolders: I, toggleSidebarFolder: H } = Ue(), { layout: p } = we(), i = b(() => {
39
- var g, o, d, k, $, J;
37
+ events: H
38
+ } = Ie(), x = we(), { collapsedSidebarFolders: I, toggleSidebarFolder: L } = qe(), { layout: p } = Ue(), i = b(() => {
39
+ var g, o, d, k, $, Q;
40
40
  const e = T[l.uid], t = z[l.uid], r = B[l.uid], a = j[l.uid];
41
41
  return e ? {
42
42
  title: ((g = e.info) == null ? void 0 : g.title) || "Untitled Collection",
@@ -54,8 +54,8 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
54
54
  }
55
55
  } : void 0,
56
56
  warning: "This cannot be undone. You’re about to delete the collection and all folders and requests inside it.",
57
- edit: (w, Q) => {
58
- W.edit(e.uid, "info.title", w), Q && W.edit(e.uid, "x-scalar-icon", Q);
57
+ edit: (w, X) => {
58
+ W.edit(e.uid, "info.title", w), X && W.edit(e.uid, "x-scalar-icon", X);
59
59
  },
60
60
  delete: () => {
61
61
  q.value && W.delete(e, q.value);
@@ -82,8 +82,8 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
82
82
  resourceTitle: "Request",
83
83
  warning: "This cannot be undone. You’re about to delete the request.",
84
84
  children: r.examples.slice(1),
85
- edit: (w) => N.edit(r.uid, "summary", w),
86
- delete: () => l.parentUids[0] && N.delete(r, l.parentUids[0])
85
+ edit: (w) => A.edit(r.uid, "summary", w),
86
+ delete: () => l.parentUids[0] && A.delete(r, l.parentUids[0])
87
87
  } : a != null && a.requestUid ? {
88
88
  title: a.name,
89
89
  to: {
@@ -94,7 +94,7 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
94
94
  examples: a.uid
95
95
  }
96
96
  },
97
- method: (J = B[a.requestUid]) == null ? void 0 : J.method,
97
+ method: (Q = B[a.requestUid]) == null ? void 0 : Q.method,
98
98
  entity: a,
99
99
  resourceTitle: "Example",
100
100
  warning: "This cannot be undone. You’re about to delete the example from the request.",
@@ -122,19 +122,19 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
122
122
  ), pe = b(
123
123
  () => {
124
124
  var e;
125
- return typeof x.currentRoute.value.name == "string" && x.currentRoute.value.name.startsWith("request") && oe.value[S.Request] === "default" && ((e = V.value) == null ? void 0 : e.uid) === l.uid;
125
+ return typeof x.currentRoute.value.name == "string" && x.currentRoute.value.name.startsWith("request") && ae.value[S.Request] === "default" && ((e = V.value) == null ? void 0 : e.uid) === l.uid;
126
126
  }
127
- ), O = be(null), L = b(() => {
127
+ ), N = be(null), G = b(() => {
128
128
  let e = 0.5, t = 0.5;
129
- if (!O.value) return { ceiling: e, floor: t };
130
- const { draggingItem: r } = O.value;
129
+ if (!N.value) return { ceiling: e, floor: t };
130
+ const { draggingItem: r } = N.value;
131
131
  return !T[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 };
132
132
  }), ce = (e, t) => !(p === "modal" || j[t.id] || T[e.id]), fe = (e, t) => {
133
- e && (De(["default"]).some((g) => e[g]) ? se("newTab", t.title || "", t.entity.uid) : t.to && x.push(t.to));
133
+ e && (Re(["default"]).some((g) => e[g]) ? le("newTab", t.title || "", t.entity.uid) : t.to && x.push(t.to), xe(() => H.focusAddressBar.emit()));
134
134
  };
135
- function A(e) {
135
+ function O(e) {
136
136
  var g, o, d;
137
- const t = l.parentUids[0] ? ((g = T[l.parentUids[0]]) == null ? void 0 : g.uid) || "" : e, r = l.parentUids[0] && ((o = z[e]) != null && o.name) ? { tags: [z[e].name] } : {}, a = N.add(
137
+ const t = l.parentUids[0] ? ((g = T[l.parentUids[0]]) == null ? void 0 : g.uid) || "" : e, r = l.parentUids[0] && ((o = z[e]) != null && o.name) ? { tags: [z[e].name] } : {}, a = A.add(
138
138
  r,
139
139
  t
140
140
  );
@@ -144,18 +144,18 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
144
144
  workspace: (d = q.value) == null ? void 0 : d.uid,
145
145
  request: a.uid
146
146
  }
147
- }), ae.hotKeys.emit({
147
+ }), H.hotKeys.emit({
148
148
  focusAddressBar: new KeyboardEvent("keydown", { key: "l" })
149
149
  }));
150
150
  }
151
- const G = b(() => {
152
- const { uid: e, watchModeStatus: t } = le.value || {};
151
+ const K = b(() => {
152
+ const { uid: e, watchModeStatus: t } = oe.value || {};
153
153
  return e !== i.value.entity.uid ? "text-c-3" : t === "WATCHING" ? "text-c-1" : t === "ERROR" ? "text-red" : "text-c-3";
154
- }), K = b(() => i.value.title === "Drafts" && p !== "modal" && i.value.children.length > 0), me = b(() => {
154
+ }), J = b(() => i.value.title === "Drafts" && p !== "modal" && i.value.children.length > 0), me = b(() => {
155
155
  const e = B[l.uid];
156
- if (e) return !te(e);
156
+ if (e) return !ie(e);
157
157
  const t = z[l.uid];
158
- return t ? !te(t) : !0;
158
+ return t ? !ie(t) : !0;
159
159
  });
160
160
  return (e, t) => {
161
161
  const r = ye("RequestSidebarItem", !0);
@@ -165,13 +165,13 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
165
165
  n(p) === "modal" && e.parentUids.length > 1 || n(p) !== "modal" && e.parentUids.length ? "before:bg-border indent-border-line-offset before:z-1 mb-[.5px] before:pointer-events-none before:absolute before:left-[calc(.75rem_+_.5px)] before:top-0 before:h-[calc(100%_+_.5px)] before:w-[.5px] last:mb-0 last:before:h-full" : ""
166
166
  ]])
167
167
  }, [
168
- v(n(xe), {
168
+ v(n(ke), {
169
169
  id: i.value.entity.uid,
170
170
  ref_key: "draggableRef",
171
- ref: O,
172
- ceiling: L.value.ceiling,
171
+ ref: N,
172
+ ceiling: G.value.ceiling,
173
173
  class: "gap-1/2 flex flex-1 flex-col text-sm",
174
- floor: L.value.floor,
174
+ floor: G.value.floor,
175
175
  isDraggable: e.isDraggable,
176
176
  isDroppable: e.isDroppable,
177
177
  parentIds: e.parentUids,
@@ -180,7 +180,7 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
180
180
  default: c(() => {
181
181
  var a, g;
182
182
  return [
183
- (i.value.entity.type === "request" || i.value.entity.type === "requestExample") && i.value.to ? (u(), f(n(ie), {
183
+ (i.value.entity.type === "request" || i.value.entity.type === "requestExample") && i.value.to ? (u(), f(n(ne), {
184
184
  key: 0,
185
185
  class: "group no-underline",
186
186
  to: i.value.to,
@@ -198,9 +198,9 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
198
198
  o || pe.value ? "bg-sidebar-active-b text-sidebar-active-c transition-none" : "text-sidebar-c-2"
199
199
  ]])
200
200
  }, [
201
- s("span", Ie, D(i.value.title || "Untitled"), 1),
202
- s("div", Te, [
203
- s("div", ze, [
201
+ s("span", Te, D(i.value.title || "Untitled"), 1),
202
+ s("div", ze, [
203
+ s("div", Me, [
204
204
  n(p) !== "modal" ? (u(), f(n(R), {
205
205
  key: 0,
206
206
  class: y(["hover:bg-b-3 hidden aspect-square h-fit px-0.5 py-0 opacity-0 group-hover:flex group-hover:opacity-100 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
@@ -228,10 +228,10 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
228
228
  _: 1
229
229
  }, 8, ["class"])) : m("", !0)
230
230
  ]),
231
- s("span", Me, [
231
+ s("span", $e, [
232
232
  t[14] || (t[14] = E("   ")),
233
233
  t[15] || (t[15] = s("span", { class: "sr-only" }, "HTTP Method:", -1)),
234
- i.value.method ? (u(), f(n(Ce), {
234
+ i.value.method ? (u(), f(n(De), {
235
235
  key: 0,
236
236
  class: "font-bold",
237
237
  method: i.value.method
@@ -255,18 +255,18 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
255
255
  }, [
256
256
  s("span", {
257
257
  class: "flex h-5 max-w-[14px] cursor-pointer items-center justify-center",
258
- onClick: t[2] || (t[2] = (o) => n(H)(i.value.entity.uid))
258
+ onClick: t[2] || (t[2] = (o) => n(L)(i.value.entity.uid))
259
259
  }, [
260
- X(e.$slots, "leftIcon", {}, () => [
261
- v(n(_), {
260
+ Z(e.$slots, "leftIcon", {}, () => [
261
+ v(n(ee), {
262
262
  class: "text-c-3 shrink-0",
263
263
  open: !!n(I)[i.value.entity.uid]
264
264
  }, null, 8, ["open"])
265
265
  ], !0),
266
266
  t[16] || (t[16] = E("   "))
267
267
  ]),
268
- s("div", Ee, [
269
- i.value.to ? (u(), f(n(ie), {
268
+ s("div", Se, [
269
+ i.value.to ? (u(), f(n(ne), {
270
270
  key: 0,
271
271
  class: "w-full no-underline",
272
272
  to: i.value.to,
@@ -274,20 +274,20 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
274
274
  }, ["stop", "prevent"]))
275
275
  }, {
276
276
  default: c(() => [
277
- s("span", Se, D(i.value.title), 1)
277
+ s("span", Be, D(i.value.title), 1)
278
278
  ]),
279
279
  _: 1
280
- }, 8, ["to"])) : (u(), C(Z, { key: 1 }, [
280
+ }, 8, ["to"])) : (u(), C(_, { key: 1 }, [
281
281
  E(D(i.value.title), 1)
282
282
  ], 64)),
283
- s("div", Be, [
283
+ s("div", je, [
284
284
  s("div", {
285
285
  class: y(["items-center gap-px opacity-0 group-hover:flex group-hover:opacity-100 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
286
286
  flex: e.menuItem.open,
287
287
  hidden: !e.menuItem.open || ((a = e.menuItem.item) == null ? void 0 : a.entity.uid) !== i.value.entity.uid
288
288
  }])
289
289
  }, [
290
- n(p) !== "modal" && !M.value || M.value && K.value ? (u(), f(n(R), {
290
+ n(p) !== "modal" && !M.value || M.value && J.value ? (u(), f(n(R), {
291
291
  key: 0,
292
292
  class: "hover:bg-b-3 hover:text-c-1 aspect-square h-fit px-0.5 py-0 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100",
293
293
  size: "sm",
@@ -315,7 +315,7 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
315
315
  class: "hover:bg-b-3 hover:text-c-1 aspect-square h-fit px-0.5 py-0 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100",
316
316
  size: "sm",
317
317
  variant: "ghost",
318
- onClick: t[5] || (t[5] = U((o) => A(i.value.entity.uid), ["stop", "prevent"]))
318
+ onClick: t[5] || (t[5] = U((o) => O(i.value.entity.uid), ["stop", "prevent"]))
319
319
  }, {
320
320
  default: c(() => [
321
321
  v(n(h), {
@@ -327,22 +327,22 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
327
327
  _: 1
328
328
  })) : m("", !0)
329
329
  ], 2),
330
- i.value.watchMode ? (u(), f(n(ee), {
330
+ i.value.watchMode ? (u(), f(n(te), {
331
331
  key: 0,
332
332
  side: "right",
333
333
  sideOffset: 12
334
334
  }, {
335
335
  trigger: c(() => [
336
336
  v(n(h), {
337
- class: y(["ml-0.5 text-sm", G.value]),
337
+ class: y(["ml-0.5 text-sm", K.value]),
338
338
  icon: "Watch",
339
339
  size: "md",
340
340
  thickness: "2"
341
341
  }, null, 8, ["class"])
342
342
  ]),
343
343
  content: c(() => [
344
- s("div", je, [
345
- s("div", We, [
344
+ s("div", We, [
345
+ s("div", Ae, [
346
346
  s("p", Ne, " Watching: " + D(i.value.documentUrl), 1)
347
347
  ])
348
348
  ])
@@ -352,32 +352,32 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
352
352
  t[17] || (t[17] = s("span", null, " ", -1))
353
353
  ])
354
354
  ])
355
- ], 10, $e)) : n(p) !== "modal" || e.parentUids.length ? (u(), C("button", {
355
+ ], 10, Ee)) : n(p) !== "modal" || e.parentUids.length ? (u(), C("button", {
356
356
  key: 2,
357
357
  "aria-expanded": !!n(I)[i.value.entity.uid],
358
358
  class: y(["hover:bg-b-2 group relative flex w-full flex-row justify-start gap-1.5 rounded p-1.5 focus-visible:z-10", [P]]),
359
359
  type: "button",
360
- onClick: t[8] || (t[8] = (o) => n(H)(i.value.entity.uid))
360
+ onClick: t[8] || (t[8] = (o) => n(L)(i.value.entity.uid))
361
361
  }, [
362
- s("span", Ae, [
363
- X(e.$slots, "leftIcon", {}, () => [
364
- v(n(_), {
362
+ s("span", Pe, [
363
+ Z(e.$slots, "leftIcon", {}, () => [
364
+ v(n(ee), {
365
365
  class: "text-c-3 hover:text-c-1 shrink-0",
366
366
  open: !!n(I)[i.value.entity.uid]
367
367
  }, null, 8, ["open"])
368
368
  ], !0),
369
369
  t[18] || (t[18] = E("   "))
370
370
  ]),
371
- s("div", Pe, [
372
- s("span", Ve, D(i.value.title), 1),
373
- s("div", Fe, [
371
+ s("div", Ve, [
372
+ s("span", Fe, D(i.value.title), 1),
373
+ s("div", Ye, [
374
374
  s("div", {
375
375
  class: y(["items-center gap-px opacity-0 group-hover:flex group-hover:opacity-100 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
376
376
  flex: e.menuItem.open,
377
377
  hidden: !e.menuItem.open || ((g = e.menuItem.item) == null ? void 0 : g.entity.uid) !== i.value.entity.uid
378
378
  }])
379
379
  }, [
380
- n(p) !== "modal" && !M.value || M.value && K.value ? (u(), f(n(R), {
380
+ n(p) !== "modal" && !M.value || M.value && J.value ? (u(), f(n(R), {
381
381
  key: 0,
382
382
  class: "hover:bg-b-3 hover:text-c-1 aspect-square h-fit px-0.5 py-0 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100",
383
383
  size: "sm",
@@ -405,7 +405,7 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
405
405
  class: "hover:bg-b-3 hover:text-c-1 aspect-square h-fit px-0.5 py-0 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100",
406
406
  size: "sm",
407
407
  variant: "ghost",
408
- onClick: t[7] || (t[7] = U((o) => A(i.value.entity.uid), ["stop", "prevent"]))
408
+ onClick: t[7] || (t[7] = U((o) => O(i.value.entity.uid), ["stop", "prevent"]))
409
409
  }, {
410
410
  default: c(() => [
411
411
  v(n(h), {
@@ -417,23 +417,23 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
417
417
  _: 1
418
418
  })) : m("", !0)
419
419
  ], 2),
420
- i.value.watchMode ? (u(), f(n(ee), {
420
+ i.value.watchMode ? (u(), f(n(te), {
421
421
  key: 0,
422
422
  side: "right",
423
423
  sideOffset: 12
424
424
  }, {
425
425
  trigger: c(() => [
426
426
  v(n(h), {
427
- class: y(["ml-0.5 text-sm", G.value]),
427
+ class: y(["ml-0.5 text-sm", K.value]),
428
428
  icon: "Watch",
429
429
  size: "md",
430
430
  thickness: "2"
431
431
  }, null, 8, ["class"])
432
432
  ]),
433
433
  content: c(() => [
434
- s("div", Ye, [
435
- s("div", He, [
436
- s("p", Le, " Watching: " + D(i.value.documentUrl), 1)
434
+ s("div", He, [
435
+ s("div", Le, [
436
+ s("p", Ge, " Watching: " + D(i.value.documentUrl), 1)
437
437
  ])
438
438
  ])
439
439
  ]),
@@ -443,8 +443,8 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
443
443
  ])
444
444
  ])
445
445
  ], 10, Oe)) : m("", !0),
446
- de.value ? (u(), C("ul", Ge, [
447
- (u(!0), C(Z, null, he(i.value.children, (o) => (u(), f(r, {
446
+ de.value ? (u(), C("ul", Ke, [
447
+ (u(!0), C(_, null, he(i.value.children, (o) => (u(), f(r, {
448
448
  key: o,
449
449
  isDraggable: !n(j)[o],
450
450
  isDroppable: ce,
@@ -459,7 +459,7 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
459
459
  key: 0,
460
460
  class: y(["text-c-1 hover:bg-b-2 flex h-8 w-full justify-start gap-1.5 py-0 text-xs", e.parentUids.length ? "pl-9" : ""]),
461
461
  variant: "ghost",
462
- onClick: t[12] || (t[12] = (o) => A(i.value.entity.uid))
462
+ onClick: t[12] || (t[12] = (o) => O(i.value.entity.uid))
463
463
  }, {
464
464
  default: c(() => [
465
465
  v(n(h), {
@@ -480,5 +480,5 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
480
480
  }
481
481
  });
482
482
  export {
483
- ot as default
483
+ at as default
484
484
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./ResponseBody.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-29928f90"]]);
4
+ const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-9bbb0b3d"]]);
5
5
  export {
6
6
  e as default
7
7
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as b, ref as C, computed as u, openBlock as o, createBlock as n, createSlots as N, withCtx as d, createTextVNode as h, toDisplayString as g, createElementBlock as T, createElementVNode as _, unref as a, createCommentVNode as s, createVNode as $ } from "vue";
1
+ import { defineComponent as b, ref as C, computed as d, openBlock as o, createBlock as n, createSlots as N, withCtx as u, createTextVNode as h, toDisplayString as g, createElementBlock as T, createElementVNode as _, unref as a, createCommentVNode as s, createVNode as $ } from "vue";
2
2
  import E from "../../../components/ViewLayout/ViewLayoutCollapse.vue.js";
3
3
  import { useResponseBody as P } from "../../../hooks/useResponseBody.js";
4
4
  import S from "./ResponseBodyDownload.vue.js";
@@ -18,20 +18,20 @@ const q = {
18
18
  headers: {}
19
19
  },
20
20
  setup(x) {
21
- const c = x, r = C(!0), p = u(
21
+ const c = x, r = C(!0), p = d(
22
22
  () => {
23
23
  var t;
24
24
  return !!((t = e.value) != null && t.raw && e.value.preview);
25
25
  }
26
- ), k = u(() => r.value || !p.value), B = u(() => !r.value || !p.value), { mimeType: i, attachmentFilename: R, dataUrl: l } = P({
26
+ ), k = d(() => r.value || !p.value), B = d(() => !r.value || !p.value), { mimeType: i, attachmentFilename: R, dataUrl: l } = P({
27
27
  data: c.data,
28
28
  headers: c.headers
29
- }), e = u(() => I[i.value.essence]);
30
- return (t, m) => (o(), n(E, { class: "max-h-content overflow-x-auto" }, N({
31
- title: d(() => [
29
+ }), e = d(() => I[i.value.essence]);
30
+ return (t, m) => (o(), n(E, { class: "max-h-content overflow-y-hidden" }, N({
31
+ title: u(() => [
32
32
  h(g(t.title), 1)
33
33
  ]),
34
- default: d(() => {
34
+ default: u(() => {
35
35
  var f, v, y, w;
36
36
  return [
37
37
  t.data ? (o(), T("div", q, [
@@ -56,7 +56,7 @@ const q = {
56
56
  type: a(i).essence
57
57
  }, null, 8, ["alpha", "mode", "src", "type"])) : s("", !0),
58
58
  !((y = e.value) != null && y.raw) && !((w = e.value) != null && w.preview) ? (o(), n(U, { key: 2 }, {
59
- default: d(() => m[1] || (m[1] = [
59
+ default: u(() => m[1] || (m[1] = [
60
60
  h(" Binary file ")
61
61
  ])),
62
62
  _: 1
@@ -68,7 +68,7 @@ const q = {
68
68
  }, [
69
69
  t.data && a(l) ? {
70
70
  name: "actions",
71
- fn: d(() => [
71
+ fn: u(() => [
72
72
  $(S, {
73
73
  filename: a(R),
74
74
  href: a(l),
@@ -1 +1 @@
1
- {"version":3,"file":"ResponseBodyRaw.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseBodyRaw.vue"],"names":[],"mappings":"AAyGA,OAAO,EAAiB,KAAK,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAM/E,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE,GAAG,CAAA;IACZ,QAAQ,EAAE,kBAAkB,GAAG,SAAS,CAAA;CACzC,CAAC;;AA4GF,wBAOG"}
1
+ {"version":3,"file":"ResponseBodyRaw.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseBodyRaw.vue"],"names":[],"mappings":"AAkHA,OAAO,EAAiB,KAAK,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAM/E,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE,GAAG,CAAA;IACZ,QAAQ,EAAE,kBAAkB,GAAG,SAAS,CAAA;CACzC,CAAC;;AAwHF,wBAOG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./ResponseBodyRaw.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-73c37f28"]]);
4
+ const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-96fbecd5"]]);
5
5
  export {
6
- a as default
6
+ s as default
7
7
  };
@@ -1,47 +1,52 @@
1
- import { defineComponent as m, ref as f, toRef as c, openBlock as a, createElementBlock as l, createElementVNode as t, unref as i, createVNode as y, createCommentVNode as C } from "vue";
2
- import { ScalarIcon as b } from "@scalar/components";
3
- import { prettyPrintJson as g } from "@scalar/oas-utils/helpers";
4
- import { useCodeMirror as v } from "@scalar/use-codemirror";
1
+ import { defineComponent as m, ref as f, toRef as c, openBlock as l, createElementBlock as i, createElementVNode as e, unref as a, createVNode as y, createCommentVNode as b } from "vue";
2
+ import { ScalarIcon as v } from "@scalar/components";
3
+ import { prettyPrintJson as C } from "@scalar/oas-utils/helpers";
4
+ import { useCodeMirror as g } from "@scalar/use-codemirror";
5
5
  import { useClipboard as _ } from "@scalar/use-hooks/useClipboard";
6
- const k = { class: "body-raw relative overflow-auto" }, R = {
6
+ const k = { class: "body-raw grid min-h-0 overflow-hidden p-px outline-none has-[:focus-visible]:outline" }, w = {
7
7
  key: 0,
8
8
  class: "scalar-code-copy"
9
+ }, x = {
10
+ class: "body-raw-scroller custom-scroll relative overflow-x-auto overscroll-contain",
11
+ tabindex: "0"
9
12
  }, E = /* @__PURE__ */ m({
10
13
  __name: "ResponseBodyRaw",
11
14
  props: {
12
15
  content: {},
13
16
  language: {}
14
17
  },
15
- setup(u) {
16
- const r = u, n = f(null), { copyToClipboard: d } = _(), { codeMirror: p } = v({
18
+ setup(d) {
19
+ const r = d, n = f(null), { copyToClipboard: u } = _(), { codeMirror: p } = g({
17
20
  codeMirrorRef: n,
18
21
  readOnly: !0,
19
22
  lineNumbers: !0,
20
- content: c(() => g(r.content)),
23
+ content: c(() => C(r.content)),
21
24
  language: c(() => r.language),
22
25
  forceFoldGutter: !0
23
26
  }), s = () => {
24
- var o;
25
- return ((o = p.value) == null ? void 0 : o.state.doc.toString()) || "";
27
+ var t;
28
+ return ((t = p.value) == null ? void 0 : t.state.doc.toString()) || "";
26
29
  };
27
- return (o, e) => (a(), l("div", k, [
28
- s() ? (a(), l("div", R, [
29
- t("button", {
30
+ return (t, o) => (l(), i("div", k, [
31
+ s() ? (l(), i("div", w, [
32
+ e("button", {
30
33
  class: "copy-button",
31
34
  type: "button",
32
- onClick: e[0] || (e[0] = (M) => i(d)(s()))
35
+ onClick: o[0] || (o[0] = (R) => a(u)(s()))
33
36
  }, [
34
- e[1] || (e[1] = t("span", { class: "sr-only" }, "Copy content", -1)),
35
- y(i(b), {
37
+ o[1] || (o[1] = e("span", { class: "sr-only" }, "Copy content", -1)),
38
+ y(a(v), {
36
39
  icon: "Clipboard",
37
40
  size: "md"
38
41
  })
39
42
  ])
40
- ])) : C("", !0),
41
- t("div", {
42
- ref_key: "codeMirrorRef",
43
- ref: n
44
- }, null, 512)
43
+ ])) : b("", !0),
44
+ e("div", x, [
45
+ e("div", {
46
+ ref_key: "codeMirrorRef",
47
+ ref: n
48
+ }, null, 512)
49
+ ])
45
50
  ]));
46
51
  }
47
52
  });
@@ -36,7 +36,7 @@ const P = { class: "col-1 flex-center relative gap-6 p-2 capitalize" }, T = {
36
36
  }));
37
37
  }, y = (s) => {
38
38
  s != null && s.createNew && w.name === "request" && k();
39
- }, N = "2.2.57";
39
+ }, N = "2.2.60";
40
40
  return B(() => r.hotKeys.on(y)), E(() => r.hotKeys.off(y)), (s, e) => (u(), i("div", P, [
41
41
  o("div", {
42
42
  class: q(["flex h-[calc(100%_-_50px)] flex-col items-center justify-center", {
@@ -1 +1 @@
1
- {"version":3,"file":"ResponseSection.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseSection.vue"],"names":[],"mappings":"AA6MA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAA;AAgBvE,KAAK,WAAW,GAAG;IACjB,oBAAoB,EAAE,MAAM,CAAA;IAC5B,QAAQ,EAAE,gBAAgB,GAAG,SAAS,CAAA;CACvC,CAAC;;AA4RF,wBAOG"}
1
+ {"version":3,"file":"ResponseSection.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseSection.vue"],"names":[],"mappings":"AAgOA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAA;AAgBvE,KAAK,WAAW,GAAG;IACjB,oBAAoB,EAAE,MAAM,CAAA;IAC5B,QAAQ,EAAE,gBAAgB,GAAG,SAAS,CAAA;CACvC,CAAC;;AAqRF,wBAOG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./ResponseSection.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-700328ca"]]);
4
+ const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-76ba3474"]]);
5
5
  export {
6
6
  s as default
7
7
  };