@scalar/api-client 2.2.56 → 2.2.57
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.
- package/CHANGELOG.md +33 -0
- package/dist/components/AddressBar/AddressBarHistory.vue.d.ts.map +1 -1
- package/dist/components/AddressBar/AddressBarHistory.vue.js +2 -2
- package/dist/components/AddressBar/AddressBarHistory.vue2.js +53 -54
- package/dist/components/CodeInput/CodeInput.vue.d.ts +1 -1
- package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +3 -19
- package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue.js +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue2.js +154 -129
- package/dist/components/DataTable/DataTableInput.vue.d.ts +4 -4
- package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarToggle.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarToggle.vue.js +17 -16
- package/dist/layouts/App/create-api-client-app.d.ts +62 -52
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.d.ts +120 -100
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.js +1 -2
- package/dist/layouts/Web/create-api-client-web.d.ts +62 -52
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/libs/create-client.d.ts +64 -58
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/create-client.js +82 -80
- package/dist/libs/extractAttachmentFilename.d.ts.map +1 -1
- package/dist/libs/extractAttachmentFilename.js +8 -7
- package/dist/libs/find-request.d.ts +1 -1
- package/dist/libs/find-request.d.ts.map +1 -1
- package/dist/libs/hot-keys.d.ts +1 -1
- package/dist/libs/hot-keys.d.ts.map +1 -1
- package/dist/libs/hot-keys.js +9 -8
- package/dist/libs/send-request/create-request-operation.test.d.ts +3 -2
- package/dist/libs/send-request/create-request-operation.test.d.ts.map +1 -1
- package/dist/store/active-entities.d.ts +4 -3
- package/dist/store/active-entities.d.ts.map +1 -1
- package/dist/store/import-spec.d.ts +3 -3
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/import-spec.js +4 -1
- package/dist/store/request-example.d.ts +22 -12
- package/dist/store/request-example.d.ts.map +1 -1
- package/dist/store/requests.d.ts +13 -13
- package/dist/store/requests.d.ts.map +1 -1
- package/dist/store/security-schemes.d.ts +6 -6
- package/dist/store/store.d.ts +92 -67
- package/dist/store/store.d.ts.map +1 -1
- package/dist/store/store.js +12 -12
- package/dist/store/workspace.d.ts +12 -12
- package/dist/store/workspace.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/views/Request/Request.vue.d.ts.map +1 -1
- package/dist/views/Request/Request.vue.js +2 -2
- package/dist/views/Request/RequestRoot.test.d.ts +2 -0
- package/dist/views/Request/RequestRoot.test.d.ts.map +1 -0
- package/dist/views/Request/RequestRoot.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestRoot.vue.js +2 -2
- package/dist/views/Request/RequestRoot.vue2.js +72 -60
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTableInput.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestBody.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestBody.vue2.js +113 -107
- package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestSection.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestSection.vue2.js +37 -37
- package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestTable.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestTable.vue2.js +55 -51
- package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebar.vue.js +2 -2
- package/dist/views/Request/RequestSidebar.vue2.js +171 -166
- package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebarItem.vue.js +1 -1
- package/dist/views/Request/RequestSidebarItem.vue2.js +187 -180
- package/dist/views/Request/RequestSubpageHeader.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSubpageHeader.vue.js +2 -2
- package/dist/views/Request/RequestSubpageHeader.vue2.js +41 -49
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +2 -2
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +62 -45
- package/package.json +12 -12
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts +0 -15
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +0 -1
- package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +0 -176
- package/dist/components/CommandPalette/CommandPaletteRequest.vue2.js +0 -4
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { defineComponent as ve, useCssVars as ge, computed as
|
|
2
|
-
import { ScalarButton as
|
|
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
3
|
import { Draggable as xe } from "@scalar/draggable";
|
|
4
4
|
import { shouldIgnoreEntity as te } from "@scalar/oas-utils/helpers";
|
|
5
5
|
import { useRouter as ke, RouterLink as ie } from "vue-router";
|
|
6
6
|
import { useLayout as we } from "../../hooks/useLayout.js";
|
|
7
7
|
import { useSidebar as Ue } from "../../hooks/useSidebar.js";
|
|
8
8
|
import { useActiveEntities as qe } from "../../store/active-entities.js";
|
|
9
|
-
import { PathId as
|
|
9
|
+
import { PathId as S } from "../../routes.js";
|
|
10
10
|
import Ce from "../../components/HttpMethod/HttpMethod.vue.js";
|
|
11
11
|
import { getModifiers as De } from "../../libs/hot-keys.js";
|
|
12
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" },
|
|
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({
|
|
14
14
|
__name: "RequestSidebarItem",
|
|
15
15
|
props: {
|
|
16
16
|
isDraggable: { type: Boolean, default: !1 },
|
|
@@ -20,45 +20,45 @@ 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(
|
|
23
|
+
setup(l, { emit: ne }) {
|
|
24
24
|
ge((e) => ({
|
|
25
|
-
"
|
|
26
|
-
"
|
|
25
|
+
"98b93bde": re.value,
|
|
26
|
+
"24740e0d": ue.value
|
|
27
27
|
}));
|
|
28
|
-
const
|
|
29
|
-
collections:
|
|
30
|
-
tags:
|
|
31
|
-
requests:
|
|
28
|
+
const se = ne, { activeCollection: le, activeRequest: V, activeRouterParams: oe, activeWorkspace: q } = qe(), {
|
|
29
|
+
collections: T,
|
|
30
|
+
tags: z,
|
|
31
|
+
requests: B,
|
|
32
32
|
requestExamples: j,
|
|
33
|
-
collectionMutators:
|
|
34
|
-
tagMutators:
|
|
35
|
-
requestMutators:
|
|
33
|
+
collectionMutators: W,
|
|
34
|
+
tagMutators: F,
|
|
35
|
+
requestMutators: N,
|
|
36
36
|
requestExampleMutators: Y,
|
|
37
37
|
events: ae
|
|
38
|
-
} = Re(),
|
|
39
|
-
var
|
|
40
|
-
const e =
|
|
38
|
+
} = Re(), x = ke(), { collapsedSidebarFolders: I, toggleSidebarFolder: H } = Ue(), { layout: p } = we(), i = b(() => {
|
|
39
|
+
var g, o, d, k, $, J;
|
|
40
|
+
const e = T[l.uid], t = z[l.uid], r = B[l.uid], a = j[l.uid];
|
|
41
41
|
return e ? {
|
|
42
|
-
title: ((
|
|
42
|
+
title: ((g = e.info) == null ? void 0 : g.title) || "Untitled Collection",
|
|
43
43
|
entity: e,
|
|
44
44
|
resourceTitle: "Collection",
|
|
45
45
|
children: e.children,
|
|
46
46
|
icon: e["x-scalar-icon"],
|
|
47
47
|
documentUrl: e.documentUrl,
|
|
48
48
|
watchMode: e.watchMode,
|
|
49
|
-
to: e.uid && ((
|
|
49
|
+
to: e.uid && ((o = e == null ? void 0 : e.info) == null ? void 0 : o.title) !== "Drafts" ? {
|
|
50
50
|
name: "collection",
|
|
51
51
|
params: {
|
|
52
|
-
[
|
|
53
|
-
[
|
|
52
|
+
[S.Workspace]: (d = q.value) == null ? void 0 : d.uid,
|
|
53
|
+
[S.Collection]: e.uid
|
|
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: (
|
|
58
|
-
|
|
57
|
+
edit: (w, Q) => {
|
|
58
|
+
W.edit(e.uid, "info.title", w), Q && W.edit(e.uid, "x-scalar-icon", Q);
|
|
59
59
|
},
|
|
60
60
|
delete: () => {
|
|
61
|
-
|
|
61
|
+
q.value && W.delete(e, q.value);
|
|
62
62
|
}
|
|
63
63
|
} : t ? {
|
|
64
64
|
title: t.name,
|
|
@@ -66,14 +66,14 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
|
|
|
66
66
|
resourceTitle: "Tag",
|
|
67
67
|
children: t.children,
|
|
68
68
|
warning: "This cannot be undone. You’re about to delete the tag and all requests inside it",
|
|
69
|
-
edit: (
|
|
70
|
-
delete: () =>
|
|
69
|
+
edit: (w) => F.edit(t.uid, "name", w),
|
|
70
|
+
delete: () => l.parentUids[0] && F.delete(t, l.parentUids[0])
|
|
71
71
|
} : r ? {
|
|
72
72
|
title: r.summary ?? r.path,
|
|
73
73
|
to: {
|
|
74
74
|
name: "request",
|
|
75
75
|
params: {
|
|
76
|
-
workspace: (
|
|
76
|
+
workspace: (k = q.value) == null ? void 0 : k.uid,
|
|
77
77
|
request: r.uid
|
|
78
78
|
}
|
|
79
79
|
},
|
|
@@ -82,25 +82,25 @@ 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: (
|
|
86
|
-
delete: () =>
|
|
87
|
-
} :
|
|
88
|
-
title:
|
|
85
|
+
edit: (w) => N.edit(r.uid, "summary", w),
|
|
86
|
+
delete: () => l.parentUids[0] && N.delete(r, l.parentUids[0])
|
|
87
|
+
} : a != null && a.requestUid ? {
|
|
88
|
+
title: a.name,
|
|
89
89
|
to: {
|
|
90
90
|
name: "request.examples",
|
|
91
91
|
params: {
|
|
92
|
-
workspace: (
|
|
93
|
-
request:
|
|
94
|
-
examples:
|
|
92
|
+
workspace: ($ = q.value) == null ? void 0 : $.uid,
|
|
93
|
+
request: a.requestUid,
|
|
94
|
+
examples: a.uid
|
|
95
95
|
}
|
|
96
96
|
},
|
|
97
|
-
method: (
|
|
98
|
-
entity:
|
|
97
|
+
method: (J = B[a.requestUid]) == null ? void 0 : J.method,
|
|
98
|
+
entity: a,
|
|
99
99
|
resourceTitle: "Example",
|
|
100
100
|
warning: "This cannot be undone. You’re about to delete the example from the request.",
|
|
101
101
|
children: [],
|
|
102
|
-
edit: (
|
|
103
|
-
delete: () => Y.delete(
|
|
102
|
+
edit: (w) => Y.edit(a.uid, "name", w),
|
|
103
|
+
delete: () => Y.delete(a)
|
|
104
104
|
} : {
|
|
105
105
|
title: "Unknown",
|
|
106
106
|
entity: {
|
|
@@ -112,143 +112,150 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
|
|
|
112
112
|
edit: () => null,
|
|
113
113
|
delete: () => null
|
|
114
114
|
};
|
|
115
|
-
}),
|
|
115
|
+
}), M = b(
|
|
116
116
|
() => i.value.entity.type === "collection" && i.value.title === "Drafts"
|
|
117
|
-
), re =
|
|
117
|
+
), re = b(() => l.parentUids.length ? p === "modal" ? `${(l.parentUids.length - 1) * 12}px` : `${l.parentUids.length * 12}px` : "12px"), ue = b(() => l.parentUids.length ? p === "modal" ? `${(l.parentUids.length - 1) * 12}px` : `${l.parentUids.length * 12}px` : "0px"), de = b(
|
|
118
118
|
() => {
|
|
119
119
|
var e;
|
|
120
|
-
return I[
|
|
120
|
+
return I[l.uid] || ((e = V.value) == null ? void 0 : e.uid) === l.uid && i.value.entity.examples.length > 1;
|
|
121
121
|
}
|
|
122
|
-
), pe =
|
|
122
|
+
), pe = b(
|
|
123
123
|
() => {
|
|
124
124
|
var e;
|
|
125
|
-
return typeof
|
|
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;
|
|
126
126
|
}
|
|
127
|
-
),
|
|
127
|
+
), O = be(null), L = b(() => {
|
|
128
128
|
let e = 0.5, t = 0.5;
|
|
129
|
-
if (!
|
|
130
|
-
const { draggingItem: r } =
|
|
131
|
-
return !
|
|
132
|
-
}),
|
|
133
|
-
e && (De(["default"]).some((
|
|
129
|
+
if (!O.value) return { ceiling: e, floor: t };
|
|
130
|
+
const { draggingItem: r } = O.value;
|
|
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
|
+
}), 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));
|
|
134
134
|
};
|
|
135
|
-
function
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
135
|
+
function A(e) {
|
|
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(
|
|
138
|
+
r,
|
|
139
|
+
t
|
|
140
|
+
);
|
|
141
|
+
a && (x.push({
|
|
142
|
+
name: "request",
|
|
143
|
+
params: {
|
|
144
|
+
workspace: (d = q.value) == null ? void 0 : d.uid,
|
|
145
|
+
request: a.uid
|
|
141
146
|
}
|
|
142
|
-
})
|
|
147
|
+
}), ae.hotKeys.emit({
|
|
148
|
+
focusAddressBar: new KeyboardEvent("keydown", { key: "l" })
|
|
149
|
+
}));
|
|
143
150
|
}
|
|
144
|
-
const G =
|
|
145
|
-
const { uid: e, watchModeStatus: t } =
|
|
151
|
+
const G = b(() => {
|
|
152
|
+
const { uid: e, watchModeStatus: t } = le.value || {};
|
|
146
153
|
return e !== i.value.entity.uid ? "text-c-3" : t === "WATCHING" ? "text-c-1" : t === "ERROR" ? "text-red" : "text-c-3";
|
|
147
|
-
}),
|
|
148
|
-
const e =
|
|
154
|
+
}), K = b(() => i.value.title === "Drafts" && p !== "modal" && i.value.children.length > 0), me = b(() => {
|
|
155
|
+
const e = B[l.uid];
|
|
149
156
|
if (e) return !te(e);
|
|
150
|
-
const t =
|
|
157
|
+
const t = z[l.uid];
|
|
151
158
|
return t ? !te(t) : !0;
|
|
152
159
|
});
|
|
153
160
|
return (e, t) => {
|
|
154
|
-
const r =
|
|
155
|
-
return me.value ? (
|
|
161
|
+
const r = ye("RequestSidebarItem", !0);
|
|
162
|
+
return me.value ? (u(), C("li", {
|
|
156
163
|
key: 0,
|
|
157
|
-
class:
|
|
158
|
-
n(
|
|
164
|
+
class: y(["relative flex flex-row", [
|
|
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" : ""
|
|
159
166
|
]])
|
|
160
167
|
}, [
|
|
161
168
|
v(n(xe), {
|
|
162
169
|
id: i.value.entity.uid,
|
|
163
170
|
ref_key: "draggableRef",
|
|
164
|
-
ref:
|
|
171
|
+
ref: O,
|
|
165
172
|
ceiling: L.value.ceiling,
|
|
166
173
|
class: "gap-1/2 flex flex-1 flex-col text-sm",
|
|
167
174
|
floor: L.value.floor,
|
|
168
175
|
isDraggable: e.isDraggable,
|
|
169
176
|
isDroppable: e.isDroppable,
|
|
170
177
|
parentIds: e.parentUids,
|
|
171
|
-
onOnDragEnd: t[13] || (t[13] = (...
|
|
178
|
+
onOnDragEnd: t[13] || (t[13] = (...a) => e.$emit("onDragEnd", ...a))
|
|
172
179
|
}, {
|
|
173
|
-
default:
|
|
174
|
-
var
|
|
180
|
+
default: c(() => {
|
|
181
|
+
var a, g;
|
|
175
182
|
return [
|
|
176
|
-
(i.value.entity.type === "request" || i.value.entity.type === "requestExample") && i.value.to ? (
|
|
183
|
+
(i.value.entity.type === "request" || i.value.entity.type === "requestExample") && i.value.to ? (u(), f(n(ie), {
|
|
177
184
|
key: 0,
|
|
178
185
|
class: "group no-underline",
|
|
179
186
|
to: i.value.to,
|
|
180
|
-
onClick: t[1] || (t[1] =
|
|
181
|
-
(
|
|
187
|
+
onClick: t[1] || (t[1] = U(
|
|
188
|
+
(o) => fe(o, i.value),
|
|
182
189
|
["prevent"]
|
|
183
190
|
))
|
|
184
191
|
}, {
|
|
185
|
-
default:
|
|
186
|
-
var
|
|
192
|
+
default: c(({ isExactActive: o }) => {
|
|
193
|
+
var d, k;
|
|
187
194
|
return [
|
|
188
|
-
|
|
189
|
-
class:
|
|
190
|
-
|
|
191
|
-
|
|
195
|
+
s("div", {
|
|
196
|
+
class: y(["relative flex min-h-8 w-full cursor-pointer flex-row items-start justify-between gap-0.5 rounded py-1.5 pr-2", [
|
|
197
|
+
P,
|
|
198
|
+
o || pe.value ? "bg-sidebar-active-b text-sidebar-active-c transition-none" : "text-sidebar-c-2"
|
|
192
199
|
]])
|
|
193
200
|
}, [
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
n(
|
|
201
|
+
s("span", Ie, D(i.value.title || "Untitled"), 1),
|
|
202
|
+
s("div", Te, [
|
|
203
|
+
s("div", ze, [
|
|
204
|
+
n(p) !== "modal" ? (u(), f(n(R), {
|
|
198
205
|
key: 0,
|
|
199
|
-
class:
|
|
200
|
-
flex: ((
|
|
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", {
|
|
207
|
+
flex: ((k = (d = e.menuItem) == null ? void 0 : d.item) == null ? void 0 : k.entity.uid) === i.value.entity.uid && e.menuItem.open
|
|
201
208
|
}]),
|
|
202
209
|
size: "sm",
|
|
203
210
|
type: "button",
|
|
204
211
|
variant: "ghost",
|
|
205
|
-
onClick: t[0] || (t[0] =
|
|
206
|
-
(
|
|
212
|
+
onClick: t[0] || (t[0] = U(
|
|
213
|
+
($) => e.$emit("openMenu", {
|
|
207
214
|
item: i.value,
|
|
208
215
|
parentUids: e.parentUids,
|
|
209
|
-
targetRef:
|
|
216
|
+
targetRef: $.currentTarget,
|
|
210
217
|
open: !e.menuItem.open
|
|
211
218
|
}),
|
|
212
219
|
["stop", "prevent"]
|
|
213
220
|
))
|
|
214
221
|
}, {
|
|
215
|
-
default:
|
|
222
|
+
default: c(() => [
|
|
216
223
|
v(n(h), {
|
|
217
224
|
icon: "Ellipses",
|
|
218
225
|
size: "md"
|
|
219
226
|
})
|
|
220
227
|
]),
|
|
221
228
|
_: 1
|
|
222
|
-
}, 8, ["class"])) :
|
|
229
|
+
}, 8, ["class"])) : m("", !0)
|
|
223
230
|
]),
|
|
224
|
-
|
|
225
|
-
t[14] || (t[14] =
|
|
226
|
-
t[15] || (t[15] =
|
|
227
|
-
i.value.method ? (
|
|
231
|
+
s("span", Me, [
|
|
232
|
+
t[14] || (t[14] = E(" ")),
|
|
233
|
+
t[15] || (t[15] = s("span", { class: "sr-only" }, "HTTP Method:", -1)),
|
|
234
|
+
i.value.method ? (u(), f(n(Ce), {
|
|
228
235
|
key: 0,
|
|
229
236
|
class: "font-bold",
|
|
230
237
|
method: i.value.method
|
|
231
|
-
}, null, 8, ["method"])) :
|
|
238
|
+
}, null, 8, ["method"])) : m("", !0)
|
|
232
239
|
])
|
|
233
240
|
])
|
|
234
241
|
], 2)
|
|
235
242
|
];
|
|
236
243
|
}),
|
|
237
244
|
_: 1
|
|
238
|
-
}, 8, ["to"])) : (n(
|
|
245
|
+
}, 8, ["to"])) : (n(p) !== "modal" || e.parentUids.length) && i.value.entity.type === "collection" ? (u(), C("div", {
|
|
239
246
|
key: 1,
|
|
240
247
|
"aria-expanded": !!n(I)[i.value.entity.uid],
|
|
241
|
-
class:
|
|
242
|
-
|
|
248
|
+
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", [
|
|
249
|
+
P,
|
|
243
250
|
{
|
|
244
|
-
"bg-sidebar-active-b text-sidebar-active-c transition-none": typeof n(
|
|
251
|
+
"bg-sidebar-active-b text-sidebar-active-c transition-none": typeof n(x).currentRoute.value.name == "string" && n(x).currentRoute.value.name.startsWith("collection") && n(x).currentRoute.value.params[n(S).Collection] === i.value.entity.uid,
|
|
245
252
|
"text-c-2": i.value.title === "Untitled Collection"
|
|
246
253
|
}
|
|
247
254
|
]])
|
|
248
255
|
}, [
|
|
249
|
-
|
|
256
|
+
s("span", {
|
|
250
257
|
class: "flex h-5 max-w-[14px] cursor-pointer items-center justify-center",
|
|
251
|
-
onClick: t[2] || (t[2] = (
|
|
258
|
+
onClick: t[2] || (t[2] = (o) => n(H)(i.value.entity.uid))
|
|
252
259
|
}, [
|
|
253
260
|
X(e.$slots, "leftIcon", {}, () => [
|
|
254
261
|
v(n(_), {
|
|
@@ -256,61 +263,61 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
|
|
|
256
263
|
open: !!n(I)[i.value.entity.uid]
|
|
257
264
|
}, null, 8, ["open"])
|
|
258
265
|
], !0),
|
|
259
|
-
t[16] || (t[16] =
|
|
266
|
+
t[16] || (t[16] = E(" "))
|
|
260
267
|
]),
|
|
261
|
-
|
|
262
|
-
i.value.to ? (
|
|
268
|
+
s("div", Ee, [
|
|
269
|
+
i.value.to ? (u(), f(n(ie), {
|
|
263
270
|
key: 0,
|
|
264
271
|
class: "w-full no-underline",
|
|
265
272
|
to: i.value.to,
|
|
266
|
-
onClick: t[3] || (t[3] =
|
|
273
|
+
onClick: t[3] || (t[3] = U(() => {
|
|
267
274
|
}, ["stop", "prevent"]))
|
|
268
275
|
}, {
|
|
269
|
-
default:
|
|
270
|
-
|
|
276
|
+
default: c(() => [
|
|
277
|
+
s("span", Se, D(i.value.title), 1)
|
|
271
278
|
]),
|
|
272
279
|
_: 1
|
|
273
|
-
}, 8, ["to"])) : (
|
|
274
|
-
|
|
280
|
+
}, 8, ["to"])) : (u(), C(Z, { key: 1 }, [
|
|
281
|
+
E(D(i.value.title), 1)
|
|
275
282
|
], 64)),
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
class:
|
|
283
|
+
s("div", Be, [
|
|
284
|
+
s("div", {
|
|
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", {
|
|
279
286
|
flex: e.menuItem.open,
|
|
280
|
-
hidden: !e.menuItem.open || ((
|
|
287
|
+
hidden: !e.menuItem.open || ((a = e.menuItem.item) == null ? void 0 : a.entity.uid) !== i.value.entity.uid
|
|
281
288
|
}])
|
|
282
289
|
}, [
|
|
283
|
-
n(
|
|
290
|
+
n(p) !== "modal" && !M.value || M.value && K.value ? (u(), f(n(R), {
|
|
284
291
|
key: 0,
|
|
285
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",
|
|
286
293
|
size: "sm",
|
|
287
294
|
variant: "ghost",
|
|
288
|
-
onClick: t[4] || (t[4] =
|
|
289
|
-
(
|
|
295
|
+
onClick: t[4] || (t[4] = U(
|
|
296
|
+
(o) => e.$emit("openMenu", {
|
|
290
297
|
item: i.value,
|
|
291
298
|
parentUids: e.parentUids,
|
|
292
|
-
targetRef:
|
|
299
|
+
targetRef: o.currentTarget.parentNode,
|
|
293
300
|
open: !0
|
|
294
301
|
}),
|
|
295
302
|
["stop", "prevent"]
|
|
296
303
|
))
|
|
297
304
|
}, {
|
|
298
|
-
default:
|
|
305
|
+
default: c(() => [
|
|
299
306
|
v(n(h), {
|
|
300
307
|
icon: "Ellipses",
|
|
301
308
|
size: "md"
|
|
302
309
|
})
|
|
303
310
|
]),
|
|
304
311
|
_: 1
|
|
305
|
-
})) :
|
|
306
|
-
n(
|
|
312
|
+
})) : m("", !0),
|
|
313
|
+
n(p) !== "modal" ? (u(), f(n(R), {
|
|
307
314
|
key: 1,
|
|
308
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",
|
|
309
316
|
size: "sm",
|
|
310
317
|
variant: "ghost",
|
|
311
|
-
onClick: t[5] || (t[5] =
|
|
318
|
+
onClick: t[5] || (t[5] = U((o) => A(i.value.entity.uid), ["stop", "prevent"]))
|
|
312
319
|
}, {
|
|
313
|
-
default:
|
|
320
|
+
default: c(() => [
|
|
314
321
|
v(n(h), {
|
|
315
322
|
icon: "Add",
|
|
316
323
|
size: "md",
|
|
@@ -318,89 +325,89 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
|
|
|
318
325
|
})
|
|
319
326
|
]),
|
|
320
327
|
_: 1
|
|
321
|
-
})) :
|
|
328
|
+
})) : m("", !0)
|
|
322
329
|
], 2),
|
|
323
|
-
i.value.watchMode ? (
|
|
330
|
+
i.value.watchMode ? (u(), f(n(ee), {
|
|
324
331
|
key: 0,
|
|
325
332
|
side: "right",
|
|
326
333
|
sideOffset: 12
|
|
327
334
|
}, {
|
|
328
|
-
trigger:
|
|
335
|
+
trigger: c(() => [
|
|
329
336
|
v(n(h), {
|
|
330
|
-
class:
|
|
337
|
+
class: y(["ml-0.5 text-sm", G.value]),
|
|
331
338
|
icon: "Watch",
|
|
332
339
|
size: "md",
|
|
333
340
|
thickness: "2"
|
|
334
341
|
}, null, 8, ["class"])
|
|
335
342
|
]),
|
|
336
|
-
content:
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
343
|
+
content: c(() => [
|
|
344
|
+
s("div", je, [
|
|
345
|
+
s("div", We, [
|
|
346
|
+
s("p", Ne, " Watching: " + D(i.value.documentUrl), 1)
|
|
340
347
|
])
|
|
341
348
|
])
|
|
342
349
|
]),
|
|
343
350
|
_: 1
|
|
344
|
-
})) :
|
|
345
|
-
t[17] || (t[17] =
|
|
351
|
+
})) : m("", !0),
|
|
352
|
+
t[17] || (t[17] = s("span", null, " ", -1))
|
|
346
353
|
])
|
|
347
354
|
])
|
|
348
|
-
], 10, $e)) : n(
|
|
355
|
+
], 10, $e)) : n(p) !== "modal" || e.parentUids.length ? (u(), C("button", {
|
|
349
356
|
key: 2,
|
|
350
357
|
"aria-expanded": !!n(I)[i.value.entity.uid],
|
|
351
|
-
class:
|
|
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]]),
|
|
352
359
|
type: "button",
|
|
353
|
-
onClick: t[8] || (t[8] = (
|
|
360
|
+
onClick: t[8] || (t[8] = (o) => n(H)(i.value.entity.uid))
|
|
354
361
|
}, [
|
|
355
|
-
|
|
362
|
+
s("span", Ae, [
|
|
356
363
|
X(e.$slots, "leftIcon", {}, () => [
|
|
357
364
|
v(n(_), {
|
|
358
365
|
class: "text-c-3 hover:text-c-1 shrink-0",
|
|
359
366
|
open: !!n(I)[i.value.entity.uid]
|
|
360
367
|
}, null, 8, ["open"])
|
|
361
368
|
], !0),
|
|
362
|
-
t[18] || (t[18] =
|
|
369
|
+
t[18] || (t[18] = E(" "))
|
|
363
370
|
]),
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
class:
|
|
371
|
+
s("div", Pe, [
|
|
372
|
+
s("span", Ve, D(i.value.title), 1),
|
|
373
|
+
s("div", Fe, [
|
|
374
|
+
s("div", {
|
|
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", {
|
|
369
376
|
flex: e.menuItem.open,
|
|
370
|
-
hidden: !e.menuItem.open || ((
|
|
377
|
+
hidden: !e.menuItem.open || ((g = e.menuItem.item) == null ? void 0 : g.entity.uid) !== i.value.entity.uid
|
|
371
378
|
}])
|
|
372
379
|
}, [
|
|
373
|
-
n(
|
|
380
|
+
n(p) !== "modal" && !M.value || M.value && K.value ? (u(), f(n(R), {
|
|
374
381
|
key: 0,
|
|
375
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",
|
|
376
383
|
size: "sm",
|
|
377
384
|
variant: "ghost",
|
|
378
|
-
onClick: t[6] || (t[6] =
|
|
379
|
-
(
|
|
385
|
+
onClick: t[6] || (t[6] = U(
|
|
386
|
+
(o) => e.$emit("openMenu", {
|
|
380
387
|
item: i.value,
|
|
381
388
|
parentUids: e.parentUids,
|
|
382
|
-
targetRef:
|
|
389
|
+
targetRef: o.currentTarget.parentNode,
|
|
383
390
|
open: !0
|
|
384
391
|
}),
|
|
385
392
|
["stop", "prevent"]
|
|
386
393
|
))
|
|
387
394
|
}, {
|
|
388
|
-
default:
|
|
395
|
+
default: c(() => [
|
|
389
396
|
v(n(h), {
|
|
390
397
|
icon: "Ellipses",
|
|
391
398
|
size: "md"
|
|
392
399
|
})
|
|
393
400
|
]),
|
|
394
401
|
_: 1
|
|
395
|
-
})) :
|
|
396
|
-
n(
|
|
402
|
+
})) : m("", !0),
|
|
403
|
+
n(p) !== "modal" ? (u(), f(n(R), {
|
|
397
404
|
key: 1,
|
|
398
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",
|
|
399
406
|
size: "sm",
|
|
400
407
|
variant: "ghost",
|
|
401
|
-
onClick: t[7] || (t[7] =
|
|
408
|
+
onClick: t[7] || (t[7] = U((o) => A(i.value.entity.uid), ["stop", "prevent"]))
|
|
402
409
|
}, {
|
|
403
|
-
default:
|
|
410
|
+
default: c(() => [
|
|
404
411
|
v(n(h), {
|
|
405
412
|
icon: "Add",
|
|
406
413
|
size: "md",
|
|
@@ -408,70 +415,70 @@ const Ie = { class: "line-clamp-1 w-full break-all pl-2 font-medium" }, Te = { c
|
|
|
408
415
|
})
|
|
409
416
|
]),
|
|
410
417
|
_: 1
|
|
411
|
-
})) :
|
|
418
|
+
})) : m("", !0)
|
|
412
419
|
], 2),
|
|
413
|
-
i.value.watchMode ? (
|
|
420
|
+
i.value.watchMode ? (u(), f(n(ee), {
|
|
414
421
|
key: 0,
|
|
415
422
|
side: "right",
|
|
416
423
|
sideOffset: 12
|
|
417
424
|
}, {
|
|
418
|
-
trigger:
|
|
425
|
+
trigger: c(() => [
|
|
419
426
|
v(n(h), {
|
|
420
|
-
class:
|
|
427
|
+
class: y(["ml-0.5 text-sm", G.value]),
|
|
421
428
|
icon: "Watch",
|
|
422
429
|
size: "md",
|
|
423
430
|
thickness: "2"
|
|
424
431
|
}, null, 8, ["class"])
|
|
425
432
|
]),
|
|
426
|
-
content:
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
433
|
+
content: c(() => [
|
|
434
|
+
s("div", Ye, [
|
|
435
|
+
s("div", He, [
|
|
436
|
+
s("p", Le, " Watching: " + D(i.value.documentUrl), 1)
|
|
430
437
|
])
|
|
431
438
|
])
|
|
432
439
|
]),
|
|
433
440
|
_: 1
|
|
434
|
-
})) :
|
|
435
|
-
t[19] || (t[19] =
|
|
441
|
+
})) : m("", !0),
|
|
442
|
+
t[19] || (t[19] = s("span", null, " ", -1))
|
|
436
443
|
])
|
|
437
444
|
])
|
|
438
|
-
], 10, Oe)) :
|
|
439
|
-
de.value ? (
|
|
440
|
-
(
|
|
441
|
-
key:
|
|
442
|
-
isDraggable: !n(j)[
|
|
443
|
-
isDroppable:
|
|
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, {
|
|
448
|
+
key: o,
|
|
449
|
+
isDraggable: !n(j)[o],
|
|
450
|
+
isDroppable: ce,
|
|
444
451
|
menuItem: e.menuItem,
|
|
445
452
|
parentUids: [...e.parentUids, e.uid],
|
|
446
|
-
uid:
|
|
447
|
-
onNewTab: t[9] || (t[9] = (
|
|
448
|
-
onOnDragEnd: t[10] || (t[10] = (...
|
|
449
|
-
onOpenMenu: t[11] || (t[11] = (
|
|
453
|
+
uid: o,
|
|
454
|
+
onNewTab: t[9] || (t[9] = (d, k) => e.$emit("newTab", d, k)),
|
|
455
|
+
onOnDragEnd: t[10] || (t[10] = (...d) => e.$emit("onDragEnd", ...d)),
|
|
456
|
+
onOpenMenu: t[11] || (t[11] = (d) => e.$emit("openMenu", d))
|
|
450
457
|
}, null, 8, ["isDraggable", "menuItem", "parentUids", "uid"]))), 128)),
|
|
451
|
-
i.value.children.length === 0 ? (
|
|
458
|
+
i.value.children.length === 0 ? (u(), f(n(R), {
|
|
452
459
|
key: 0,
|
|
453
|
-
class:
|
|
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" : ""]),
|
|
454
461
|
variant: "ghost",
|
|
455
|
-
onClick: t[12] || (t[12] = (
|
|
462
|
+
onClick: t[12] || (t[12] = (o) => A(i.value.entity.uid))
|
|
456
463
|
}, {
|
|
457
|
-
default:
|
|
464
|
+
default: c(() => [
|
|
458
465
|
v(n(h), {
|
|
459
466
|
icon: "Add",
|
|
460
467
|
size: "sm"
|
|
461
468
|
}),
|
|
462
|
-
t[20] || (t[20] =
|
|
469
|
+
t[20] || (t[20] = s("span", null, "Add Request", -1))
|
|
463
470
|
]),
|
|
464
471
|
_: 1
|
|
465
|
-
}, 8, ["class"])) :
|
|
466
|
-
])) :
|
|
472
|
+
}, 8, ["class"])) : m("", !0)
|
|
473
|
+
])) : m("", !0)
|
|
467
474
|
];
|
|
468
475
|
}),
|
|
469
476
|
_: 3
|
|
470
477
|
}, 8, ["id", "ceiling", "floor", "isDraggable", "isDroppable", "parentIds"])
|
|
471
|
-
], 2)) :
|
|
478
|
+
], 2)) : m("", !0);
|
|
472
479
|
};
|
|
473
480
|
}
|
|
474
481
|
});
|
|
475
482
|
export {
|
|
476
|
-
|
|
483
|
+
ot as default
|
|
477
484
|
};
|