@scalar/api-client 2.0.5 → 2.0.7

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 (37) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/dist/Modal/ApiClientModal.vue.d.ts +1 -1
  3. package/dist/Modal/ApiClientModal.vue.d.ts.map +1 -1
  4. package/dist/Modal/ApiClientModal.vue.js +1 -1
  5. package/dist/Modal/ApiClientModal.vue2.js +16 -15
  6. package/dist/Modal/api-client-modal.d.ts +1 -1
  7. package/dist/Modal/api-client-modal.d.ts.map +1 -1
  8. package/dist/Modal/api-client-modal.js +43 -43
  9. package/dist/components/DarkModeToggle/DarkModeIconToggle.vue.js +1 -1
  10. package/dist/components/DataTable/DataTableInput.vue.d.ts +2 -0
  11. package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
  12. package/dist/components/DataTable/DataTableInput.vue.js +2 -2
  13. package/dist/components/DataTable/DataTableInput.vue2.js +43 -36
  14. package/dist/components/DataTable/DataTableInputEnumSelect.vue.d.ts +22 -0
  15. package/dist/components/DataTable/DataTableInputEnumSelect.vue.d.ts.map +1 -0
  16. package/dist/components/DataTable/DataTableInputEnumSelect.vue.js +102 -0
  17. package/dist/components/DataTable/DataTableInputEnumSelect.vue2.js +4 -0
  18. package/dist/components/SideNav/SideNavLink.vue.js +2 -2
  19. package/dist/constants.js +1 -1
  20. package/dist/store/workspace.d.ts +75 -12
  21. package/dist/store/workspace.d.ts.map +1 -1
  22. package/dist/store/workspace.js +113 -109
  23. package/dist/style.css +1 -1
  24. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  25. package/dist/views/Cookies/Cookies.vue2.js +13 -11
  26. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  27. package/dist/views/Request/RequestSection/RequestSection.vue.js +10 -10
  28. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
  29. package/dist/views/Request/RequestSection/RequestTable.vue.js +2 -2
  30. package/dist/views/Request/RequestSection/RequestTable.vue2.js +24 -23
  31. package/dist/views/Request/RequestSidebarItem.vue.d.ts +0 -1
  32. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  33. package/dist/views/Request/RequestSidebarItem.vue.js +2 -1
  34. package/dist/views/Request/RequestSidebarItem.vue2.js +8 -9
  35. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  36. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +6 -6
  37. package/package.json +8 -8
@@ -1,4 +1,4 @@
1
- import { defineComponent as y, computed as v, ref as x, watch as A, openBlock as S, createBlock as q, withCtx as _, createVNode as l, unref as n, createElementVNode as r, createTextVNode as k, toDisplayString as B, withDirectives as o, vShow as a } from "vue";
1
+ import { defineComponent as y, computed as v, ref as x, watch as A, openBlock as S, createBlock as k, withCtx as _, createVNode as l, unref as n, createElementVNode as r, createTextVNode as q, toDisplayString as B, withDirectives as o, vShow as a } from "vue";
2
2
  import R from "../../../components/ContextBar.vue.js";
3
3
  import C from "../../../components/ViewLayout/ViewLayoutSection.vue.js";
4
4
  import { useWorkspace as E } from "../../../store/workspace.js";
