@scalar/api-client 2.5.31 → 2.5.33
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/AddressBar.vue.js +1 -1
- package/dist/components/AddressBar/AddressBar.vue2.js +120 -128
- package/dist/components/AddressBar/AddressBarHistory.vue.js +1 -1
- package/dist/components/AddressBar/AddressBarHistory.vue2.js +57 -63
- package/dist/components/CodeInput/CodeInput.vue.js +2 -2
- package/dist/components/CodeInput/CodeInput.vue2.js +143 -150
- package/dist/components/CodeInput/codeVariableWidget.js +70 -75
- package/dist/components/CommandPalette/CommandActionInput.vue.js +17 -19
- package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +26 -27
- package/dist/components/CommandPalette/CommandPaletteExample.vue.js +53 -55
- package/dist/components/CommandPalette/CommandPaletteImport.vue.js +129 -133
- package/dist/components/CommandPalette/CommandPaletteImportCurl.vue.js +1 -1
- package/dist/components/CommandPalette/CommandPaletteImportCurl.vue2.js +84 -98
- package/dist/components/CommandPalette/CommandPaletteServer.vue.js +64 -74
- package/dist/components/CommandPalette/CommandPaletteTag.vue.js +5 -11
- package/dist/components/CommandPalette/TheCommandPalette.vue.js +1 -1
- package/dist/components/CommandPalette/TheCommandPalette.vue2.js +164 -183
- package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
- package/dist/components/DataTable/DataTableInput.vue.js +4 -4
- package/dist/components/DataTable/DataTableInput.vue2.js +31 -31
- package/dist/components/DataTable/DataTableInputSelect.vue.js +1 -2
- package/dist/components/EmptyState.vue.js +1 -1
- package/dist/components/EnvironmentSelector/EnvironmentSelector.vue.js +75 -84
- package/dist/components/Form/LabelInput.vue.js +1 -1
- package/dist/components/HttpMethod/HttpMethod.vue.js +1 -1
- package/dist/components/HttpMethod/HttpMethod.vue2.js +11 -11
- package/dist/components/ImportCollection/DropEventListener.vue.js +42 -44
- package/dist/components/ImportCollection/ImportCollectionListener.vue.js +22 -23
- package/dist/components/ImportCollection/ImportCollectionModal.vue.js +141 -149
- package/dist/components/ImportCollection/ImportCollectionModal.vue3.js +1 -1
- package/dist/components/ImportCollection/ImportNowButton.vue.js +22 -23
- package/dist/components/ImportCollection/IntegrationLogo.vue.js +12 -13
- package/dist/components/ImportCollection/PasteEventListener.vue.js +11 -12
- package/dist/components/ImportCollection/WorkspaceSelector.vue.js +69 -76
- package/dist/components/ImportCollection/utils/get-openapi-version.js +8 -8
- package/dist/components/ImportCollection/utils/import-collection.js +14 -14
- package/dist/components/OpenApiClientButton.vue.js +1 -1
- package/dist/components/OpenApiClientButton.vue2.js +10 -10
- package/dist/components/ScalarAsciiArt.vue.js +1 -1
- package/dist/components/ScalarAsciiArt.vue2.js +19 -22
- package/dist/components/Search/useSearch.js +51 -61
- package/dist/components/SectionFilter.vue.js +1 -1
- package/dist/components/SectionFilter.vue2.js +26 -29
- package/dist/components/Server/ServerDropdown.vue.js +70 -96
- package/dist/components/Server/ServerDropdownItem.vue.js +1 -1
- package/dist/components/Server/ServerDropdownItem.vue2.js +57 -67
- package/dist/components/Server/ServerSelector.vue.js +44 -55
- package/dist/components/Server/ServerVariablesForm.vue.js +36 -42
- package/dist/components/Server/ServerVariablesSelect.vue.js +6 -6
- package/dist/components/SideNav/DownloadAppButton.vue.js +1 -1
- package/dist/components/SideNav/SideNav.vue.js +68 -74
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +1 -1
- package/dist/components/Sidebar/Sidebar.vue.js +1 -1
- package/dist/components/Sidebar/SidebarListElement.vue.js +2 -2
- package/dist/components/TopNav/TopNav.vue.js +107 -122
- package/dist/components/TopNav/TopNavItem.vue.js +1 -1
- package/dist/hooks/useFileDialog.js +12 -12
- package/dist/hooks/useResponseBody.js +14 -16
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/layouts/App/ApiClientApp.vue.js +50 -56
- package/dist/layouts/App/ApiClientApp.vue3.js +1 -1
- package/dist/layouts/App/create-api-client-app.js +19 -20
- package/dist/layouts/App/index.js +1 -1
- package/dist/layouts/Modal/ApiClientModal.vue.js +1 -1
- package/dist/layouts/Modal/ApiClientModal.vue2.js +18 -21
- package/dist/layouts/Web/ApiClientWeb.vue.js +45 -51
- package/dist/layouts/Web/ApiClientWeb.vue3.js +1 -1
- package/dist/layouts/Web/create-api-client-web.js +19 -20
- package/dist/layouts/Web/index.js +1 -1
- package/dist/libs/create-client.js +102 -109
- package/dist/libs/env-helpers.js +3 -3
- package/dist/libs/event-bus.js +15 -15
- package/dist/libs/extractAttachmentFilename.js +5 -6
- package/dist/libs/find-request.js +9 -10
- package/dist/libs/get-request-uid-by-path-method.js +12 -12
- package/dist/libs/getOpenApiDocumentDetails.js +7 -7
- package/dist/libs/importers/curl.js +3 -3
- package/dist/libs/normalize-headers.js +9 -10
- package/dist/libs/postman.js +15 -17
- package/dist/libs/send-request/build-request-security.js +9 -10
- package/dist/libs/send-request/create-fetch-body.js +11 -12
- package/dist/libs/send-request/create-fetch-query-params.js +13 -13
- package/dist/libs/send-request/create-request-operation.js +83 -84
- package/dist/libs/send-request/decode-buffer.d.ts.map +1 -1
- package/dist/libs/send-request/set-request-cookies.js +12 -12
- package/dist/libs/string-template.js +21 -21
- package/dist/libs/validate-parameters.js +5 -8
- package/dist/plugins/plugin-manager.js +11 -17
- package/dist/store/active-entities.js +90 -117
- package/dist/store/collections.js +41 -42
- package/dist/store/import-spec.js +25 -26
- package/dist/store/request-example.js +20 -24
- package/dist/store/requests.js +63 -81
- package/dist/store/router-params.js +7 -7
- package/dist/store/security-schemes.js +35 -36
- package/dist/store/store.js +2 -2
- package/dist/store/tags.js +20 -21
- package/dist/style.css +1 -1
- package/dist/views/Collection/Collection.vue2.js +21 -22
- package/dist/views/Collection/CollectionAuthentication.vue.js +1 -1
- package/dist/views/Collection/CollectionAuthentication.vue2.js +43 -47
- package/dist/views/Collection/CollectionEnvironment.vue.js +1 -1
- package/dist/views/Collection/CollectionEnvironment.vue2.js +196 -207
- package/dist/views/Collection/CollectionInfoForm.vue.js +1 -1
- package/dist/views/Collection/CollectionInfoForm.vue2.js +34 -41
- package/dist/views/Collection/CollectionNavigation.vue.js +116 -125
- package/dist/views/Collection/CollectionOverview.vue2.js +22 -25
- package/dist/views/Collection/CollectionServerForm.vue.js +39 -45
- package/dist/views/Collection/CollectionServers.vue2.js +88 -98
- package/dist/views/Collection/CollectionSettings.vue.js +1 -1
- package/dist/views/Collection/CollectionSettings.vue2.js +101 -108
- package/dist/views/Collection/components/EnvironmentForm.vue.js +1 -1
- package/dist/views/Collection/components/EnvironmentForm.vue2.js +141 -145
- package/dist/views/Collection/components/MarkdownInput.vue.js +1 -1
- package/dist/views/Collection/components/MarkdownInput.vue2.js +1 -2
- package/dist/views/Components/CodeSnippet/CodeSnippet.vue.js +15 -15
- package/dist/views/Components/CodeSnippet/helpers/convert-to-har-request.js +15 -16
- package/dist/views/Components/CodeSnippet/helpers/get-har-request.js +61 -64
- package/dist/views/Components/CodeSnippet/helpers/get-snippet.js +9 -10
- package/dist/views/Cookies/CookieModal.vue.js +1 -1
- package/dist/views/Cookies/Cookies.vue2.js +90 -93
- package/dist/views/Environment/Environment.vue2.js +267 -295
- package/dist/views/Environment/EnvironmentModal.vue.js +63 -70
- package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +38 -42
- package/dist/views/Request/Request.vue.js +1 -1
- package/dist/views/Request/Request.vue2.js +60 -67
- package/dist/views/Request/RequestRoot.vue.js +1 -1
- package/dist/views/Request/RequestRoot.vue2.js +78 -89
- package/dist/views/Request/RequestSection/RequestAuth/DeleteRequestAuthModal.vue.js +37 -44
- package/dist/views/Request/RequestSection/RequestAuth/OAuth2.vue.js +44 -45
- package/dist/views/Request/RequestSection/RequestAuth/OAuthScopesInput.vue.js +111 -127
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +120 -139
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthTab.vue.js +97 -97
- package/dist/views/Request/RequestSection/RequestBody.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestBody.vue2.js +287 -310
- package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +86 -94
- package/dist/views/Request/RequestSection/RequestParams.vue.js +37 -38
- package/dist/views/Request/RequestSection/RequestPathParams.vue.js +36 -38
- package/dist/views/Request/RequestSection/RequestSection.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestSection.vue2.js +28 -31
- package/dist/views/Request/RequestSection/RequestTable.vue.js +1 -1
- package/dist/views/Request/RequestSection/RequestTable.vue2.js +49 -52
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +1 -1
- package/dist/views/Request/RequestSection/helpers/filter-security-requirements.js +16 -16
- package/dist/views/Request/RequestSection/helpers/getting-started.js +7 -11
- package/dist/views/Request/RequestSection/helpers/update-scheme.js +7 -8
- package/dist/views/Request/RequestSidebar.vue.js +1 -1
- package/dist/views/Request/RequestSidebar.vue2.js +199 -211
- package/dist/views/Request/RequestSidebarItem.vue.js +2 -2
- package/dist/views/Request/RequestSidebarItem.vue2.js +332 -349
- package/dist/views/Request/RequestSidebarItemMenu.vue.js +1 -1
- package/dist/views/Request/RequestSidebarItemMenu.vue2.js +210 -240
- package/dist/views/Request/RequestSubpageHeader.vue.js +1 -1
- package/dist/views/Request/ResponseSection/RequestHeaders.vue.js +38 -41
- package/dist/views/Request/ResponseSection/ResponseBody.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseBody.vue2.js +58 -64
- package/dist/views/Request/ResponseSection/ResponseBodyDownload.vue.js +1 -2
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue2.js +20 -23
- package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue3.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +29 -30
- package/dist/views/Request/ResponseSection/ResponseHeaders.vue.js +38 -41
- package/dist/views/Request/ResponseSection/ResponseLoadingOverlay.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseMetaInformation.vue.js +28 -29
- package/dist/views/Request/ResponseSection/ResponseSection.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseSection.vue2.js +128 -140
- package/dist/views/Request/components/WorkspaceDropdown.vue.js +116 -124
- package/dist/views/Request/consts/mediaTypes.js +2 -3
- package/dist/views/Request/handle-drag.js +24 -28
- package/dist/views/Request/hooks/useOpenApiWatcher.js +26 -33
- package/dist/views/Request/libs/auth.js +37 -43
- package/dist/views/Request/libs/oauth2.js +30 -32
- package/dist/views/Request/libs/watch-mode.js +100 -103
- package/dist/views/Settings/SettingsGeneral.vue.js +206 -236
- package/package.json +22 -22
- package/dist/components/AddressBar/AddressBar.vue3.js +0 -4
- package/dist/components/AddressBar/AddressBarHistory.vue3.js +0 -4
- package/dist/components/CodeInput/CodeInput.vue3.js +0 -4
- package/dist/components/CodeInput/CodeInput.vue4.js +0 -4
- package/dist/components/CommandPalette/CommandPaletteImportCurl.vue3.js +0 -4
- package/dist/components/CommandPalette/TheCommandPalette.vue3.js +0 -4
- package/dist/components/DataTable/DataTableInput.vue3.js +0 -4
- package/dist/components/EmptyState.vue3.js +0 -4
- package/dist/components/Form/LabelInput.vue3.js +0 -4
- package/dist/components/HttpMethod/HttpMethod.vue3.js +0 -4
- package/dist/components/ImportCollection/ImportCollectionModal.vue2.js +0 -4
- package/dist/components/OpenApiClientButton.vue3.js +0 -4
- package/dist/components/ScalarAsciiArt.vue3.js +0 -4
- package/dist/components/SectionFilter.vue3.js +0 -4
- package/dist/components/Server/ServerDropdownItem.vue3.js +0 -4
- package/dist/components/SideNav/DownloadAppButton.vue3.js +0 -4
- package/dist/components/Sidebar/Actions/SidebarListElementForm.vue3.js +0 -4
- package/dist/components/Sidebar/Sidebar.vue3.js +0 -4
- package/dist/components/Sidebar/SidebarListElement.vue3.js +0 -4
- package/dist/components/Sidebar/SidebarListElement.vue4.js +0 -4
- package/dist/components/TopNav/TopNavItem.vue3.js +0 -4
- package/dist/layouts/App/ApiClientApp.vue2.js +0 -4
- package/dist/layouts/Modal/ApiClientModal.vue3.js +0 -4
- package/dist/layouts/Web/ApiClientWeb.vue2.js +0 -4
- package/dist/style.css.js +0 -4
- package/dist/views/Collection/CollectionAuthentication.vue3.js +0 -4
- package/dist/views/Collection/CollectionEnvironment.vue3.js +0 -4
- package/dist/views/Collection/CollectionInfoForm.vue3.js +0 -4
- package/dist/views/Collection/CollectionSettings.vue3.js +0 -4
- package/dist/views/Collection/components/EnvironmentForm.vue3.js +0 -4
- package/dist/views/Collection/components/MarkdownInput.vue3.js +0 -4
- package/dist/views/Cookies/CookieModal.vue3.js +0 -4
- package/dist/views/Request/Request.vue3.js +0 -4
- package/dist/views/Request/RequestRoot.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuthDataTable.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestBody.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestCodeExample.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestSection.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestTable.vue3.js +0 -4
- package/dist/views/Request/RequestSection/RequestTableTooltip.vue3.js +0 -4
- package/dist/views/Request/RequestSidebar.vue3.js +0 -4
- package/dist/views/Request/RequestSidebarItem.vue3.js +0 -4
- package/dist/views/Request/RequestSidebarItem.vue4.js +0 -4
- package/dist/views/Request/RequestSidebarItemMenu.vue3.js +0 -4
- package/dist/views/Request/RequestSubpageHeader.vue3.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBody.vue3.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBodyPreview.vue3.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBodyRaw.vue3.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseBodyVirtual.vue2.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue3.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseLoadingOverlay.vue3.js +0 -4
- package/dist/views/Request/ResponseSection/ResponseSection.vue3.js +0 -4
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ScalarButton as
|
|
3
|
-
import { Draggable as
|
|
4
|
-
import { shouldIgnoreEntity as
|
|
5
|
-
import { useRouter as
|
|
6
|
-
import { useLayout as
|
|
7
|
-
import { useSidebar as
|
|
8
|
-
import { useActiveEntities as
|
|
9
|
-
import { PathId as
|
|
10
|
-
import
|
|
11
|
-
import { getModifiers as
|
|
12
|
-
import { useWorkspace as
|
|
13
|
-
const
|
|
1
|
+
import { defineComponent as re, useCssVars as ue, computed as v, ref as de, resolveComponent as pe, createElementBlock as C, createCommentVNode as p, openBlock as u, normalizeClass as g, unref as n, createVNode as f, withCtx as m, createBlock as c, withModifiers as h, createElementVNode as s, toDisplayString as j, createTextVNode as B, renderSlot as L, Fragment as ce, renderList as fe, nextTick as me } from "vue";
|
|
2
|
+
import { ScalarButton as k, ScalarIcon as b, ScalarSidebarGroupToggle as G, ScalarTooltip as K } from "@scalar/components";
|
|
3
|
+
import { Draggable as ve } from "@scalar/draggable";
|
|
4
|
+
import { shouldIgnoreEntity as J } from "@scalar/oas-utils/helpers";
|
|
5
|
+
import { useRouter as ge, RouterLink as Q } from "vue-router";
|
|
6
|
+
import { useLayout as be } from "../../hooks/useLayout.js";
|
|
7
|
+
import { useSidebar as ye } from "../../hooks/useSidebar.js";
|
|
8
|
+
import { useActiveEntities as he } from "../../store/active-entities.js";
|
|
9
|
+
import { PathId as R } from "../../routes.js";
|
|
10
|
+
import xe from "../../components/HttpMethod/HttpMethod.vue.js";
|
|
11
|
+
import { getModifiers as ke } from "../../libs/hot-keys.js";
|
|
12
|
+
import { useWorkspace as we } from "../../store/store.js";
|
|
13
|
+
const qe = { class: "line-clamp-1 w-full pl-2 break-all" }, Ue = { class: "flex flex-row items-center gap-1" }, De = { class: "relative" }, Ie = { class: "flex items-start" }, Ce = { class: "flex flex-1 flex-row justify-between font-medium" }, Re = { class: "line-clamp-1 w-full text-left break-all" }, Te = { class: "relative flex h-fit justify-end" }, Me = {
|
|
14
14
|
class: "flex items-center justify-center",
|
|
15
15
|
type: "button"
|
|
16
|
-
},
|
|
16
|
+
}, Ee = ["aria-expanded"], $e = { class: "flex h-5 max-w-[14px] items-center justify-center" }, ze = { class: "flex flex-1 flex-row justify-between" }, Se = { class: "line-clamp-1 w-full text-left font-medium break-all" }, je = { class: "relative flex h-fit justify-end" }, Be = {
|
|
17
17
|
class: "flex items-center justify-center",
|
|
18
18
|
type: "button"
|
|
19
|
-
},
|
|
19
|
+
}, We = { key: 3 }, W = "hover:bg-sidebar-b-active indent-padding-left", Qe = /* @__PURE__ */ re({
|
|
20
20
|
__name: "RequestSidebarItem",
|
|
21
21
|
props: {
|
|
22
22
|
isDraggable: { type: Boolean, default: !1 },
|
|
@@ -26,60 +26,59 @@ const Te = { class: "line-clamp-1 w-full pl-2 break-all" }, Me = { class: "flex
|
|
|
26
26
|
menuItem: {}
|
|
27
27
|
},
|
|
28
28
|
emits: ["onDragEnd", "newTab", "openMenu"],
|
|
29
|
-
setup(
|
|
30
|
-
|
|
31
|
-
eae2c57a:
|
|
32
|
-
"7c91ad9b":
|
|
29
|
+
setup(o, { emit: X }) {
|
|
30
|
+
ue((t) => ({
|
|
31
|
+
eae2c57a: te.value,
|
|
32
|
+
"7c91ad9b": ie.value
|
|
33
33
|
}));
|
|
34
|
-
const
|
|
35
|
-
collections:
|
|
36
|
-
tags:
|
|
37
|
-
requests:
|
|
38
|
-
requestExamples:
|
|
39
|
-
collectionMutators:
|
|
40
|
-
tagMutators:
|
|
41
|
-
requestMutators:
|
|
42
|
-
requestExampleMutators:
|
|
43
|
-
events:
|
|
44
|
-
} =
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
entity: e,
|
|
34
|
+
const Z = X, { activeCollection: _, activeRequest: A, activeRouterParams: ee, activeWorkspace: x } = he(), {
|
|
35
|
+
collections: q,
|
|
36
|
+
tags: U,
|
|
37
|
+
requests: T,
|
|
38
|
+
requestExamples: M,
|
|
39
|
+
collectionMutators: E,
|
|
40
|
+
tagMutators: N,
|
|
41
|
+
requestMutators: $,
|
|
42
|
+
requestExampleMutators: O,
|
|
43
|
+
events: P
|
|
44
|
+
} = we(), y = ge(), { collapsedSidebarFolders: w, toggleSidebarFolder: V } = ye(), { layout: d } = be(), i = v(() => {
|
|
45
|
+
const t = q[o.uid], e = U[o.uid], r = T[o.uid], l = M[o.uid];
|
|
46
|
+
return t ? {
|
|
47
|
+
title: t.info?.title || "Untitled Collection",
|
|
48
|
+
entity: t,
|
|
50
49
|
resourceTitle: "Collection",
|
|
51
|
-
children:
|
|
52
|
-
icon:
|
|
53
|
-
documentUrl:
|
|
54
|
-
watchMode:
|
|
55
|
-
to:
|
|
50
|
+
children: t.children,
|
|
51
|
+
icon: t["x-scalar-icon"],
|
|
52
|
+
documentUrl: t.documentUrl,
|
|
53
|
+
watchMode: t.watchMode,
|
|
54
|
+
to: t.uid && t?.info?.title !== "Drafts" ? {
|
|
56
55
|
name: "collection",
|
|
57
56
|
params: {
|
|
58
|
-
[
|
|
59
|
-
[
|
|
57
|
+
[R.Workspace]: x.value?.uid,
|
|
58
|
+
[R.Collection]: t.uid
|
|
60
59
|
}
|
|
61
60
|
} : void 0,
|
|
62
61
|
warning: "This cannot be undone. You're about to delete the collection and all folders and requests inside it.",
|
|
63
|
-
edit: (
|
|
64
|
-
|
|
62
|
+
edit: (a, I) => {
|
|
63
|
+
E.edit(t.uid, "info.title", a), I && E.edit(t.uid, "x-scalar-icon", I);
|
|
65
64
|
},
|
|
66
65
|
delete: () => {
|
|
67
|
-
|
|
66
|
+
x.value && E.delete(t, x.value);
|
|
68
67
|
}
|
|
69
|
-
} :
|
|
70
|
-
title:
|
|
71
|
-
entity:
|
|
68
|
+
} : e ? {
|
|
69
|
+
title: e.name,
|
|
70
|
+
entity: e,
|
|
72
71
|
resourceTitle: "Tag",
|
|
73
|
-
children:
|
|
72
|
+
children: e.children,
|
|
74
73
|
warning: "This cannot be undone. You're about to delete the tag and all requests inside it",
|
|
75
|
-
edit: (
|
|
76
|
-
delete: () =>
|
|
74
|
+
edit: (a) => N.edit(e.uid, "name", a),
|
|
75
|
+
delete: () => o.parentUids[0] && N.delete(e, o.parentUids[0])
|
|
77
76
|
} : r ? {
|
|
78
77
|
title: r.summary ?? r.path,
|
|
79
78
|
to: {
|
|
80
79
|
name: "request",
|
|
81
80
|
params: {
|
|
82
|
-
workspace:
|
|
81
|
+
workspace: x.value?.uid,
|
|
83
82
|
request: r.uid
|
|
84
83
|
}
|
|
85
84
|
},
|
|
@@ -88,25 +87,25 @@ const Te = { class: "line-clamp-1 w-full pl-2 break-all" }, Me = { class: "flex
|
|
|
88
87
|
resourceTitle: "Request",
|
|
89
88
|
warning: "This cannot be undone. You're about to delete the request.",
|
|
90
89
|
children: r.examples.slice(1),
|
|
91
|
-
edit: (
|
|
92
|
-
delete: () =>
|
|
93
|
-
} :
|
|
94
|
-
title:
|
|
90
|
+
edit: (a) => $.edit(r.uid, "summary", a),
|
|
91
|
+
delete: () => o.parentUids[0] && $.delete(r, o.parentUids[0])
|
|
92
|
+
} : l?.requestUid ? {
|
|
93
|
+
title: l.name,
|
|
95
94
|
to: {
|
|
96
95
|
name: "request.examples",
|
|
97
96
|
params: {
|
|
98
|
-
workspace:
|
|
99
|
-
request:
|
|
100
|
-
examples:
|
|
97
|
+
workspace: x.value?.uid,
|
|
98
|
+
request: l.requestUid,
|
|
99
|
+
examples: l.uid
|
|
101
100
|
}
|
|
102
101
|
},
|
|
103
|
-
method:
|
|
104
|
-
entity:
|
|
102
|
+
method: T[l.requestUid]?.method,
|
|
103
|
+
entity: l,
|
|
105
104
|
resourceTitle: "Example",
|
|
106
105
|
warning: "This cannot be undone. You're about to delete the example from the request.",
|
|
107
106
|
children: [],
|
|
108
|
-
edit: (
|
|
109
|
-
delete: () =>
|
|
107
|
+
edit: (a) => O.edit(l.uid, "name", a),
|
|
108
|
+
delete: () => O.delete(l)
|
|
110
109
|
} : {
|
|
111
110
|
title: "Unknown",
|
|
112
111
|
entity: {
|
|
@@ -118,313 +117,210 @@ const Te = { class: "line-clamp-1 w-full pl-2 break-all" }, Me = { class: "flex
|
|
|
118
117
|
edit: () => null,
|
|
119
118
|
delete: () => null
|
|
120
119
|
};
|
|
121
|
-
}),
|
|
120
|
+
}), D = v(
|
|
122
121
|
() => i.value.entity.type === "collection" && i.value.title === "Drafts"
|
|
123
|
-
),
|
|
124
|
-
() =>
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
()
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
}
|
|
133
|
-
),
|
|
134
|
-
|
|
135
|
-
if (!B.value)
|
|
136
|
-
return { ceiling: e, floor: t };
|
|
137
|
-
const { draggingItem: r } = B.value;
|
|
138
|
-
return !C[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 };
|
|
139
|
-
}), pe = (e, t) => !(p === "modal" || E[t.id] || C[e.id]), fe = (e, t) => {
|
|
140
|
-
e && (Re(["default"]).some((o) => e[o]) ? oe("newTab", t.title || "", t.entity.uid) : t.to && x.push(t.to), xe(() => Y.focusAddressBar.emit()));
|
|
122
|
+
), te = v(() => o.parentUids.length ? d === "modal" ? `${(o.parentUids.length - 1) * 12}px` : `${o.parentUids.length * 12}px` : "12px"), ie = v(() => o.parentUids.length ? d === "modal" ? `${(o.parentUids.length - 1) * 12}px` : `${o.parentUids.length * 12}px` : "0px"), ne = v(
|
|
123
|
+
() => w[o.uid] || A.value?.uid === o.uid && i.value.entity.examples.length > 1
|
|
124
|
+
), le = v(
|
|
125
|
+
() => typeof y.currentRoute.value.name == "string" && y.currentRoute.value.name.startsWith("request") && ee.value[R.Request] === "default" && A.value?.uid === o.uid
|
|
126
|
+
), z = de(null), F = v(() => {
|
|
127
|
+
let t = 0.5, e = 0.5;
|
|
128
|
+
if (!z.value)
|
|
129
|
+
return { ceiling: t, floor: e };
|
|
130
|
+
const { draggingItem: r } = z.value;
|
|
131
|
+
return !q[r?.id] && i.value.entity.type === "collection" ? (t = 1, e = 0) : i.value.entity.type === "tag" && (t = 0.8, e = 0.2), { ceiling: t, floor: e };
|
|
132
|
+
}), oe = (t, e) => !(d === "modal" || M[e.id] || q[t.id]), se = (t, e) => {
|
|
133
|
+
t && (ke(["default"]).some((a) => t[a]) ? Z("newTab", e.title || "", e.entity.uid) : e.to && y.push(e.to), me(() => P.focusAddressBar.emit()));
|
|
141
134
|
};
|
|
142
|
-
function
|
|
143
|
-
|
|
144
|
-
const t = l.parentUids[0] ? ((o = C[l.parentUids[0]]) == null ? void 0 : o.uid) || "" : e, r = l.parentUids[0] && ((u = R[e]) != null && u.name) ? { tags: [R[e].name] } : {}, a = j.add(
|
|
135
|
+
function S(t) {
|
|
136
|
+
const e = o.parentUids[0] ? q[o.parentUids[0]]?.uid || "" : t, r = o.parentUids[0] && U[t]?.name ? { tags: [U[t].name] } : {}, l = $.add(
|
|
145
137
|
r,
|
|
146
|
-
|
|
138
|
+
e
|
|
147
139
|
);
|
|
148
|
-
|
|
140
|
+
l && (y.push({
|
|
149
141
|
name: "request",
|
|
150
142
|
params: {
|
|
151
|
-
workspace:
|
|
152
|
-
request:
|
|
143
|
+
workspace: x.value?.uid,
|
|
144
|
+
request: l.uid
|
|
153
145
|
}
|
|
154
|
-
}),
|
|
146
|
+
}), P.hotKeys.emit({
|
|
155
147
|
focusAddressBar: new KeyboardEvent("keydown", { key: "l" })
|
|
156
148
|
}));
|
|
157
149
|
}
|
|
158
|
-
const
|
|
159
|
-
const { uid:
|
|
160
|
-
return
|
|
161
|
-
}),
|
|
162
|
-
const
|
|
163
|
-
if (
|
|
164
|
-
return !
|
|
165
|
-
const
|
|
166
|
-
return
|
|
150
|
+
const Y = v(() => {
|
|
151
|
+
const { uid: t, watchModeStatus: e } = _.value || {};
|
|
152
|
+
return t !== i.value.entity.uid ? "text-c-3" : e === "WATCHING" ? "text-c-1" : e === "ERROR" ? "text-red" : "text-c-3";
|
|
153
|
+
}), H = v(() => i.value.title === "Drafts" && d !== "modal" && i.value.children.length > 0), ae = v(() => {
|
|
154
|
+
const t = T[o.uid];
|
|
155
|
+
if (t)
|
|
156
|
+
return !J(t);
|
|
157
|
+
const e = U[o.uid];
|
|
158
|
+
return e ? !J(e) : !0;
|
|
167
159
|
});
|
|
168
|
-
return (
|
|
169
|
-
const r =
|
|
170
|
-
return
|
|
160
|
+
return (t, e) => {
|
|
161
|
+
const r = pe("RequestSidebarItem", !0);
|
|
162
|
+
return ae.value ? (u(), C("li", {
|
|
171
163
|
key: 0,
|
|
172
|
-
class:
|
|
173
|
-
n(
|
|
164
|
+
class: g(["relative flex flex-row", [
|
|
165
|
+
n(d) === "modal" && t.parentUids.length > 1 || n(d) !== "modal" && t.parentUids.length ? "before:bg-border indent-border-line-offset mb-[.5px] before:pointer-events-none before:absolute before:top-0 before:left-[calc(.75rem_+_.5px)] before:z-1 before:h-[calc(100%_+_.5px)] before:w-[.5px] last:mb-0 last:before:h-full" : ""
|
|
174
166
|
]])
|
|
175
167
|
}, [
|
|
176
|
-
|
|
168
|
+
f(n(ve), {
|
|
177
169
|
id: i.value.entity.uid,
|
|
178
170
|
ref_key: "draggableRef",
|
|
179
|
-
ref:
|
|
180
|
-
ceiling:
|
|
171
|
+
ref: z,
|
|
172
|
+
ceiling: F.value.ceiling,
|
|
181
173
|
class: "gap-1/2 flex flex-1 flex-col text-base",
|
|
182
|
-
floor:
|
|
183
|
-
isDraggable:
|
|
184
|
-
isDroppable:
|
|
185
|
-
parentIds:
|
|
186
|
-
onOnDragEnd:
|
|
174
|
+
floor: F.value.floor,
|
|
175
|
+
isDraggable: t.isDraggable,
|
|
176
|
+
isDroppable: t.isDroppable,
|
|
177
|
+
parentIds: t.parentUids,
|
|
178
|
+
onOnDragEnd: e[12] || (e[12] = (...l) => t.$emit("onDragEnd", ...l))
|
|
187
179
|
}, {
|
|
188
|
-
default:
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
m(n(h), {
|
|
232
|
-
icon: "Ellipses",
|
|
233
|
-
size: "md"
|
|
234
|
-
})
|
|
235
|
-
]),
|
|
236
|
-
_: 1
|
|
237
|
-
}, 8, ["class"])) : f("", !0)
|
|
180
|
+
default: m(() => [
|
|
181
|
+
(i.value.entity.type === "request" || i.value.entity.type === "requestExample") && i.value.to ? (u(), c(n(Q), {
|
|
182
|
+
key: 0,
|
|
183
|
+
class: "group no-underline",
|
|
184
|
+
to: i.value.to,
|
|
185
|
+
onClick: e[1] || (e[1] = h(
|
|
186
|
+
(l) => se(l, i.value),
|
|
187
|
+
["prevent"]
|
|
188
|
+
))
|
|
189
|
+
}, {
|
|
190
|
+
default: m(({ isExactActive: l }) => [
|
|
191
|
+
s("div", {
|
|
192
|
+
class: g(["relative flex min-h-8 w-full cursor-pointer flex-row items-start justify-between gap-0.5 rounded py-1.5 pr-2", [
|
|
193
|
+
W,
|
|
194
|
+
l || le.value ? "bg-sidebar-b-active text-sidebar-c-active font-medium transition-none" : "text-sidebar-c-2"
|
|
195
|
+
]])
|
|
196
|
+
}, [
|
|
197
|
+
s("span", qe, j(i.value.title || "Untitled"), 1),
|
|
198
|
+
s("div", Ue, [
|
|
199
|
+
s("div", De, [
|
|
200
|
+
n(d) !== "modal" ? (u(), c(n(k), {
|
|
201
|
+
key: 0,
|
|
202
|
+
class: g(["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", {
|
|
203
|
+
flex: t.menuItem?.item?.entity.uid === i.value.entity.uid && t.menuItem.open
|
|
204
|
+
}]),
|
|
205
|
+
size: "sm",
|
|
206
|
+
type: "button",
|
|
207
|
+
variant: "ghost",
|
|
208
|
+
onClick: e[0] || (e[0] = h(
|
|
209
|
+
(a) => t.$emit("openMenu", {
|
|
210
|
+
item: i.value,
|
|
211
|
+
parentUids: t.parentUids,
|
|
212
|
+
targetRef: a.currentTarget,
|
|
213
|
+
open: !t.menuItem.open
|
|
214
|
+
}),
|
|
215
|
+
["stop", "prevent"]
|
|
216
|
+
))
|
|
217
|
+
}, {
|
|
218
|
+
default: m(() => [
|
|
219
|
+
f(n(b), {
|
|
220
|
+
icon: "Ellipses",
|
|
221
|
+
size: "md"
|
|
222
|
+
})
|
|
238
223
|
]),
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
t[14] || (t[14] = s("span", { class: "sr-only" }, "HTTP Method:", -1)),
|
|
242
|
-
i.value.method ? (d(), c(n(Ce), {
|
|
243
|
-
key: 0,
|
|
244
|
-
class: "font-bold",
|
|
245
|
-
method: i.value.method
|
|
246
|
-
}, null, 8, ["method"])) : f("", !0)
|
|
247
|
-
])
|
|
248
|
-
])
|
|
249
|
-
], 2)
|
|
250
|
-
];
|
|
251
|
-
}),
|
|
252
|
-
_: 1
|
|
253
|
-
}, 8, ["to"])) : (n(p) !== "modal" || e.parentUids.length) && i.value.entity.type === "collection" && i.value.to ? (d(), c(n(ie), {
|
|
254
|
-
key: 1,
|
|
255
|
-
"aria-expanded": !!n(D)[i.value.entity.uid],
|
|
256
|
-
class: y(["hover:bg-b-2 group relative flex w-full flex-row justify-start gap-1.5 rounded p-1.5 no-underline focus-visible:z-10", [
|
|
257
|
-
O,
|
|
258
|
-
{
|
|
259
|
-
"bg-sidebar-b-active text-sidebar-c-active transition-none": typeof n(x).currentRoute.value.name == "string" && n(x).currentRoute.value.name.startsWith("collection") && n(x).currentRoute.value.params[n($).Collection] === i.value.entity.uid,
|
|
260
|
-
"text-c-2": i.value.title === "Untitled Collection"
|
|
261
|
-
}
|
|
262
|
-
]]),
|
|
263
|
-
to: i.value.to
|
|
264
|
-
}, {
|
|
265
|
-
default: v(() => {
|
|
266
|
-
var o;
|
|
267
|
-
return [
|
|
268
|
-
s("span", {
|
|
269
|
-
class: "flex h-5 max-w-[14px] cursor-pointer items-center justify-center",
|
|
270
|
-
onClick: t[2] || (t[2] = w((u) => n(H)(i.value.entity.uid), ["stop", "prevent"]))
|
|
271
|
-
}, [
|
|
272
|
-
Z(e.$slots, "leftIcon", {}, () => [
|
|
273
|
-
m(n(_), {
|
|
274
|
-
class: "text-c-3 shrink-0",
|
|
275
|
-
open: !!n(D)[i.value.entity.uid]
|
|
276
|
-
}, null, 8, ["open"])
|
|
277
|
-
], !0),
|
|
278
|
-
t[15] || (t[15] = N(" "))
|
|
224
|
+
_: 1
|
|
225
|
+
}, 8, ["class"])) : p("", !0)
|
|
279
226
|
]),
|
|
280
|
-
s("
|
|
281
|
-
|
|
282
|
-
s("
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
}, [
|
|
289
|
-
n(p) !== "modal" && !I.value || I.value && K.value ? (d(), c(n(q), {
|
|
290
|
-
key: 0,
|
|
291
|
-
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",
|
|
292
|
-
size: "sm",
|
|
293
|
-
variant: "ghost",
|
|
294
|
-
onClick: t[3] || (t[3] = w(
|
|
295
|
-
(u) => e.$emit("openMenu", {
|
|
296
|
-
item: i.value,
|
|
297
|
-
parentUids: e.parentUids,
|
|
298
|
-
targetRef: u.currentTarget.parentNode,
|
|
299
|
-
open: !0
|
|
300
|
-
}),
|
|
301
|
-
["stop", "prevent"]
|
|
302
|
-
))
|
|
303
|
-
}, {
|
|
304
|
-
default: v(() => [
|
|
305
|
-
m(n(h), {
|
|
306
|
-
icon: "Ellipses",
|
|
307
|
-
size: "md"
|
|
308
|
-
})
|
|
309
|
-
]),
|
|
310
|
-
_: 1
|
|
311
|
-
})) : f("", !0),
|
|
312
|
-
n(p) !== "modal" ? (d(), c(n(q), {
|
|
313
|
-
key: 1,
|
|
314
|
-
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",
|
|
315
|
-
size: "sm",
|
|
316
|
-
variant: "ghost",
|
|
317
|
-
onClick: t[4] || (t[4] = w((u) => W(i.value.entity.uid), ["stop", "prevent"]))
|
|
318
|
-
}, {
|
|
319
|
-
default: v(() => [
|
|
320
|
-
m(n(h), {
|
|
321
|
-
icon: "Add",
|
|
322
|
-
size: "md",
|
|
323
|
-
thickness: "2"
|
|
324
|
-
})
|
|
325
|
-
]),
|
|
326
|
-
_: 1
|
|
327
|
-
})) : f("", !0)
|
|
328
|
-
], 2),
|
|
329
|
-
i.value.watchMode ? (d(), c(n(ee), {
|
|
330
|
-
key: 0,
|
|
331
|
-
placement: "right",
|
|
332
|
-
offset: 12,
|
|
333
|
-
content: `Watching: ${i.value.documentUrl}`
|
|
334
|
-
}, {
|
|
335
|
-
default: v(() => [
|
|
336
|
-
s("button", Be, [
|
|
337
|
-
m(n(h), {
|
|
338
|
-
class: y(["ml-0.5 text-sm", G.value]),
|
|
339
|
-
icon: "Watch",
|
|
340
|
-
size: "md",
|
|
341
|
-
thickness: "2"
|
|
342
|
-
}, null, 8, ["class"])
|
|
343
|
-
])
|
|
344
|
-
]),
|
|
345
|
-
_: 1
|
|
346
|
-
}, 8, ["content"])) : f("", !0),
|
|
347
|
-
t[16] || (t[16] = s("span", null, " ", -1))
|
|
348
|
-
])
|
|
227
|
+
s("span", Ie, [
|
|
228
|
+
e[13] || (e[13] = B(" ")),
|
|
229
|
+
e[14] || (e[14] = s("span", { class: "sr-only" }, "HTTP Method:", -1)),
|
|
230
|
+
i.value.method ? (u(), c(n(xe), {
|
|
231
|
+
key: 0,
|
|
232
|
+
class: "font-bold",
|
|
233
|
+
method: i.value.method
|
|
234
|
+
}, null, 8, ["method"])) : p("", !0)
|
|
349
235
|
])
|
|
350
|
-
]
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
236
|
+
])
|
|
237
|
+
], 2)
|
|
238
|
+
]),
|
|
239
|
+
_: 1
|
|
240
|
+
}, 8, ["to"])) : (n(d) !== "modal" || t.parentUids.length) && i.value.entity.type === "collection" && i.value.to ? (u(), c(n(Q), {
|
|
241
|
+
key: 1,
|
|
242
|
+
"aria-expanded": !!n(w)[i.value.entity.uid],
|
|
243
|
+
class: g(["hover:bg-b-2 group relative flex w-full flex-row justify-start gap-1.5 rounded p-1.5 no-underline focus-visible:z-10", [
|
|
244
|
+
W,
|
|
245
|
+
{
|
|
246
|
+
"bg-sidebar-b-active text-sidebar-c-active transition-none": typeof n(y).currentRoute.value.name == "string" && n(y).currentRoute.value.name.startsWith("collection") && n(y).currentRoute.value.params[n(R).Collection] === i.value.entity.uid,
|
|
247
|
+
"text-c-2": i.value.title === "Untitled Collection"
|
|
248
|
+
}
|
|
249
|
+
]]),
|
|
250
|
+
to: i.value.to
|
|
251
|
+
}, {
|
|
252
|
+
default: m(() => [
|
|
253
|
+
s("span", {
|
|
254
|
+
class: "flex h-5 max-w-[14px] cursor-pointer items-center justify-center",
|
|
255
|
+
onClick: e[2] || (e[2] = h((l) => n(V)(i.value.entity.uid), ["stop", "prevent"]))
|
|
256
|
+
}, [
|
|
257
|
+
L(t.$slots, "leftIcon", {}, () => [
|
|
258
|
+
f(n(G), {
|
|
259
|
+
class: "text-c-3 shrink-0",
|
|
260
|
+
open: !!n(w)[i.value.entity.uid]
|
|
365
261
|
}, null, 8, ["open"])
|
|
366
262
|
], !0),
|
|
367
|
-
|
|
263
|
+
e[15] || (e[15] = B(" "))
|
|
368
264
|
]),
|
|
369
|
-
s("div",
|
|
370
|
-
s("span",
|
|
371
|
-
s("div",
|
|
265
|
+
s("div", Ce, [
|
|
266
|
+
s("span", Re, j(i.value.title), 1),
|
|
267
|
+
s("div", Te, [
|
|
372
268
|
s("div", {
|
|
373
|
-
class:
|
|
374
|
-
flex:
|
|
375
|
-
hidden: !
|
|
269
|
+
class: g(["items-center gap-px opacity-0 group-hover:flex group-hover:opacity-100 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
|
|
270
|
+
flex: t.menuItem.open,
|
|
271
|
+
hidden: !t.menuItem.open || t.menuItem.item?.entity.uid !== i.value.entity.uid
|
|
376
272
|
}])
|
|
377
273
|
}, [
|
|
378
|
-
n(
|
|
274
|
+
n(d) !== "modal" && !D.value || D.value && H.value ? (u(), c(n(k), {
|
|
379
275
|
key: 0,
|
|
380
276
|
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",
|
|
381
277
|
size: "sm",
|
|
382
278
|
variant: "ghost",
|
|
383
|
-
onClick:
|
|
384
|
-
(
|
|
279
|
+
onClick: e[3] || (e[3] = h(
|
|
280
|
+
(l) => t.$emit("openMenu", {
|
|
385
281
|
item: i.value,
|
|
386
|
-
parentUids:
|
|
387
|
-
targetRef:
|
|
282
|
+
parentUids: t.parentUids,
|
|
283
|
+
targetRef: l.currentTarget.parentNode,
|
|
388
284
|
open: !0
|
|
389
285
|
}),
|
|
390
286
|
["stop", "prevent"]
|
|
391
287
|
))
|
|
392
288
|
}, {
|
|
393
|
-
default:
|
|
394
|
-
|
|
289
|
+
default: m(() => [
|
|
290
|
+
f(n(b), {
|
|
395
291
|
icon: "Ellipses",
|
|
396
292
|
size: "md"
|
|
397
293
|
})
|
|
398
294
|
]),
|
|
399
295
|
_: 1
|
|
400
|
-
})) :
|
|
401
|
-
n(
|
|
296
|
+
})) : p("", !0),
|
|
297
|
+
n(d) !== "modal" ? (u(), c(n(k), {
|
|
402
298
|
key: 1,
|
|
403
299
|
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",
|
|
404
300
|
size: "sm",
|
|
405
301
|
variant: "ghost",
|
|
406
|
-
onClick:
|
|
302
|
+
onClick: e[4] || (e[4] = h((l) => S(i.value.entity.uid), ["stop", "prevent"]))
|
|
407
303
|
}, {
|
|
408
|
-
default:
|
|
409
|
-
|
|
304
|
+
default: m(() => [
|
|
305
|
+
f(n(b), {
|
|
410
306
|
icon: "Add",
|
|
411
307
|
size: "md",
|
|
412
308
|
thickness: "2"
|
|
413
309
|
})
|
|
414
310
|
]),
|
|
415
311
|
_: 1
|
|
416
|
-
})) :
|
|
312
|
+
})) : p("", !0)
|
|
417
313
|
], 2),
|
|
418
|
-
i.value.watchMode ? (
|
|
314
|
+
i.value.watchMode ? (u(), c(n(K), {
|
|
419
315
|
key: 0,
|
|
420
|
-
content: "Watching: {{ item.documentUrl }}",
|
|
421
316
|
placement: "right",
|
|
422
|
-
offset: 12
|
|
317
|
+
offset: 12,
|
|
318
|
+
content: `Watching: ${i.value.documentUrl}`
|
|
423
319
|
}, {
|
|
424
|
-
default:
|
|
425
|
-
s("button",
|
|
426
|
-
|
|
427
|
-
class:
|
|
320
|
+
default: m(() => [
|
|
321
|
+
s("button", Me, [
|
|
322
|
+
f(n(b), {
|
|
323
|
+
class: g(["ml-0.5 text-sm", Y.value]),
|
|
428
324
|
icon: "Watch",
|
|
429
325
|
size: "md",
|
|
430
326
|
thickness: "2"
|
|
@@ -432,48 +328,135 @@ const Te = { class: "line-clamp-1 w-full pl-2 break-all" }, Me = { class: "flex
|
|
|
432
328
|
])
|
|
433
329
|
]),
|
|
434
330
|
_: 1
|
|
435
|
-
})) :
|
|
436
|
-
|
|
331
|
+
}, 8, ["content"])) : p("", !0),
|
|
332
|
+
e[16] || (e[16] = s("span", null, " ", -1))
|
|
437
333
|
])
|
|
438
334
|
])
|
|
439
|
-
]
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
335
|
+
]),
|
|
336
|
+
_: 3
|
|
337
|
+
}, 8, ["aria-expanded", "class", "to"])) : n(d) !== "modal" || t.parentUids.length ? (u(), C("button", {
|
|
338
|
+
key: 2,
|
|
339
|
+
"aria-expanded": !!n(w)[i.value.entity.uid],
|
|
340
|
+
class: g(["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]]),
|
|
341
|
+
type: "button",
|
|
342
|
+
onClick: e[7] || (e[7] = (l) => n(V)(i.value.entity.uid))
|
|
343
|
+
}, [
|
|
344
|
+
s("span", $e, [
|
|
345
|
+
L(t.$slots, "leftIcon", {}, () => [
|
|
346
|
+
f(n(G), {
|
|
347
|
+
class: "text-c-3 hover:text-c-1 shrink-0",
|
|
348
|
+
open: !!n(w)[i.value.entity.uid]
|
|
349
|
+
}, null, 8, ["open"])
|
|
350
|
+
], !0),
|
|
351
|
+
e[17] || (e[17] = B(" "))
|
|
352
|
+
]),
|
|
353
|
+
s("div", ze, [
|
|
354
|
+
s("span", Se, j(i.value.title), 1),
|
|
355
|
+
s("div", je, [
|
|
356
|
+
s("div", {
|
|
357
|
+
class: g(["items-center gap-px opacity-0 group-hover:flex group-hover:opacity-100 group-focus-visible:opacity-100 group-has-[:focus-visible]:opacity-100", {
|
|
358
|
+
flex: t.menuItem.open,
|
|
359
|
+
hidden: !t.menuItem.open || t.menuItem.item?.entity.uid !== i.value.entity.uid
|
|
360
|
+
}])
|
|
361
|
+
}, [
|
|
362
|
+
n(d) !== "modal" && !D.value || D.value && H.value ? (u(), c(n(k), {
|
|
363
|
+
key: 0,
|
|
364
|
+
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",
|
|
365
|
+
size: "sm",
|
|
366
|
+
variant: "ghost",
|
|
367
|
+
onClick: e[5] || (e[5] = h(
|
|
368
|
+
(l) => t.$emit("openMenu", {
|
|
369
|
+
item: i.value,
|
|
370
|
+
parentUids: t.parentUids,
|
|
371
|
+
targetRef: l.currentTarget.parentNode,
|
|
372
|
+
open: !0
|
|
373
|
+
}),
|
|
374
|
+
["stop", "prevent"]
|
|
375
|
+
))
|
|
376
|
+
}, {
|
|
377
|
+
default: m(() => [
|
|
378
|
+
f(n(b), {
|
|
379
|
+
icon: "Ellipses",
|
|
380
|
+
size: "md"
|
|
381
|
+
})
|
|
382
|
+
]),
|
|
383
|
+
_: 1
|
|
384
|
+
})) : p("", !0),
|
|
385
|
+
n(d) !== "modal" ? (u(), c(n(k), {
|
|
386
|
+
key: 1,
|
|
387
|
+
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",
|
|
388
|
+
size: "sm",
|
|
389
|
+
variant: "ghost",
|
|
390
|
+
onClick: e[6] || (e[6] = h((l) => S(i.value.entity.uid), ["stop", "prevent"]))
|
|
391
|
+
}, {
|
|
392
|
+
default: m(() => [
|
|
393
|
+
f(n(b), {
|
|
394
|
+
icon: "Add",
|
|
395
|
+
size: "md",
|
|
396
|
+
thickness: "2"
|
|
397
|
+
})
|
|
398
|
+
]),
|
|
399
|
+
_: 1
|
|
400
|
+
})) : p("", !0)
|
|
401
|
+
], 2),
|
|
402
|
+
i.value.watchMode ? (u(), c(n(K), {
|
|
403
|
+
key: 0,
|
|
404
|
+
content: "Watching: {{ item.documentUrl }}",
|
|
405
|
+
placement: "right",
|
|
406
|
+
offset: 12
|
|
407
|
+
}, {
|
|
408
|
+
default: m(() => [
|
|
409
|
+
s("button", Be, [
|
|
410
|
+
f(n(b), {
|
|
411
|
+
class: g(["ml-0.5 text-sm", Y.value]),
|
|
412
|
+
icon: "Watch",
|
|
413
|
+
size: "md",
|
|
414
|
+
thickness: "2"
|
|
415
|
+
}, null, 8, ["class"])
|
|
416
|
+
])
|
|
417
|
+
]),
|
|
418
|
+
_: 1
|
|
419
|
+
})) : p("", !0),
|
|
420
|
+
e[18] || (e[18] = s("span", null, " ", -1))
|
|
421
|
+
])
|
|
422
|
+
])
|
|
423
|
+
], 10, Ee)) : p("", !0),
|
|
424
|
+
ne.value ? (u(), C("ul", We, [
|
|
425
|
+
(u(!0), C(ce, null, fe(i.value.children, (l) => (u(), c(r, {
|
|
426
|
+
key: l,
|
|
427
|
+
isDraggable: !n(M)[l],
|
|
428
|
+
isDroppable: oe,
|
|
429
|
+
menuItem: t.menuItem,
|
|
430
|
+
parentUids: [...t.parentUids, t.uid],
|
|
431
|
+
uid: l,
|
|
432
|
+
onNewTab: e[8] || (e[8] = (a, I) => t.$emit("newTab", a, I)),
|
|
433
|
+
onOnDragEnd: e[9] || (e[9] = (...a) => t.$emit("onDragEnd", ...a)),
|
|
434
|
+
onOpenMenu: e[10] || (e[10] = (a) => t.$emit("openMenu", a))
|
|
435
|
+
}, null, 8, ["isDraggable", "menuItem", "parentUids", "uid"]))), 128)),
|
|
436
|
+
i.value.children.length === 0 ? (u(), c(n(k), {
|
|
437
|
+
key: 0,
|
|
438
|
+
class: g(["text-c-1 hover:bg-b-2 flex h-8 w-full justify-start gap-1.5 py-0 text-xs", t.parentUids.length ? "pl-9" : ""]),
|
|
439
|
+
variant: "ghost",
|
|
440
|
+
onClick: e[11] || (e[11] = (l) => S(i.value.entity.uid))
|
|
441
|
+
}, {
|
|
442
|
+
default: m(() => [
|
|
443
|
+
f(n(b), {
|
|
444
|
+
icon: "Add",
|
|
445
|
+
size: "sm"
|
|
446
|
+
}),
|
|
447
|
+
e[19] || (e[19] = s("span", null, "Add Request", -1))
|
|
448
|
+
]),
|
|
449
|
+
_: 1,
|
|
450
|
+
__: [19]
|
|
451
|
+
}, 8, ["class"])) : p("", !0)
|
|
452
|
+
])) : p("", !0)
|
|
453
|
+
]),
|
|
471
454
|
_: 3
|
|
472
455
|
}, 8, ["id", "ceiling", "floor", "isDraggable", "isDroppable", "parentIds"])
|
|
473
|
-
], 2)) :
|
|
456
|
+
], 2)) : p("", !0);
|
|
474
457
|
};
|
|
475
458
|
}
|
|
476
459
|
});
|
|
477
460
|
export {
|
|
478
|
-
|
|
461
|
+
Qe as default
|
|
479
462
|
};
|