@ynput/ayon-frontend-shared 0.5.0 → 0.6.0
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/dist/DetailsPanel.es.js +88 -86
- package/dist/Feed.es.js +22 -22
- package/dist/ListTable.es.js +77 -67
- package/dist/ProjectTreeTable.es.js +1164 -1150
- package/dist/Slicer.es.js +2 -2
- package/dist/Views.es.js +1 -1
- package/dist/api.es.js +331 -329
- package/dist/chunks/Actions.es.js +23 -23
- package/dist/chunks/DeleteEntitiesContext.es.js +115 -115
- package/dist/chunks/DetailsDialog.es.js +3 -3
- package/dist/chunks/DetailsPanelContext.es.js +155 -0
- package/dist/chunks/EntityPath.es.js +20 -20
- package/dist/chunks/EntityPickerDialog.es.js +1 -1
- package/dist/chunks/EntityTooltip.es.js +12 -12
- package/dist/chunks/EntityUpdatesContext.es.js +1 -1
- package/dist/chunks/Feed.es.js +2208 -2611
- package/dist/chunks/FilterErrorActions.es.js +1 -1
- package/dist/chunks/GlobalContext.es.js +14 -14
- package/dist/chunks/Menu.es.js +1 -1
- package/dist/chunks/MenuContext.es.js +51 -242
- package/dist/chunks/MenuItem.es.js +1 -1
- package/dist/chunks/MetaWidget.es.js +3341 -3899
- package/dist/chunks/NewEntityContext.es.js +40 -40
- package/dist/chunks/PlayableIcon.es.js +4261 -1163
- package/dist/chunks/ProjectContext.es.js +13 -13
- package/dist/chunks/ProjectFoldersContext.es.js +5 -5
- package/dist/chunks/RepresentationsList.es.js +3 -3
- package/dist/chunks/ReviewablesSelector.es.js +85 -76
- package/dist/chunks/SimpleForm.es.js +9 -9
- package/dist/chunks/SimpleTable.es.js +1 -1
- package/dist/chunks/Slicer.es.js +173 -171
- package/dist/chunks/TableSettingsFallback.es.js +6 -6
- package/dist/chunks/ThumbnailSimple.es.js +410 -61
- package/dist/chunks/VersionUploadContext.es.js +29 -29
- package/dist/chunks/ViewsContext.es.js +90 -90
- package/dist/chunks/Watchers.es.js +628 -598
- package/dist/chunks/entityDefinitions.es.js +31 -31
- package/dist/chunks/expandRelativeDates.es.js +27 -0
- package/dist/chunks/getBundleMode.es.js +16 -61
- package/dist/chunks/getUris.es.js +271 -269
- package/dist/chunks/queryFilterToClientFilter.es.js +11 -10
- package/dist/chunks/searchTerms.es.js +177 -173
- package/dist/chunks/uriUtils.es.js +48 -0
- package/dist/chunks/useAttributeEnums.es.js +11 -11
- package/dist/chunks/useColumnDragRestriction.es.js +37 -27
- package/dist/chunks/useDateRangeFilter.es.js +3 -3
- package/dist/chunks/useLocalStorage.es.js +9 -9
- package/dist/chunks/useSessionStorage.es.js +61 -0
- package/dist/chunks/viewUpdateHelper.es.js +19 -19
- package/dist/components.es.js +165 -160
- package/dist/context.es.js +60 -58
- package/dist/hooks.es.js +104 -98
- package/dist/index.es.js +18 -13
- package/dist/types/Actions.d.ts +16 -16
- package/dist/types/ContextMenu.d.ts +16 -16
- package/dist/types/DetailsPanel.d.ts +16 -16
- package/dist/types/EntityPickerDialog.d.ts +16 -16
- package/dist/types/Feed.d.ts +16 -16
- package/dist/types/ListTable.d.ts +16 -16
- package/dist/types/NewEntity.d.ts +16 -16
- package/dist/types/ProjectTreeTable.d.ts +20 -16
- package/dist/types/RepresentationsList.d.ts +16 -16
- package/dist/types/SimpleTable.d.ts +16 -16
- package/dist/types/Slicer.d.ts +16 -16
- package/dist/types/Views.d.ts +17 -17
- package/dist/types/api.d.ts +391 -95
- package/dist/types/components.d.ts +79 -20
- package/dist/types/context.d.ts +60 -17
- package/dist/types/hooks.d.ts +16 -16
- package/dist/types/index.d.ts +16 -16
- package/dist/types/util.d.ts +16 -16
- package/dist/util.es.js +108 -97
- package/package.json +16 -4
- package/dist/chunks/mentionTypeOptions.es.js +0 -15
package/dist/chunks/Slicer.es.js
CHANGED
|
@@ -2,35 +2,37 @@ import { jsx as E, jsxs as G, Fragment as $e } from "react/jsx-runtime";
|
|
|
2
2
|
import { useState as U, useCallback as A, useMemo as O, useContext as Ye, useEffect as se, forwardRef as Je, useRef as ye, useId as Xe, useImperativeHandle as Ze, useLayoutEffect as Te } from "react";
|
|
3
3
|
import { Splitter as et, SplitterPanel as tt } from "primereact/splitter";
|
|
4
4
|
import V from "styled-components";
|
|
5
|
-
import { u as
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
5
|
+
import { u as xe, n as me } from "./entityDefinitions.es.js";
|
|
6
|
+
import { u as ze } from "./useSessionStorage.es.js";
|
|
7
|
+
import { a as Ce } from "./useLocalStorage.es.js";
|
|
8
8
|
import { u as we } from "./ProjectFoldersContext.es.js";
|
|
9
|
-
import { E as
|
|
10
|
-
import { toast as
|
|
11
|
-
import { be as
|
|
12
|
-
import {
|
|
9
|
+
import { E as nt, u as st } from "./EntityPickerDialog.es.js";
|
|
10
|
+
import { toast as De } from "react-toastify";
|
|
11
|
+
import { be as Re, bq as ot, bg as Ue, bo as at } from "./searchTerms.es.js";
|
|
12
|
+
import { dl as Ve, cF as it, bS as rt, by as lt } from "./getUris.es.js";
|
|
13
13
|
import "primereact/confirmdialog";
|
|
14
|
-
import {
|
|
14
|
+
import { g as ct, P as dt, U as He } from "./MetaWidget.es.js";
|
|
15
15
|
import "lodash";
|
|
16
16
|
import "uuid";
|
|
17
|
-
import { b as he, H as
|
|
17
|
+
import { b as he, H as ut, a as pt, d as ft, S as mt } from "./SimpleTable.es.js";
|
|
18
18
|
import { a as ue } from "./ProjectContext.es.js";
|
|
19
|
-
import { u as
|
|
20
|
-
import { u as
|
|
19
|
+
import { u as ht } from "./GlobalContext.es.js";
|
|
20
|
+
import { u as gt, a as yt } from "./useAttributeEnums.es.js";
|
|
21
21
|
import { g as ge } from "./getEntityTypeIcon.es.js";
|
|
22
|
-
import { b as
|
|
23
|
-
import { g as
|
|
24
|
-
import { InputText as
|
|
22
|
+
import { b as bt, s as St } from "./buildHierarchicalTableRows.es.js";
|
|
23
|
+
import { g as Tt } from "./parseHtmlToPlainTextWithLinks.es.js";
|
|
24
|
+
import { InputText as vt, Button as It, Icon as xt } from "@ynput/ayon-react-components";
|
|
25
25
|
import W from "clsx";
|
|
26
|
-
import { u as
|
|
27
|
-
import { a as
|
|
28
|
-
import {
|
|
26
|
+
import { u as Ct } from "./NewEntityContext.es.js";
|
|
27
|
+
import { a as wt, K as Lt } from "./platform.es.js";
|
|
28
|
+
import { u as Et } from "./DetailsPanelContext.es.js";
|
|
29
|
+
import { g as kt } from "./DeleteEntitiesContext.es.js";
|
|
29
30
|
import { u as Dt } from "./VersionUploadContext.es.js";
|
|
30
|
-
import { u as
|
|
31
|
+
import { u as Rt, b as Pt, F as Pe } from "./EntityUpdatesContext.es.js";
|
|
31
32
|
import "./MenuItem.es.js";
|
|
32
33
|
import "@module-federation/enhanced/runtime";
|
|
33
34
|
import "semver";
|
|
35
|
+
import { u as Mt } from "./MenuContext.es.js";
|
|
34
36
|
import "react-dom";
|
|
35
37
|
const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.includes(r) ? Ge : a), Ot = (e, t, a, r) => {
|
|
36
38
|
const d = e.reduce((p, g) => p + g, 0), l = r.filter(Boolean).length;
|
|
@@ -63,7 +65,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
63
65
|
minSize: 2,
|
|
64
66
|
height: u
|
|
65
67
|
};
|
|
66
|
-
},
|
|
68
|
+
}, Ft = (e, t, a) => {
|
|
67
69
|
const r = e.map((m, p) => Math.max(m / 100 * t, a[p])), d = Math.max(
|
|
68
70
|
t,
|
|
69
71
|
a.reduce((m, p) => m + p, 0)
|
|
@@ -71,11 +73,11 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
71
73
|
if (l <= 0) return r;
|
|
72
74
|
const f = r.map((m, p) => m - a[p]), S = f.reduce((m, p) => m + p, 0);
|
|
73
75
|
return S ? r.map((m, p) => m - l * (f[p] / S)) : r;
|
|
74
|
-
},
|
|
76
|
+
}, jt = "slicer-splitter", Me = {
|
|
75
77
|
minSize: 2,
|
|
76
78
|
size: 12
|
|
77
|
-
},
|
|
78
|
-
const [e, t] = ze(
|
|
79
|
+
}, Xn = () => {
|
|
80
|
+
const [e, t] = ze(jt, [
|
|
79
81
|
Me.size,
|
|
80
82
|
100 - Me.size
|
|
81
83
|
]);
|
|
@@ -93,7 +95,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
93
95
|
height: u,
|
|
94
96
|
heights: b
|
|
95
97
|
} = Nt(m, t, a, r), h = (i) => {
|
|
96
|
-
const c =
|
|
98
|
+
const c = Ft(i.sizes, u, g);
|
|
97
99
|
l({
|
|
98
100
|
...m,
|
|
99
101
|
...Object.fromEntries(
|
|
@@ -117,7 +119,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
117
119
|
onClose: a,
|
|
118
120
|
onMoveComplete: r
|
|
119
121
|
}) => {
|
|
120
|
-
const [d] = Ve(), l =
|
|
122
|
+
const [d] = Ve(), l = ct(), { folders: f } = we(), S = l?.tableData || [], m = A(
|
|
121
123
|
(h) => l?.getEntityById(h) || f.find((i) => i.id === h),
|
|
122
124
|
[f, l]
|
|
123
125
|
), p = A(
|
|
@@ -145,7 +147,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
145
147
|
}
|
|
146
148
|
r?.(i);
|
|
147
149
|
} catch (c) {
|
|
148
|
-
let s =
|
|
150
|
+
let s = Re(c) || "Failed to move entities";
|
|
149
151
|
if (s.includes("already exists"))
|
|
150
152
|
if (t.entities.length > 1)
|
|
151
153
|
s = "Cannot move some entities - one or more entities with the same name already exist in the target location";
|
|
@@ -156,7 +158,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
156
158
|
const y = s.match(/name '.*?, (.+?)' already exists/);
|
|
157
159
|
s = `Cannot move "${y ? y[1] : "this folder"}" - a folder with this name already exists in the target location`;
|
|
158
160
|
}
|
|
159
|
-
|
|
161
|
+
De.error(s);
|
|
160
162
|
} finally {
|
|
161
163
|
a();
|
|
162
164
|
}
|
|
@@ -184,8 +186,8 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
184
186
|
throw new Error(s || "Some move operations failed");
|
|
185
187
|
}
|
|
186
188
|
} catch (h) {
|
|
187
|
-
let i =
|
|
188
|
-
|
|
189
|
+
let i = Re(h) || "Failed to move entities to root";
|
|
190
|
+
De.error(i);
|
|
189
191
|
} finally {
|
|
190
192
|
a();
|
|
191
193
|
}
|
|
@@ -216,9 +218,9 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
216
218
|
const s = f.find((y) => y.id === h);
|
|
217
219
|
if (s) {
|
|
218
220
|
const y = t.entities.find((n) => {
|
|
219
|
-
const
|
|
220
|
-
return
|
|
221
|
-
(v) => v.name ===
|
|
221
|
+
const I = m(n.entityId);
|
|
222
|
+
return I?.name ? S.filter((v) => n.entityType === "folder" ? v.entityType === "folder" && v.parentId === s.id : n.entityType === "task" ? v.entityType === "task" && v.folderId === s.id : !1).some(
|
|
223
|
+
(v) => v.name === I.name && v.entityId !== n.entityId
|
|
222
224
|
) : !1;
|
|
223
225
|
});
|
|
224
226
|
if (y)
|
|
@@ -250,7 +252,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
250
252
|
onMoveComplete: r
|
|
251
253
|
});
|
|
252
254
|
return t?.entities.length ? /* @__PURE__ */ E(
|
|
253
|
-
|
|
255
|
+
nt,
|
|
254
256
|
{
|
|
255
257
|
projectName: e,
|
|
256
258
|
entityType: "folder",
|
|
@@ -265,7 +267,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
265
267
|
}
|
|
266
268
|
) : null;
|
|
267
269
|
}, Vt = ({ projectName: e, useExtraSlices: t }) => {
|
|
268
|
-
const [a, { isLoading: r, isFetching: d }] =
|
|
270
|
+
const [a, { isLoading: r, isFetching: d }] = it(), { formatAssignees: l } = t();
|
|
269
271
|
return {
|
|
270
272
|
getData: async () => {
|
|
271
273
|
const S = await a({ projectName: e || "" }, !0).unwrap();
|
|
@@ -276,15 +278,15 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
276
278
|
}, Ht = ({ scopes: e, useExtraSlices: t }) => {
|
|
277
279
|
const { isLoading: a, productTypes: r, ...d } = ue(), { formatStatuses: l, formatTaskTypes: f, formatProductTypes: S, formatTypes: m, formatAttribute: p } = t();
|
|
278
280
|
return { project: d, getStatuses: async () => l(d, e), getTypes: async () => m(d), getTaskTypes: async () => f(d), getProductTypes: async () => S(r), getAttribute: async (i) => p ? p(i).map(
|
|
279
|
-
(c) =>
|
|
281
|
+
(c) => ot(c.icon ?? void 0) ? { ...c, icon: void 0, img: c.icon, imgShape: "circle" } : c
|
|
280
282
|
) : void 0, isLoading: a };
|
|
281
283
|
}, Bt = ({ entityTypes: e, request: t }) => {
|
|
282
284
|
const {
|
|
283
285
|
attributes: a,
|
|
284
286
|
isLoading: { siteInfo: r }
|
|
285
|
-
} =
|
|
286
|
-
return { attributes:
|
|
287
|
-
(p) => p.data.enum?.some((g) => g.hidden) ? { ...p, data: { ...p.data, enum:
|
|
287
|
+
} = ht(), d = Ye(dt), l = d?.attribFields?.length ? d.attribFields : a, { projectName: f } = ue();
|
|
288
|
+
return { attributes: gt(l, { projectName: f, request: t ?? [] }).filter((p) => Ue(p.data)).filter((p) => e.some((g) => p.scope?.includes(g))).map(
|
|
289
|
+
(p) => p.data.enum?.some((g) => g.hidden) ? { ...p, data: { ...p.data, enum: at(p.data.enum) } } : p
|
|
288
290
|
), isLoading: r };
|
|
289
291
|
}, Gt = "snippet_folder", de = "folder", Kt = (e) => `${de}-${e}`, _e = (e) => e.entityListType === "review-session" ? "subscriptions" : ge(e.entityType), ve = (e) => [...e].sort((t, a) => {
|
|
290
292
|
if (t.active && !a.active) return -1;
|
|
@@ -296,13 +298,13 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
296
298
|
data: r,
|
|
297
299
|
isLoading: d,
|
|
298
300
|
isFetching: l
|
|
299
|
-
} =
|
|
301
|
+
} = rt(
|
|
300
302
|
{ projectName: t || "" },
|
|
301
303
|
{
|
|
302
304
|
initialPageParam: { cursor: "" },
|
|
303
305
|
skip: !t || !e
|
|
304
306
|
}
|
|
305
|
-
), { data: f = [], isLoading: S } =
|
|
307
|
+
), { data: f = [], isLoading: S } = lt(
|
|
306
308
|
{ projectName: t || "" },
|
|
307
309
|
{ skip: !t || !a || !e }
|
|
308
310
|
), m = O(() => {
|
|
@@ -320,30 +322,30 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
320
322
|
}), n.parentId || b.add(n.id);
|
|
321
323
|
for (const n of f)
|
|
322
324
|
if (n.parentId && u.has(n.parentId)) {
|
|
323
|
-
const
|
|
324
|
-
|
|
325
|
+
const I = u.get(n.parentId), T = u.get(n.id);
|
|
326
|
+
I.children.set(n.id, T);
|
|
325
327
|
}
|
|
326
328
|
const h = [];
|
|
327
329
|
for (const n of L) {
|
|
328
|
-
const
|
|
329
|
-
if (
|
|
330
|
-
const T = u.get(
|
|
330
|
+
const I = n.entityListFolderId;
|
|
331
|
+
if (I && u.has(I)) {
|
|
332
|
+
const T = u.get(I);
|
|
331
333
|
T.items.push(n), T.hasAnyItems = !0;
|
|
332
334
|
} else
|
|
333
335
|
h.push(n);
|
|
334
336
|
}
|
|
335
337
|
for (const n of u.values())
|
|
336
338
|
if (n.hasAnyItems) {
|
|
337
|
-
let
|
|
338
|
-
for (;
|
|
339
|
-
const T = u.get(
|
|
339
|
+
let I = n.folder;
|
|
340
|
+
for (; I.parentId; ) {
|
|
341
|
+
const T = u.get(I.parentId);
|
|
340
342
|
if (T)
|
|
341
|
-
T.hasAnyItems = !0,
|
|
343
|
+
T.hasAnyItems = !0, I = T.folder;
|
|
342
344
|
else
|
|
343
345
|
break;
|
|
344
346
|
}
|
|
345
347
|
}
|
|
346
|
-
const i = (n,
|
|
348
|
+
const i = (n, I, T = []) => ({
|
|
347
349
|
id: n.id,
|
|
348
350
|
name: n.label,
|
|
349
351
|
label: n.label,
|
|
@@ -357,15 +359,15 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
357
359
|
entityType: n.entityType,
|
|
358
360
|
listId: n.id
|
|
359
361
|
}
|
|
360
|
-
}), c = (n) => n.sort((
|
|
361
|
-
const v = f.findIndex((H) => H.id ===
|
|
362
|
-
return v === -1 && k === -1 ?
|
|
362
|
+
}), c = (n) => n.sort((I, T) => {
|
|
363
|
+
const v = f.findIndex((H) => H.id === I.id), k = f.findIndex((H) => H.id === T.id);
|
|
364
|
+
return v === -1 && k === -1 ? I.folder.label.localeCompare(T.folder.label) : v === -1 ? 1 : k === -1 ? -1 : v - k;
|
|
363
365
|
}), s = (n) => {
|
|
364
|
-
const
|
|
366
|
+
const I = n.items.map((T) => T.id);
|
|
365
367
|
for (const T of n.children.values())
|
|
366
|
-
|
|
367
|
-
return
|
|
368
|
-
}, o =
|
|
368
|
+
I.push(...s(T));
|
|
369
|
+
return I;
|
|
370
|
+
}, o = bt({
|
|
369
371
|
folderNodes: u,
|
|
370
372
|
rootFolderIds: b,
|
|
371
373
|
showEmptyFolders: !1,
|
|
@@ -376,21 +378,21 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
376
378
|
getFolderLabel: (n) => n.label,
|
|
377
379
|
getFolderIcon: (n) => n.data?.icon || Gt,
|
|
378
380
|
getFolderColor: (n) => n.data?.color,
|
|
379
|
-
getItemCount: (n) => n.items.length + Array.from(n.children.values()).reduce((
|
|
381
|
+
getItemCount: (n) => n.items.length + Array.from(n.children.values()).reduce((I, T) => I + T.items.length, 0)
|
|
380
382
|
});
|
|
381
383
|
for (const n of o) {
|
|
382
384
|
if (n.id.startsWith(de + "-")) {
|
|
383
385
|
const T = n.id.substring((de + "-").length), v = u.get(T);
|
|
384
386
|
v && (n.data = { ...n.data, childListIds: s(v) });
|
|
385
387
|
}
|
|
386
|
-
const
|
|
387
|
-
for (;
|
|
388
|
-
const T =
|
|
388
|
+
const I = [...n.subRows || []];
|
|
389
|
+
for (; I.length > 0; ) {
|
|
390
|
+
const T = I.shift();
|
|
389
391
|
if (T.id.startsWith(de + "-")) {
|
|
390
392
|
const v = T.id.substring((de + "-").length), k = u.get(v);
|
|
391
393
|
k && (T.data = { ...T.data, childListIds: s(k) });
|
|
392
394
|
}
|
|
393
|
-
T.subRows &&
|
|
395
|
+
T.subRows && I.push(...T.subRows);
|
|
394
396
|
}
|
|
395
397
|
}
|
|
396
398
|
const y = ve(h).map((n) => i(n));
|
|
@@ -497,13 +499,13 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
497
499
|
onSliceTypeChange: p,
|
|
498
500
|
useExtraSlices: g,
|
|
499
501
|
isLoadingExtraSlices: L
|
|
500
|
-
} =
|
|
502
|
+
} = xe(), u = f ?? m, b = S ?? p, { projectName: h } = ue(), { formatAttribute: i } = g(), c = e.filter((C) => Ae.some((R) => R.value === C.value)).map((C) => ({
|
|
501
503
|
...Ae.find((_) => _.value === C.value),
|
|
502
504
|
...C
|
|
503
505
|
})), s = e.some((C) => C.value === "attributes"), o = u?.startsWith("attrib.") ? u.slice(7) : void 0, y = O(
|
|
504
506
|
() => o ? [o] : [],
|
|
505
507
|
[o]
|
|
506
|
-
), { attributes: n, isLoading:
|
|
508
|
+
), { attributes: n, isLoading: I } = Bt({
|
|
507
509
|
entityTypes: a,
|
|
508
510
|
request: y
|
|
509
511
|
});
|
|
@@ -511,7 +513,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
511
513
|
(C) => c.push({
|
|
512
514
|
label: C.data.title || C.name,
|
|
513
515
|
value: "attrib." + C.name,
|
|
514
|
-
icon:
|
|
516
|
+
icon: Tt(C.name, C.data.type, Ue(C.data))
|
|
515
517
|
})
|
|
516
518
|
);
|
|
517
519
|
const [T, v] = U(!1), H = !!n.find((C) => C.name === o)?.enumIsLoading, {
|
|
@@ -526,33 +528,33 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
526
528
|
data: te,
|
|
527
529
|
getData: Q,
|
|
528
530
|
isFetching: Y
|
|
529
|
-
} =
|
|
531
|
+
} = st({
|
|
530
532
|
projectName: h || "",
|
|
531
533
|
folderTypes: oe?.folderTypes || [],
|
|
532
534
|
includeColors: !0
|
|
533
|
-
}), { getData:
|
|
535
|
+
}), { getData: x, isLoading: D } = Vt({
|
|
534
536
|
projectName: h,
|
|
535
537
|
useExtraSlices: g
|
|
536
538
|
}), {
|
|
537
539
|
getData: P,
|
|
538
540
|
isLoading: K,
|
|
539
541
|
isExpandable: re
|
|
540
|
-
} = Wt(u === "entityList"),
|
|
542
|
+
} = Wt(u === "entityList"), j = Y || B || D || L && u !== "hierarchy" || K && u === "entityList" || I || H, N = {
|
|
541
543
|
hierarchy: {
|
|
542
544
|
getData: Q,
|
|
543
545
|
isLoading: Y,
|
|
544
546
|
isExpandable: !0
|
|
545
547
|
},
|
|
546
548
|
assignees: {
|
|
547
|
-
getData:
|
|
548
|
-
isLoading:
|
|
549
|
+
getData: x,
|
|
550
|
+
isLoading: D,
|
|
549
551
|
isExpandable: !1,
|
|
550
552
|
noValue: !0,
|
|
551
553
|
hasValue: !0
|
|
552
554
|
},
|
|
553
555
|
author: {
|
|
554
|
-
getData:
|
|
555
|
-
isLoading:
|
|
556
|
+
getData: x,
|
|
557
|
+
isLoading: D,
|
|
556
558
|
isExpandable: !1
|
|
557
559
|
},
|
|
558
560
|
status: {
|
|
@@ -584,7 +586,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
584
586
|
for (const C of n)
|
|
585
587
|
N["attrib." + C.name] = {
|
|
586
588
|
getData: () => ee(C),
|
|
587
|
-
isLoading:
|
|
589
|
+
isLoading: I || !!C.enumIsLoading,
|
|
588
590
|
isExpandable: !1,
|
|
589
591
|
isAttribute: !0
|
|
590
592
|
};
|
|
@@ -592,56 +594,56 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
592
594
|
(C) => N[C.value] && !t.includes(C.value)
|
|
593
595
|
)?.value;
|
|
594
596
|
se(() => {
|
|
595
|
-
|
|
596
|
-
}, [
|
|
597
|
-
const z = (C,
|
|
597
|
+
j || $ || !ne || b(ne, !1);
|
|
598
|
+
}, [j, $, ne]);
|
|
599
|
+
const z = (C, R) => {
|
|
598
600
|
const _ = N[C];
|
|
599
601
|
if (!_) {
|
|
600
602
|
console.warn(`Slice type ${C} not found`);
|
|
601
603
|
return;
|
|
602
604
|
}
|
|
603
|
-
(_.isAttribute && s || e.some((ce) => ce.value === C)) && b(C,
|
|
605
|
+
(_.isAttribute && s || e.some((ce) => ce.value === C)) && b(C, R);
|
|
604
606
|
};
|
|
605
607
|
se(() => {
|
|
606
|
-
if (
|
|
608
|
+
if (j) return;
|
|
607
609
|
(async () => {
|
|
608
610
|
try {
|
|
609
611
|
if (!$) return;
|
|
610
612
|
v(!0);
|
|
611
|
-
const
|
|
612
|
-
if (
|
|
613
|
+
const R = await $.getData();
|
|
614
|
+
if (R === void 0)
|
|
613
615
|
throw window.alert(
|
|
614
616
|
"Slice options failed to load. This likely means the PowerFeatures addon is out of date. Please update to the latest version."
|
|
615
617
|
), b(ne ?? "hierarchy", !1), new Error("Slice data is undefined");
|
|
616
|
-
$.hasValue &&
|
|
617
|
-
data:
|
|
618
|
+
$.hasValue && R.unshift(Yt(u)), $.noValue && R.unshift(Qt(u)), fe({
|
|
619
|
+
data: R,
|
|
618
620
|
isExpandable: $.isExpandable
|
|
619
621
|
});
|
|
620
|
-
} catch (
|
|
621
|
-
console.error("Error fetching slice data:",
|
|
622
|
+
} catch (R) {
|
|
623
|
+
console.error("Error fetching slice data:", R), fe(pe);
|
|
622
624
|
} finally {
|
|
623
625
|
v(!1);
|
|
624
626
|
}
|
|
625
627
|
})();
|
|
626
|
-
}, [u, h,
|
|
627
|
-
const
|
|
628
|
+
}, [u, h, j, u === "hierarchy" ? te : null]);
|
|
629
|
+
const F = O(
|
|
628
630
|
() => Ke(le.data, r, d, l),
|
|
629
631
|
[le.data, r, d, l]
|
|
630
632
|
), Le = O(() => {
|
|
631
|
-
const C = /* @__PURE__ */ new Map(),
|
|
632
|
-
for (;
|
|
633
|
-
const _ =
|
|
633
|
+
const C = /* @__PURE__ */ new Map(), R = [...F];
|
|
634
|
+
for (; R.length > 0; ) {
|
|
635
|
+
const _ = R.shift();
|
|
634
636
|
if (_ && (C.set(_.id, _), _.subRows && _.subRows.length > 0))
|
|
635
637
|
for (const ce of _.subRows)
|
|
636
|
-
|
|
638
|
+
R.push(ce);
|
|
637
639
|
}
|
|
638
640
|
return C;
|
|
639
|
-
}, [
|
|
641
|
+
}, [F]);
|
|
640
642
|
return {
|
|
641
643
|
sliceOptions: c,
|
|
642
|
-
table: { ...le, data:
|
|
644
|
+
table: { ...le, data: F },
|
|
643
645
|
sliceMap: Le,
|
|
644
|
-
isLoading: N[u] && N[u].isLoading || T ||
|
|
646
|
+
isLoading: N[u] && N[u].isLoading || T || j,
|
|
645
647
|
sliceType: u,
|
|
646
648
|
handleSliceTypeChange: z
|
|
647
649
|
};
|
|
@@ -655,7 +657,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
655
657
|
extraGroupBys: l,
|
|
656
658
|
args: e?.args ?? { projectName: "" },
|
|
657
659
|
skip: f
|
|
658
|
-
}, { counts: m, total: p, complete: g } =
|
|
660
|
+
}, { counts: m, total: p, complete: g } = yt(S), L = m?.get(He)?.count ?? 0, u = Math.max(p - L, 0);
|
|
659
661
|
return {
|
|
660
662
|
counts: f ? void 0 : m ?? (g ? Xt : void 0),
|
|
661
663
|
total: p,
|
|
@@ -670,7 +672,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
670
672
|
flex: 1;
|
|
671
673
|
min-width: 0;
|
|
672
674
|
}
|
|
673
|
-
`, tn = V(
|
|
675
|
+
`, tn = V(vt)`
|
|
674
676
|
flex: 1;
|
|
675
677
|
min-width: 0;
|
|
676
678
|
height: 28px;
|
|
@@ -700,10 +702,10 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
700
702
|
}
|
|
701
703
|
)
|
|
702
704
|
] });
|
|
703
|
-
},
|
|
704
|
-
e.toggleExpanded(t), e.subRows?.forEach((a) =>
|
|
705
|
+
}, Ie = (e, t) => {
|
|
706
|
+
e.toggleExpanded(t), e.subRows?.forEach((a) => Ie(a, t));
|
|
705
707
|
}, Oe = (e) => e.map((t) => t.id).filter(Boolean), sn = (e, t, a, r) => {
|
|
706
|
-
const { onOpenNew: d } =
|
|
708
|
+
const { onOpenNew: d } = Ct(), { projectName: l } = ue(), { setEntities: f } = Et(), S = Dt(), [m] = Ve(), { deleteEntities: p } = kt(), [g, L] = U(null), u = A(
|
|
707
709
|
(c, s) => s.map((o) => t?.get(o) || (o === c.id ? c : void 0)).filter((o) => !!o),
|
|
708
710
|
[t]
|
|
709
711
|
), b = O(
|
|
@@ -782,7 +784,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
782
784
|
(c, { row: s, selectedRows: o }) => ({
|
|
783
785
|
label: "Show details",
|
|
784
786
|
icon: "dock_to_left",
|
|
785
|
-
shortcut:
|
|
787
|
+
shortcut: wt("click", [Lt.Alt]),
|
|
786
788
|
command: () => b.onShowDetails(s.original, o)
|
|
787
789
|
}),
|
|
788
790
|
(c, { row: s }) => ({
|
|
@@ -800,7 +802,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
800
802
|
(c, { selectedTableRows: s }) => ({
|
|
801
803
|
label: "Expand all children",
|
|
802
804
|
icon: "expand_all",
|
|
803
|
-
command: () => s.filter((o) => o.getCanExpand() && !o.getIsExpanded()).forEach((o) =>
|
|
805
|
+
command: () => s.filter((o) => o.getCanExpand() && !o.getIsExpanded()).forEach((o) => Ie(o, !0)),
|
|
804
806
|
hidden: !s.some(
|
|
805
807
|
(o) => o.getCanExpand() && !o.getIsExpanded()
|
|
806
808
|
)
|
|
@@ -808,7 +810,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
808
810
|
(c, { selectedTableRows: s }) => ({
|
|
809
811
|
label: "Collapse all children",
|
|
810
812
|
icon: "collapse_all",
|
|
811
|
-
command: () => s.filter((o) => o.getCanExpand() && o.getIsExpanded()).forEach((o) =>
|
|
813
|
+
command: () => s.filter((o) => o.getCanExpand() && o.getIsExpanded()).forEach((o) => Ie(o, !1)),
|
|
812
814
|
hidden: !s.some(
|
|
813
815
|
(o) => o.getCanExpand() && o.getIsExpanded()
|
|
814
816
|
)
|
|
@@ -862,7 +864,7 @@ const _t = 180, Be = 100, Ge = 34, At = (e, t = [], a = Be) => e.map((r) => t.in
|
|
|
862
864
|
onSubmitRename: h,
|
|
863
865
|
onCancelRename: () => L(null)
|
|
864
866
|
};
|
|
865
|
-
}, on = V(
|
|
867
|
+
}, on = V(It)`
|
|
866
868
|
/* put above the menu so it's still clickable */
|
|
867
869
|
/* NOTE: this will need fixing as this also puts it above dialogs */
|
|
868
870
|
/* z-index: 1001; */
|
|
@@ -934,7 +936,7 @@ const an = (e, t, a) => {
|
|
|
934
936
|
).join(", ")} since last sync`;
|
|
935
937
|
}, ln = Je(
|
|
936
938
|
({ projectNames: e, topics: t, onSync: a, shouldSyncOnUpdate: r, hideWhenNoUpdates: d = !1, ...l }, f) => {
|
|
937
|
-
const [S, m] = U(!1), [p, g] =
|
|
939
|
+
const [S, m] = U(!1), [p, g] = Rt(), { setMenuOpen: L } = Mt(), u = ye(null), b = ye(), h = Xe();
|
|
938
940
|
se(() => () => {
|
|
939
941
|
const v = b.current;
|
|
940
942
|
b.current = void 0, v !== void 0 && clearTimeout(v);
|
|
@@ -946,7 +948,7 @@ const an = (e, t, a) => {
|
|
|
946
948
|
} finally {
|
|
947
949
|
m(!1);
|
|
948
950
|
}
|
|
949
|
-
}, { updates: c, hasUpdates: s } =
|
|
951
|
+
}, { updates: c, hasUpdates: s } = Pt({
|
|
950
952
|
projectNames: e,
|
|
951
953
|
topics: t,
|
|
952
954
|
isSyncing: S,
|
|
@@ -954,7 +956,7 @@ const an = (e, t, a) => {
|
|
|
954
956
|
});
|
|
955
957
|
if (se(() => {
|
|
956
958
|
const v = (k) => {
|
|
957
|
-
k.repeat || !k.shiftKey || k.ctrlKey || k.metaKey || k.key.toLowerCase() !== "r" ||
|
|
959
|
+
k.repeat || !k.shiftKey || k.ctrlKey || k.metaKey || k.key.toLowerCase() !== "r" || St(k) || (k.preventDefault(), k.stopPropagation(), i());
|
|
958
960
|
};
|
|
959
961
|
return window.addEventListener("keydown", v), () => window.removeEventListener("keydown", v);
|
|
960
962
|
}, [i]), d && !s) return null;
|
|
@@ -1032,7 +1034,7 @@ const an = (e, t, a) => {
|
|
|
1032
1034
|
}
|
|
1033
1035
|
const y = c[c.length - 1];
|
|
1034
1036
|
if (y && o(y, i.clientWidth)) return;
|
|
1035
|
-
const n = i.clientWidth - s,
|
|
1037
|
+
const n = i.clientWidth - s, I = c.filter((v) => o(v, n)).length, T = Math.max(1, I);
|
|
1036
1038
|
T !== g && L(T);
|
|
1037
1039
|
}), !l.length) return /* @__PURE__ */ E(Ne, { ref: a });
|
|
1038
1040
|
const b = l.slice(0, g), h = l.length - b.length;
|
|
@@ -1044,7 +1046,7 @@ const an = (e, t, a) => {
|
|
|
1044
1046
|
title: i.label || i.name,
|
|
1045
1047
|
"aria-label": i.label || i.name,
|
|
1046
1048
|
children: [
|
|
1047
|
-
i.startContent ?? (i.img ? /* @__PURE__ */ E("img", { src: i.img, alt: "" }) : i.icon && /* @__PURE__ */ E(
|
|
1049
|
+
i.startContent ?? (i.img ? /* @__PURE__ */ E("img", { src: i.img, alt: "" }) : i.icon && /* @__PURE__ */ E(xt, { icon: i.icon, style: { color: i.iconColor } })),
|
|
1048
1050
|
!(p && f(i)) && /* @__PURE__ */ E("span", { children: i.label || i.name })
|
|
1049
1051
|
]
|
|
1050
1052
|
},
|
|
@@ -1072,7 +1074,7 @@ const an = (e, t, a) => {
|
|
|
1072
1074
|
flex: 1;
|
|
1073
1075
|
min-width: 0;
|
|
1074
1076
|
}
|
|
1075
|
-
`, fn = V(
|
|
1077
|
+
`, fn = V(ut)`
|
|
1076
1078
|
.slicer-dropdown {
|
|
1077
1079
|
flex: 0 1 auto;
|
|
1078
1080
|
min-width: 48px;
|
|
@@ -1106,7 +1108,7 @@ const an = (e, t, a) => {
|
|
|
1106
1108
|
text-overflow: ellipsis;
|
|
1107
1109
|
white-space: nowrap;
|
|
1108
1110
|
}
|
|
1109
|
-
`,
|
|
1111
|
+
`, Fe = "__splitSlicer__", je = ({
|
|
1110
1112
|
panel: e,
|
|
1111
1113
|
visibleSlices: t,
|
|
1112
1114
|
sliceFields: a,
|
|
@@ -1130,13 +1132,13 @@ const an = (e, t, a) => {
|
|
|
1130
1132
|
setPanelSliceType: o,
|
|
1131
1133
|
getPanelSelection: y,
|
|
1132
1134
|
setPanelSelection: n,
|
|
1133
|
-
getPanelExpanded:
|
|
1135
|
+
getPanelExpanded: I,
|
|
1134
1136
|
setPanelExpanded: T,
|
|
1135
1137
|
onSliceTypeChange: v,
|
|
1136
1138
|
isViewSyncPending: k,
|
|
1137
1139
|
onOpenViewer: H,
|
|
1138
1140
|
onAddToList: oe
|
|
1139
|
-
} =
|
|
1141
|
+
} = xe(), { refetch: ae } = we(), { powerLicense: q, setPowerpackDialog: ie } = Ce(), Z = y(e.id), ee = I(e.id), B = (w) => {
|
|
1140
1142
|
n(e.id, w);
|
|
1141
1143
|
}, te = A(
|
|
1142
1144
|
(w) => T(e.id, w),
|
|
@@ -1149,7 +1151,7 @@ const an = (e, t, a) => {
|
|
|
1149
1151
|
if (typeof l != "function") return w;
|
|
1150
1152
|
const M = (X) => JSON.stringify([X?.entity, X?.args]), Qe = M(Q);
|
|
1151
1153
|
return w.filter((X) => X === e.sliceType || M(l(X)) === Qe);
|
|
1152
|
-
}, [l, Q, t, e.sliceType]), { counts:
|
|
1154
|
+
}, [l, Q, t, e.sliceType]), { counts: x, filled: D, complete: P } = Zt(
|
|
1153
1155
|
Q,
|
|
1154
1156
|
e.sliceType,
|
|
1155
1157
|
Y
|
|
@@ -1162,7 +1164,7 @@ const an = (e, t, a) => {
|
|
|
1162
1164
|
() => t.filter((w) => w.id !== e.id).map((w) => w.sliceType),
|
|
1163
1165
|
[t, e.id]
|
|
1164
1166
|
), {
|
|
1165
|
-
sliceOptions:
|
|
1167
|
+
sliceOptions: j,
|
|
1166
1168
|
sliceType: N,
|
|
1167
1169
|
handleSliceTypeChange: pe,
|
|
1168
1170
|
table: { data: le, isExpandable: fe },
|
|
@@ -1172,57 +1174,57 @@ const an = (e, t, a) => {
|
|
|
1172
1174
|
sliceFields: a,
|
|
1173
1175
|
usedSliceTypes: re,
|
|
1174
1176
|
entityTypes: r,
|
|
1175
|
-
counts:
|
|
1176
|
-
filled:
|
|
1177
|
+
counts: x,
|
|
1178
|
+
filled: D,
|
|
1177
1179
|
countsComplete: P,
|
|
1178
1180
|
sliceType: e.sliceType,
|
|
1179
1181
|
onSliceTypeChange: K
|
|
1180
|
-
}), z = N === "hierarchy",
|
|
1182
|
+
}), z = N === "hierarchy", F = !!p && c.includes(e.id), C = j.find((w) => w.value === N)?.label || N, R = L !== void 0, _ = L ?? "", ce = z ? "Folders" : C, J = sn(
|
|
1181
1183
|
f || oe,
|
|
1182
1184
|
$,
|
|
1183
1185
|
H,
|
|
1184
1186
|
S
|
|
1185
1187
|
), We = z ? J.rowContextMenuBuilders : [], Ee = O(
|
|
1186
|
-
() =>
|
|
1187
|
-
[
|
|
1188
|
+
() => j.map((w) => w.value).filter((w) => !t.some((M) => M.sliceType === w)),
|
|
1189
|
+
[j, t]
|
|
1188
1190
|
), be = !!m && Ee.length > 0, Se = O(() => {
|
|
1189
|
-
const w =
|
|
1191
|
+
const w = j.map(
|
|
1190
1192
|
(M) => re.includes(M.value) ? { ...M, disabled: !0, disabledMessage: "Already used by another panel" } : M
|
|
1191
1193
|
);
|
|
1192
|
-
return be && w.push({ label: "Split slicer", value:
|
|
1193
|
-
}, [
|
|
1194
|
+
return be && w.push({ label: "Split slicer", value: Fe, icon: "splitscreen_add" }), w;
|
|
1195
|
+
}, [j, re, be]), ke = () => {
|
|
1194
1196
|
if (!q) return ie("slicer");
|
|
1195
1197
|
h(Ee[0]);
|
|
1196
1198
|
}, qe = (w) => {
|
|
1197
1199
|
const M = String(w[0]);
|
|
1198
|
-
if (M ===
|
|
1200
|
+
if (M === Fe) {
|
|
1199
1201
|
ke();
|
|
1200
1202
|
return;
|
|
1201
1203
|
}
|
|
1202
1204
|
pe(M, !!g && d === N);
|
|
1203
1205
|
};
|
|
1204
|
-
return /* @__PURE__ */ G(
|
|
1206
|
+
return /* @__PURE__ */ G(pt, { children: [
|
|
1205
1207
|
/* @__PURE__ */ G(
|
|
1206
1208
|
fn,
|
|
1207
1209
|
{
|
|
1208
|
-
className: W({ collapsed:
|
|
1209
|
-
onClick:
|
|
1210
|
+
className: W({ collapsed: F }),
|
|
1211
|
+
onClick: F ? () => s(e.id) : void 0,
|
|
1210
1212
|
children: [
|
|
1211
1213
|
p && /* @__PURE__ */ E(
|
|
1212
1214
|
he,
|
|
1213
1215
|
{
|
|
1214
1216
|
icon: "expand_more",
|
|
1215
|
-
className: W("collapse-toggle", { collapsed:
|
|
1216
|
-
"data-tooltip":
|
|
1217
|
+
className: W("collapse-toggle", { collapsed: F }),
|
|
1218
|
+
"data-tooltip": F ? "Expand panel" : "Collapse panel",
|
|
1217
1219
|
"data-tooltip-delay": 0,
|
|
1218
1220
|
onClick: () => s(e.id)
|
|
1219
1221
|
}
|
|
1220
1222
|
),
|
|
1221
|
-
|
|
1223
|
+
F ? (
|
|
1222
1224
|
// the dropdown cannot be used from a collapsed panel, but the dimension it
|
|
1223
1225
|
// shows has to read the same as the dropdown does when open
|
|
1224
1226
|
/* @__PURE__ */ E(mn, { children: /* @__PURE__ */ E("span", { children: C }) })
|
|
1225
|
-
) : k ? /* @__PURE__ */ E(un, {}) : !
|
|
1227
|
+
) : k ? /* @__PURE__ */ E(un, {}) : !R && /* @__PURE__ */ E(
|
|
1226
1228
|
b,
|
|
1227
1229
|
{
|
|
1228
1230
|
options: Se,
|
|
@@ -1233,17 +1235,17 @@ const an = (e, t, a) => {
|
|
|
1233
1235
|
disableOpen: Se.length === 1
|
|
1234
1236
|
}
|
|
1235
1237
|
),
|
|
1236
|
-
|
|
1238
|
+
F && /* @__PURE__ */ E(dn, { rowSelection: Z, sliceMap: $ }),
|
|
1237
1239
|
/* @__PURE__ */ G(
|
|
1238
1240
|
pn,
|
|
1239
1241
|
{
|
|
1240
|
-
className: W({ searching:
|
|
1242
|
+
className: W({ searching: R }),
|
|
1241
1243
|
onClick: (w) => w.stopPropagation(),
|
|
1242
1244
|
children: [
|
|
1243
|
-
!
|
|
1245
|
+
!F && /* @__PURE__ */ E(
|
|
1244
1246
|
nn,
|
|
1245
1247
|
{
|
|
1246
|
-
open:
|
|
1248
|
+
open: R,
|
|
1247
1249
|
value: _,
|
|
1248
1250
|
subject: ce,
|
|
1249
1251
|
onChange: u
|
|
@@ -1259,7 +1261,7 @@ const an = (e, t, a) => {
|
|
|
1259
1261
|
hideWhenNoUpdates: !0
|
|
1260
1262
|
}
|
|
1261
1263
|
),
|
|
1262
|
-
be && g && !
|
|
1264
|
+
be && g && !R && /* @__PURE__ */ E(
|
|
1263
1265
|
he,
|
|
1264
1266
|
{
|
|
1265
1267
|
icon: "splitscreen_add",
|
|
@@ -1269,7 +1271,7 @@ const an = (e, t, a) => {
|
|
|
1269
1271
|
onClick: ke
|
|
1270
1272
|
}
|
|
1271
1273
|
),
|
|
1272
|
-
!g && !
|
|
1274
|
+
!g && !R && /* @__PURE__ */ E(
|
|
1273
1275
|
he,
|
|
1274
1276
|
{
|
|
1275
1277
|
icon: "close",
|
|
@@ -1284,8 +1286,8 @@ const an = (e, t, a) => {
|
|
|
1284
1286
|
]
|
|
1285
1287
|
}
|
|
1286
1288
|
),
|
|
1287
|
-
!
|
|
1288
|
-
|
|
1289
|
+
!F && /* @__PURE__ */ E(
|
|
1290
|
+
ft,
|
|
1289
1291
|
{
|
|
1290
1292
|
rowSelection: Z,
|
|
1291
1293
|
onRowSelectionChange: B,
|
|
@@ -1293,7 +1295,7 @@ const an = (e, t, a) => {
|
|
|
1293
1295
|
setExpanded: te,
|
|
1294
1296
|
data: $,
|
|
1295
1297
|
children: /* @__PURE__ */ E(
|
|
1296
|
-
|
|
1298
|
+
mt,
|
|
1297
1299
|
{
|
|
1298
1300
|
data: le,
|
|
1299
1301
|
isExpandable: fe,
|
|
@@ -1327,7 +1329,7 @@ const an = (e, t, a) => {
|
|
|
1327
1329
|
}
|
|
1328
1330
|
`
|
|
1329
1331
|
).join("")}
|
|
1330
|
-
`,
|
|
1332
|
+
`, Zn = ({
|
|
1331
1333
|
sliceFields: e = [],
|
|
1332
1334
|
entityTypes: t = ["task"],
|
|
1333
1335
|
pinnedSliceType: a,
|
|
@@ -1335,45 +1337,45 @@ const an = (e, t, a) => {
|
|
|
1335
1337
|
onAddToList: d,
|
|
1336
1338
|
enableSplit: l
|
|
1337
1339
|
}) => {
|
|
1338
|
-
const { slices: f, page: S, setPanelExpanded: m, projectName: p, collapsedPanels: g } =
|
|
1339
|
-
i("entities" in
|
|
1340
|
+
const { slices: f, page: S, setPanelExpanded: m, projectName: p, collapsedPanels: g } = xe(), { powerLicense: L } = Ce(), u = !!l, b = u && L ? f : f.slice(0, 1), [h, i] = U(null), c = A((x) => {
|
|
1341
|
+
i("entities" in x ? x : { entities: [x] });
|
|
1340
1342
|
}, []), s = A(() => {
|
|
1341
1343
|
i(null);
|
|
1342
1344
|
}, []), { getParentFolderIds: o } = we(), y = A(
|
|
1343
|
-
(
|
|
1344
|
-
const
|
|
1345
|
+
(x) => {
|
|
1346
|
+
const D = [x, ...o(x)];
|
|
1345
1347
|
m(
|
|
1346
1348
|
"hierarchy",
|
|
1347
|
-
(P) => typeof P == "boolean" ? P || Object.fromEntries(
|
|
1349
|
+
(P) => typeof P == "boolean" ? P || Object.fromEntries(D.map((K) => [K, !0])) : {
|
|
1348
1350
|
...P,
|
|
1349
|
-
...Object.fromEntries(
|
|
1351
|
+
...Object.fromEntries(D.map((K) => [K, !0]))
|
|
1350
1352
|
}
|
|
1351
1353
|
);
|
|
1352
1354
|
},
|
|
1353
1355
|
[o, m]
|
|
1354
|
-
), n = ye(null), [
|
|
1356
|
+
), n = ye(null), [I, T] = U(0);
|
|
1355
1357
|
se(() => {
|
|
1356
|
-
const
|
|
1357
|
-
if (!
|
|
1358
|
-
const
|
|
1359
|
-
return
|
|
1358
|
+
const x = n.current;
|
|
1359
|
+
if (!x) return;
|
|
1360
|
+
const D = new ResizeObserver(([P]) => T(P.contentRect.height));
|
|
1361
|
+
return D.observe(x), () => D.disconnect();
|
|
1360
1362
|
}, [b.length]);
|
|
1361
|
-
const v = b.map((
|
|
1363
|
+
const v = b.map((x) => x.id), k = b.length > 1, {
|
|
1362
1364
|
sizes: H,
|
|
1363
1365
|
minSize: oe,
|
|
1364
1366
|
height: ae,
|
|
1365
1367
|
layoutKey: q,
|
|
1366
1368
|
handleResizeEnd: ie
|
|
1367
|
-
} = $t(S, v, k ? g : [],
|
|
1368
|
-
(
|
|
1369
|
-
).filter((
|
|
1370
|
-
(
|
|
1369
|
+
} = $t(S, v, k ? g : [], I), Z = v.slice(0, -1).map(
|
|
1370
|
+
(x, D) => k && (g.includes(x) || g.includes(v[D + 1])) ? D : -1
|
|
1371
|
+
).filter((x) => x >= 0), [ee, B] = U({}), te = A(
|
|
1372
|
+
(x, D) => B((P) => ({ ...P, [x]: D })),
|
|
1371
1373
|
[]
|
|
1372
1374
|
), Q = v.join("|");
|
|
1373
1375
|
se(() => {
|
|
1374
|
-
B((
|
|
1375
|
-
const
|
|
1376
|
-
return
|
|
1376
|
+
B((x) => {
|
|
1377
|
+
const D = Object.keys(x).filter((P) => v.includes(P));
|
|
1378
|
+
return D.length === Object.keys(x).length ? x : Object.fromEntries(D.map((P) => [P, x[P]]));
|
|
1377
1379
|
});
|
|
1378
1380
|
}, [Q]);
|
|
1379
1381
|
const Y = {
|
|
@@ -1389,12 +1391,12 @@ const an = (e, t, a) => {
|
|
|
1389
1391
|
};
|
|
1390
1392
|
return /* @__PURE__ */ G($e, { children: [
|
|
1391
1393
|
b.length === 1 ? /* @__PURE__ */ E(
|
|
1392
|
-
|
|
1394
|
+
je,
|
|
1393
1395
|
{
|
|
1394
1396
|
panel: b[0],
|
|
1395
1397
|
isPrimary: !0,
|
|
1396
1398
|
search: ee[b[0].id],
|
|
1397
|
-
onSearchChange: (
|
|
1399
|
+
onSearchChange: (x) => te(b[0].id, x),
|
|
1398
1400
|
...Y
|
|
1399
1401
|
}
|
|
1400
1402
|
) : /* @__PURE__ */ E(hn, { ref: n, $deadGutters: Z, children: /* @__PURE__ */ E(
|
|
@@ -1407,24 +1409,24 @@ const an = (e, t, a) => {
|
|
|
1407
1409
|
height: ae,
|
|
1408
1410
|
overflow: "hidden"
|
|
1409
1411
|
},
|
|
1410
|
-
children: b.map((
|
|
1412
|
+
children: b.map((x, D) => /* @__PURE__ */ E(
|
|
1411
1413
|
tt,
|
|
1412
1414
|
{
|
|
1413
|
-
size: H[
|
|
1415
|
+
size: H[D],
|
|
1414
1416
|
minSize: oe,
|
|
1415
1417
|
style: { overflow: "hidden" },
|
|
1416
1418
|
children: /* @__PURE__ */ E(
|
|
1417
|
-
|
|
1419
|
+
je,
|
|
1418
1420
|
{
|
|
1419
|
-
panel:
|
|
1420
|
-
isPrimary:
|
|
1421
|
-
search: ee[
|
|
1422
|
-
onSearchChange: (P) => te(
|
|
1421
|
+
panel: x,
|
|
1422
|
+
isPrimary: D === 0,
|
|
1423
|
+
search: ee[x.id],
|
|
1424
|
+
onSearchChange: (P) => te(x.id, P),
|
|
1423
1425
|
...Y
|
|
1424
1426
|
}
|
|
1425
1427
|
)
|
|
1426
1428
|
},
|
|
1427
|
-
|
|
1429
|
+
x.id
|
|
1428
1430
|
))
|
|
1429
1431
|
},
|
|
1430
1432
|
q
|
|
@@ -1444,15 +1446,15 @@ export {
|
|
|
1444
1446
|
_t as S,
|
|
1445
1447
|
Be as a,
|
|
1446
1448
|
Me as b,
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
+
jt as c,
|
|
1450
|
+
Zn as d,
|
|
1449
1451
|
Kt as e,
|
|
1450
|
-
|
|
1452
|
+
Ft as f,
|
|
1451
1453
|
Ae as g,
|
|
1452
1454
|
sn as h,
|
|
1453
1455
|
Zt as i,
|
|
1454
1456
|
$t as j,
|
|
1455
|
-
|
|
1457
|
+
Xn as k,
|
|
1456
1458
|
ln as l,
|
|
1457
1459
|
Nt as r,
|
|
1458
1460
|
Wt as u
|