@@ -10,7 +10,7 @@ import { ScalarIcon as O } from "@scalar/components";
10
10
  const P = { class: "flex-1" }, T = { class: "text-c-3 pl-1" }, w = { class: "request-section-content custom-scroll flex flex-1 flex-col px-2 xl:px-5 py-2.5" }, M = /* @__PURE__ */ y({
11
11
  __name: "RequestSection",
12
12
  setup(K) {
13
- const { activeRequest: i, activeExample: m, activeSecurityRequirements: p } = E(), c = ["POST", "PUT", "PATCH", "DELETE"], h = v(() => {
13
+ const { activeRequest: i, activeExample: m, activeSecurityRequirements: d } = E(), c = ["POST", "PUT", "PATCH", "DELETE"], h = v(() => {
14
14
  const t = [
15
15
  "All",
16
16
  "Auth",
@@ -20,23 +20,23 @@ const P = { class: "flex-1" }, T = { class: "text-c-3 pl-1" }, w = { class: "req
20
20
  "Query",
21
21
  "Body"
22
22
  ];
23
- return m.value.parameters.path.length || t.splice(t.indexOf("Request"), 1), c.includes(i.value.method) || t.splice(t.indexOf("Body"), 1), d.value && t.splice(t.indexOf("Auth"), 1), t;
24
- }), d = v(
25
- () => p.value.length === 0 || JSON.stringify(p.value) === "[{}]"
23
+ return m.value.parameters.path.length || t.splice(t.indexOf("Request"), 1), c.includes(i.value.method) || t.splice(t.indexOf("Body"), 1), p.value && t.splice(t.indexOf("Auth"), 1), t;
24
+ }), p = v(
25
+ () => d.value.length === 0 || JSON.stringify(d.value) === "[{}]"
26
26
  ), e = x("All");
27
27
  return A(i, (t) => {
28
28
  e.value === "Body" && !c.includes(t.method) && (e.value = "All");
29
- }), (t, f) => (S(), q(C, null, {
29
+ }), (t, f) => (S(), k(C, null, {
30
30
  title: _(() => {
31
31
  var s;
32
32
  return [
33
33
  l(n(O), {
34
- class: "text-c-3 mr-1.5",
34
+ class: "text-c-3 mr-1.5 stroke-2",
35
35
  icon: "ExternalLink",
36
- size: "sm"
36
+ size: "md"
37
37
  }),
38
38
  r("div", P, [
39
- k(" Request "),
39
+ q(" Request "),
40
40
  r("span", T, B((s = n(i)) == null ? void 0 : s.summary), 1)
41
41
  ])
42
42
  ];
@@ -51,7 +51,7 @@ const P = { class: "flex-1" }, T = { class: "text-c-3 pl-1" }, w = { class: "req
51
51
  o(l($, { title: "Authentication" }, null, 512), [
52
52
  [
53
53
  a,
54
- !d.value && (e.value === "All" || e.value === "Auth")
54
+ !p.value && (e.value === "All" || e.value === "Auth")
55
55
  ]
56
56
  ]),
57
57
  o(l(H, {
@@ -1 +1 @@
1
- {"version":3,"file":"RequestTable.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/RequestSection/RequestTable.vue"],"names":[],"mappings":"AAwIA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,2CAA2C,CAAA;;YAK5E,uBAAuB,EAAE;IACjC,8BAA8B;sBACZ,OAAO;uBACN,OAAO;;;;;;;;;;;;;;YAHlB,uBAAuB,EAAE;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;YAHlB,uBAAuB,EAAE;IACjC,8BAA8B;sBACZ,OAAO;uBACN,OAAO;;;;;;;;;;;;;;qBADR,OAAO;sBACN,OAAO;;AAqa9B,wBAOG;AAOH,KAAK,kBAAkB,CAAC,CAAC,EAAE,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,IAAI,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,SAAS,MAAM,CAAC,GAC7C,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG;QAAE,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;KAAC,CAAC,GACvC,CAAC,CAAC,CAAC,CAAC;CACP,CAAC;AAEN,KAAK,cAAc,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC;AAExD,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -1,7 +1,7 @@
1
1
  import o from "./RequestTable.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-5d101842"]]);
4
+ const c = /* @__PURE__ */ t(o, [["__scopeId", "data-v-c04c82dd"]]);
5
5
  export {
6
- m as default
6
+ c as default
7
7
  };
@@ -1,11 +1,11 @@
1
- import { defineComponent as S, openBlock as s, createBlock as r, unref as p, withCtx as i, createElementBlock as f, Fragment as v, renderList as F, createCommentVNode as b, createVNode as c, createSlots as R, createElementVNode as d, toDisplayString as w, pushScopeId as $, popScopeId as x } from "vue";
1
+ import { defineComponent as S, openBlock as s, createBlock as r, unref as p, withCtx as i, createElementBlock as f, Fragment as v, renderList as F, createCommentVNode as b, createVNode as c, createSlots as R, createElementVNode as u, toDisplayString as w, pushScopeId as $, popScopeId as x } from "vue";
2
2
  import I from "../../../components/DataTable/DataTable.vue.js";
3
3
  import U from "../../../components/DataTable/DataTableCell.vue.js";
4
4
  import C from "../../../components/DataTable/DataTableCheckbox.vue.js";
5
5
  import V from "../../../components/DataTable/DataTableInput.vue.js";
6
6
  import z from "../../../components/DataTable/DataTableRow.vue.js";
7
7
  import { ScalarIcon as y, ScalarButton as E } from "@scalar/components";
8
- const q = (u) => ($("data-v-5d101842"), u = u(), x(), u), D = { class: "relative group/info flex items-center pr-2" }, H = { class: "absolute pointer-events-none w-40 shadow-lg rounded bg-b-1 z-100 p-1.5 text-xxs leading-5 -translate-x-full translate-y-[24px] opacity-0 group-hover/info:opacity-100 z-10 text-c-1" }, N = { class: "text-c-2 max-w-[100%] overflow-hidden filemask flex items-end justify-end" }, T = ["onClick"], j = /* @__PURE__ */ q(() => /* @__PURE__ */ d("span", null, "File", -1)), P = /* @__PURE__ */ S({
8
+ const q = (d) => ($("data-v-c04c82dd"), d = d(), x(), d), D = { class: "relative group/info flex items-center pr-2" }, H = { class: "absolute pointer-events-none w-40 shadow-lg rounded bg-b-1 z-100 p-1.5 text-xxs leading-5 -translate-x-full translate-y-[24px] opacity-0 group-hover/info:opacity-100 z-10 text-c-1" }, N = { class: "text-c-2 max-w-[100%] overflow-hidden filemask flex items-end justify-end" }, T = ["onClick"], j = /* @__PURE__ */ q(() => /* @__PURE__ */ u("span", null, "File", -1)), P = /* @__PURE__ */ S({
9
9
  __name: "RequestTable",
10
10
  props: {
11
11
  items: {},
@@ -13,58 +13,59 @@ const q = (u) => ($("data-v-5d101842"), u = u(), x(), u), D = { class: "relative
13
13
  showUploadButton: { type: Boolean, default: !1 }
14
14
  },
15
15
  emits: ["updateRow", "toggleRow", "addRow", "deleteRow", "inputFocus", "inputBlur", "uploadFile", "removeFile"],
16
- setup(u, { emit: g }) {
17
- const k = u, o = g, h = k.isEnabledHidden ? ["", ""] : ["", "", "36px"], m = (t, l, n) => {
18
- o("updateRow", t, l, n);
16
+ setup(d, { emit: g }) {
17
+ const k = d, o = g, h = k.isEnabledHidden ? ["", ""] : ["", "", "36px"], m = (t, n, l) => {
18
+ o("updateRow", t, n, l);
19
19
  }, _ = (t) => {
20
20
  o("uploadFile", t);
21
21
  };
22
- return (t, l) => (s(), r(I, {
22
+ return (t, n) => (s(), r(I, {
23
23
  class: "flex-1",
24
24
  columns: p(h)
25
25
  }, {
26
26
  default: i(() => [
27
- (s(!0), f(v, null, F(t.items, (n, a) => (s(), r(z, { key: a }, {
27
+ (s(!0), f(v, null, F(t.items, (l, a) => (s(), r(z, { key: a }, {
28
28
  default: i(() => [
29
29
  t.isEnabledHidden ? b("", !0) : (s(), r(C, {
30
30
  key: 0,
31
- modelValue: n.enabled,
31
+ modelValue: l.enabled,
32
32
  "onUpdate:modelValue": (e) => o("toggleRow", a, e)
33
33
  }, null, 8, ["modelValue", "onUpdate:modelValue"])),
34
34
  c(V, {
35
- modelValue: n.key,
35
+ modelValue: l.key,
36
36
  placeholder: "Key",
37
- required: n.required,
38
- onBlur: l[0] || (l[0] = (e) => o("inputBlur")),
39
- onFocus: l[1] || (l[1] = (e) => o("inputFocus")),
37
+ required: l.required,
38
+ onBlur: n[0] || (n[0] = (e) => o("inputBlur")),
39
+ onFocus: n[1] || (n[1] = (e) => o("inputFocus")),
40
40
  onInput: (e) => t.items && a === t.items.length - 1 && o("addRow"),
41
41
  onSelectVariable: (e) => m(a, "key", e),
42
42
  "onUpdate:modelValue": (e) => o("updateRow", a, "key", e)
43
43
  }, null, 8, ["modelValue", "required", "onInput", "onSelectVariable", "onUpdate:modelValue"]),
44
44
  c(V, {
45
- modelValue: n.value,
45
+ enum: l.enum,
46
+ modelValue: l.value,
46
47
  placeholder: "Value",
47
- onBlur: l[2] || (l[2] = (e) => o("inputBlur")),
48
- onFocus: l[3] || (l[3] = (e) => o("inputFocus")),
48
+ onBlur: n[2] || (n[2] = (e) => o("inputBlur")),
49
+ onFocus: n[3] || (n[3] = (e) => o("inputFocus")),
49
50
  onInput: (e) => t.items && a === t.items.length - 1 && o("addRow"),
50
51
  onSelectVariable: (e) => m(a, "value", e),
51
52
  "onUpdate:modelValue": (e) => o("updateRow", a, "value", e)
52
53
  }, R({ _: 2 }, [
53
- n.description ? {
54
+ l.description ? {
54
55
  name: "icon",
55
56
  fn: i(() => [
56
- d("div", D, [
57
+ u("div", D, [
57
58
  c(p(y), {
58
59
  class: "ml-1 text-c-3 group-hover/info:text-c-1",
59
60
  icon: "Info",
60
61
  size: "sm"
61
62
  }),
62
- d("span", H, w(n.description), 1)
63
+ u("span", H, w(l.description), 1)
63
64
  ])
64
65
  ]),
65
66
  key: "0"
66
67
  } : void 0
67
- ]), 1032, ["modelValue", "onInput", "onSelectVariable", "onUpdate:modelValue"]),
68
+ ]), 1032, ["enum", "modelValue", "onInput", "onSelectVariable", "onUpdate:modelValue"]),
68
69
  t.showUploadButton ? (s(), r(U, {
69
70
  key: 1,
70
71
  class: "group/upload p-1 overflow-hidden relative text-ellipsis whitespace-nowrap"
@@ -72,11 +73,11 @@ const q = (u) => ($("data-v-5d101842"), u = u(), x(), u), D = { class: "relative
72
73
  default: i(() => {
73
74
  var e;
74
75
  return [
75
- n.file ? (s(), f(v, { key: 0 }, [
76
- d("div", N, [
77
- d("span", null, w((e = n.file) == null ? void 0 : e.name), 1)
76
+ l.file ? (s(), f(v, { key: 0 }, [
77
+ u("div", N, [
78
+ u("span", null, w((e = l.file) == null ? void 0 : e.name), 1)
78
79
  ]),
79
- d("button", {
80
+ u("button", {
80
81
  class: "absolute bg-b-2 font-medium centered-x centered-y hidden rounded text-center p-0.5 w-[calc(100%_-_8px)] group-hover/upload:block text-xs",
81
82
  type: "button",
82
83
  onClick: (B) => o("removeFile", a)
@@ -1,5 +1,4 @@
1
1
  import { type DraggingItem, type HoveredItem } from '@scalar/draggable';
2
- import '@scalar/draggable/style.css';
3
2
  import type { Collection } from '@scalar/oas-utils/entities/workspace/collection';
4
3
  import type { Folder } from '@scalar/oas-utils/entities/workspace/folder';
5
4
  import type { Request, RequestExample } from '@scalar/oas-utils/entities/workspace/spec';
@@ -1 +1 @@
1
- {"version":3,"file":"RequestSidebarItem.vue.d.ts","sourceRoot":"","sources":["../../../src/views/Request/RequestSidebarItem.vue"],"names":[],"mappings":"AAiOA,OAAO,EAEL,KAAK,YAAY,EACjB,KAAK,WAAW,EACjB,MAAM,mBAAmB,CAAA;AAC1B,OAAO,6BAA6B,CAAA;AACpC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iDAAiD,CAAA;AACjF,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,6CAA6C,CAAA;AACzE,OAAO,KAAK,EACV,OAAO,EACP,cAAc,EACf,MAAM,2CAA2C,CAAA;AA0GlD,iBAAS,cAAc;gBAvET,IAAI;;gBAAJ,IAAI;EAwVjB;AACD,QAAA,MAAM,eAAe;IAnXjB;;;;OAIG;kBACW,OAAO;IACrB;;;;OAIG;kBACW,OAAO;IACrB,qEAAqE;gBACzD,MAAM,EAAE;UACd,UAAU,GAAG,MAAM,GAAG,OAAO,GAAG,cAAc;;;;;;;;IAdpD;;;;OAIG;kBACW,OAAO;IACrB;;;;OAIG;kBACW,OAAO;IACrB,qEAAqE;gBACzD,MAAM,EAAE;UACd,UAAU,GAAG,MAAM,GAAG,OAAO,GAAG,cAAc;;;;;;;;iBATtC,OAAO;iBAMP,OAAO;MA+WvB,CAAC;wBACkB,uBAAuB,CAAC,OAAO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,CAAC,CAAC;KAEV,CAAA;CACD,CAAC;AAEN,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -1,7 +1,8 @@
1
1
  import t from "./RequestSidebarItem.vue2.js";
2
2
  /* empty css */
3
+ /* empty css */
3
4
  import o from "../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ o(t, [["__scopeId", "data-v-3cdb431d"]]);
5
+ const a = /* @__PURE__ */ o(t, [["__scopeId", "data-v-2b673e3d"]]);
5
6
  export {
6
7
  a as default
7
8
  };
@@ -2,12 +2,11 @@ import { defineComponent as N, useCssVars as V, computed as a, resolveComponent
2
2
  import { useWorkspace as W } from "../../store/workspace.js";
3
3
  import { ScalarIcon as A } from "@scalar/components";
4
4
  import { Draggable as G } from "@scalar/draggable";
5
- import "@scalar/draggable/style.css";
6
5
  import { useRouter as H, RouterLink as J } from "vue-router";
7
6
  import M from "./RequestSidebarItemMenu.vue.js";
8
7
  import P from "../../components/HttpMethod/HttpMethod.vue.js";
9
8
  import { useSidebar as Q } from "../../hooks/useSidebar.js";
10
- const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y = { class: "relative" }, Z = { class: "flex" }, _ = { class: "z-10 mr-[-.5px] flex h-fit items-center justify-center" }, ee = { class: "z-10 font-medium" }, te = { key: 2 }, q = "hover:before:bg-sidebar-active-b before:absolute before:inset-0 before:rounded before-left-offset", me = /* @__PURE__ */ N({
9
+ const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y = { class: "relative" }, Z = { class: "flex" }, _ = { class: "z-10 mr-[-.5px] flex h-fit items-center justify-center" }, ee = { class: "z-10 font-medium" }, te = { key: 2 }, q = "hover:before:bg-sidebar-active-b before:absolute before:inset-0 before:rounded before-left-offset", pe = /* @__PURE__ */ N({
11
10
  __name: "RequestSidebarItem",
12
11
  props: {
13
12
  isDraggable: { type: Boolean, default: !1 },
@@ -18,9 +17,9 @@ const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y =
18
17
  emits: ["onDragEnd"],
19
18
  setup(w) {
20
19
  V((e) => ({
21
- "426379e0": E.value
20
+ "26c2db78": E.value
22
21
  }));
23
- const s = w, { activeRequest: c, folders: C, requests: h, requestExamples: R, workspace: l } = W(), { collapsedSidebarFolders: v, toggleSidebarFolder: $ } = Q(), S = H(), m = a(() => "childUids" in s.item), E = a(() => s.parentUids.length ? m.value ? `-${s.parentUids.length * 16}px` : `-${s.parentUids.length * 16}px` : "0px"), z = (e, t) => {
22
+ const s = w, { activeRequest: c, folders: C, requests: h, requestExamples: R, workspace: l } = W(), { collapsedSidebarFolders: v, toggleSidebarFolder: $ } = Q(), S = H(), u = a(() => "childUids" in s.item), E = a(() => s.parentUids.length ? u.value ? `-${s.parentUids.length * 16}px` : `-${s.parentUids.length * 16}px` : "0px"), z = (e, t) => {
24
23
  e.metaKey ? window.open(`/request/${t}`, "_blank") : S.push(`/request/${t}`);
25
24
  }, D = (e) => {
26
25
  var t;
@@ -40,9 +39,9 @@ const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y =
40
39
  }, [
41
40
  f(r(G), {
42
41
  id: e.item.uid,
43
- ceiling: m.value ? 0.8 : 0.5,
42
+ ceiling: u.value ? 0.8 : 0.5,
44
43
  class: "flex flex-1 flex-col gap-[.5px] text-sm",
45
- floor: m.value ? 0.2 : 0.5,
44
+ floor: u.value ? 0.2 : 0.5,
46
45
  isDraggable: e.parentUids.length > 0 && e.isDraggable,
47
46
  isDroppable: e.isDroppable,
48
47
  parentIds: e.parentUids,
@@ -64,7 +63,7 @@ const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y =
64
63
  (e.isDroppable, "pl-3")
65
64
  ]]),
66
65
  tabindex: "0",
67
- onClick: t[0] || (t[0] = (u) => z(u, e.item.uid))
66
+ onClick: t[0] || (t[0] = (m) => z(m, e.item.uid))
68
67
  }, [
69
68
  n("span", X, U(D(e.item)), 1),
70
69
  n("div", Y, [
@@ -115,7 +114,7 @@ const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y =
115
114
  isDroppable: e.isDroppable,
116
115
  item: r(C)[i] || r(h)[i] || r(R)[i],
117
116
  parentUids: [...e.parentUids, e.item.uid],
118
- onOnDragEnd: t[2] || (t[2] = (...u) => e.$emit("onDragEnd", ...u))
117
+ onOnDragEnd: t[2] || (t[2] = (...m) => e.$emit("onDragEnd", ...m))
119
118
  }, null, 8, ["isDraggable", "isDroppable", "item", "parentUids"]))), 128))
120
119
  ], 512)), [
121
120
  [K, O.value]
@@ -128,5 +127,5 @@ const X = { class: "z-10 font-medium w-full editable-sidebar-hover-item" }, Y =
128
127
  }
129
128
  });
130
129
  export {
131
- me as default
130
+ pe as default
132
131
  };
@@ -1 +1 @@
1
- {"version":3,"file":"ResponseSection.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseSection.vue"],"names":[],"mappings":"AAuHA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAA;;cAUrE,gBAAgB,GAAG,SAAS;;cAA5B,gBAAgB,GAAG,SAAS;;AA+NxC,wBAMG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
1
+ {"version":3,"file":"ResponseSection.vue.d.ts","sourceRoot":"","sources":["../../../../src/views/Request/ResponseSection/ResponseSection.vue"],"names":[],"mappings":"AAuHA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,2CAA2C,CAAA;;cAUrE,gBAAgB,GAAG,SAAS;;cAA5B,gBAAgB,GAAG,SAAS;;AAgOxC,wBAMG;AAOH,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AAC5D,KAAK,uBAAuB,CAAC,CAAC,IAAI;KAChC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GACpC;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAC9D;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CACzD,CAAC"}
@@ -35,17 +35,17 @@ const E = { class: "flex items-center flex-1" }, H = { class: "custom-scroll fle
35
35
  value: e[m],
36
36
  required: !1
37
37
  })) : [];
38
- }), _ = i(() => {
38
+ }), k = i(() => {
39
39
  var o;
40
40
  const e = (o = a.response) == null ? void 0 : o.data;
41
41
  return e && V(e) ? JSON.stringify(JSON.parse(e), null, 2) : e && typeof h(e) == "object" ? JSON.stringify(e, null, 2) : e;
42
- }), k = ["All", "Body", "Headers", "Cookies"], s = x("All");
42
+ }), _ = ["All", "Body", "Headers", "Cookies"], s = x("All");
43
43
  return (e, o) => (r(), n(g, null, {
44
44
  title: u(() => [
45
45
  p(S(R), {
46
- class: "text-c-3 mr-1.5 rotate-180",
46
+ class: "text-c-3 mr-1.5 rotate-180 stroke-2",
47
47
  icon: "ExternalLink",
48
- size: "sm"
48
+ size: "md"
49
49
  }),
50
50
  f("div", E, [
51
51
  C(" Response "),
@@ -60,7 +60,7 @@ const E = { class: "flex items-center flex-1" }, H = { class: "custom-scroll fle
60
60
  e.response ? (r(), A(B, { key: 1 }, [
61
61
  p(N, {
62
62
  activeSection: s.value,
63
- sections: k,
63
+ sections: _,
64
64
  onSetActiveSection: o[0] || (o[0] = (t) => s.value = t)
65
65
  }, null, 8, ["activeSection"]),
66
66
  s.value === "All" || s.value === "Cookies" ? (r(), n(b, {
@@ -74,7 +74,7 @@ const E = { class: "flex items-center flex-1" }, H = { class: "custom-scroll fle
74
74
  s.value === "All" || s.value === "Body" ? (r(), n($, {
75
75
  key: 2,
76
76
  active: !0,
77
- data: _.value,
77
+ data: k.value,
78
78
  headers: c.value,
79
79
  title: "Body"
80
80
  }, null, 8, ["data", "headers"])) : l("", !0)
package/package.json CHANGED
@@ -18,7 +18,7 @@
18
18
  "rest",
19
19
  "testing"
20
20
  ],
21
- "version": "2.0.5",
21
+ "version": "2.0.7",
22
22
  "engines": {
23
23
  "node": ">=18"
24
24
  },
@@ -102,6 +102,7 @@
102
102
  "@vueuse/core": "^10.10.0",
103
103
  "axios": "^1.6.8",
104
104
  "cva": "1.0.0-beta.1",
105
+ "fuse.js": "^7.0.0",
105
106
  "js-cookie": "^3.0.5",
106
107
  "nanoid": "^5.0.7",
107
108
  "pretty-bytes": "^6.1.1",
@@ -109,10 +110,12 @@
109
110
  "vue": "^3.4.22",
110
111
  "vue-router": "^4.3.0",
111
112
  "zod": "^3.22.4",
113
+ "@scalar/components": "0.12.8",
112
114
  "@scalar/draggable": "0.1.3",
113
- "@scalar/components": "0.12.7",
114
- "@scalar/object-utils": "1.1.2",
115
- "@scalar/oas-utils": "0.2.8",
115
+ "@scalar/object-utils": "1.1.3",
116
+ "@scalar/oas-utils": "0.2.9",
117
+ "@scalar/use-codemirror": "0.11.4",
118
+ "@scalar/themes": "0.9.11",
116
119
  "@scalar/use-toasts": "0.7.4",
117
120
  "@scalar/use-tooltip": "1.0.2"
118
121
  },
@@ -121,7 +124,6 @@
121
124
  "@types/js-cookie": "^3.0.6",
122
125
  "@vitejs/plugin-vue": "^5.0.4",
123
126
  "autoprefixer": "^10.4.19",
124
- "fuse.js": "^7.0.0",
125
127
  "jsdom": "^22.1.0",
126
128
  "postcss": "^8.4.38",
127
129
  "tailwindcss": "^3.4.4",
@@ -132,9 +134,7 @@
132
134
  "vite-svg-loader": "^5.1.0",
133
135
  "vitest": "^1.6.0",
134
136
  "vue-tsc": "^2.0.13",
135
- "@scalar/build-tooling": "0.1.8",
136
- "@scalar/themes": "0.9.10",
137
- "@scalar/use-codemirror": "0.11.4"
137
+ "@scalar/build-tooling": "0.1.8"
138
138
  },
139
139
  "scripts": {
140
140
  "build": "vite build && pnpm types:build && tsc-alias -p tsconfig.build.json",