@ynput/ayon-frontend-shared 0.7.6 → 0.8.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 +361 -355
- package/dist/Feed.es.js +1 -1
- package/dist/ListTable.es.js +18 -18
- package/dist/NewEntity.es.js +30 -30
- package/dist/ProjectTreeTable.es.js +984 -974
- package/dist/ProjectsTable.es.js +3 -3
- package/dist/Slicer.es.js +53 -50
- package/dist/Views.es.js +150 -151
- package/dist/api.es.js +166 -165
- package/dist/chunks/Actions.es.js +9 -10
- package/dist/chunks/ColumnDropIndicator.es.js +2 -2
- package/dist/chunks/ColumnHeaderMenuUI.es.js +3 -4
- package/dist/chunks/DeleteEntitiesConfirmDialog.es.js +2 -2
- package/dist/chunks/DetailsDialog.es.js +3 -3
- package/dist/chunks/EmptyPlaceholder.es.js +7 -7
- package/dist/chunks/EntityPath.es.js +38 -39
- package/dist/chunks/EntityPickerDialog.es.js +65 -66
- package/dist/chunks/EntityTooltip.es.js +18 -19
- package/dist/chunks/Feed.es.js +1381 -1355
- package/dist/chunks/FilmstripEntityCard.es.js +5201 -0
- package/dist/chunks/FilterErrorActions.es.js +2 -3
- package/dist/chunks/GroupSettingsFallback.es.js +2 -2
- package/dist/chunks/Menu.es.js +52 -53
- package/dist/chunks/MetaWidget.es.js +1948 -1875
- package/dist/chunks/ProjectFoldersContext.es.js +40 -40
- package/dist/chunks/RepresentationsList.es.js +1 -1
- package/dist/chunks/ReviewablesSelector.es.js +759 -742
- package/dist/chunks/SimpleTable.es.js +2 -1
- package/dist/chunks/Slicer.es.js +49 -50
- package/dist/chunks/TableExportContextInstance.es.js +600 -402
- package/dist/chunks/TableSettingsFallback.es.js +3 -4
- package/dist/chunks/ThumbnailSimple.es.js +114 -99
- package/dist/chunks/VideoPlayer.es.js +8 -9
- package/dist/chunks/Watchers.es.js +928 -871
- package/dist/chunks/expandRelativeDates.es.js +1 -1
- package/dist/chunks/getThumbnailUrl.es.js +33 -21
- package/dist/chunks/getUris.es.js +1580 -1610
- package/dist/chunks/queryFilterToClientFilter.es.js +1 -1
- package/dist/chunks/realtimeUpdatesUtils.es.js +15 -15
- package/dist/chunks/searchTerms.es.js +773 -696
- package/dist/chunks/useAttributeEnums.es.js +22 -22
- package/dist/chunks/useDateRangeFilter.es.js +1 -1
- package/dist/chunks/useHierarchySelection.es.js +3 -4
- package/dist/chunks/useLoadModule.es.js +3 -4
- package/dist/components.es.js +475 -467
- package/dist/context.es.js +615 -540
- package/dist/hooks.es.js +193 -171
- package/dist/index.es.js +2 -2
- package/dist/types/Actions.d.ts +10 -8
- package/dist/types/DetailsPanel.d.ts +54 -76
- package/dist/types/EntityPickerDialog.d.ts +12 -6
- package/dist/types/Feed.d.ts +24 -24
- package/dist/types/ListTable.d.ts +33 -27
- package/dist/types/NewEntity.d.ts +26 -39
- package/dist/types/ProjectTreeTable.d.ts +199 -195
- package/dist/types/ProjectsTable.d.ts +6 -6
- package/dist/types/RepresentationsList.d.ts +4 -0
- package/dist/types/Slicer.d.ts +63 -246
- package/dist/types/Views.d.ts +71 -298
- package/dist/types/api.d.ts +3164 -2363
- package/dist/types/components.d.ts +327 -474
- package/dist/types/context.d.ts +285 -572
- package/dist/types/hooks.d.ts +76 -47
- package/dist/types/index.d.ts +6 -0
- package/dist/types/util.d.ts +141 -120
- package/dist/util.es.js +71 -68
- package/package.json +6 -6
- package/dist/chunks/EntityUpdatesContext.es.js +0 -61
- package/dist/chunks/PlayableIcon.es.js +0 -5020
- package/dist/chunks/viewUpdateHelper.es.js +0 -153
|
@@ -1,31 +1,30 @@
|
|
|
1
1
|
import { jsx as U, jsxs as Be, Fragment as hn } from "react/jsx-runtime";
|
|
2
|
-
import ot, { useCallback as q, useSyncExternalStore as
|
|
2
|
+
import ot, { useCallback as q, useSyncExternalStore as Ys, useMemo as H, useEffect as $e, useState as Ge, useRef as He, useLayoutEffect as Js, createElement as Zs } from "react";
|
|
3
3
|
import { useVirtualizer as cs } from "@tanstack/react-virtual";
|
|
4
|
-
import { functionalUpdate as Lt, useReactTable as
|
|
4
|
+
import { functionalUpdate as Lt, useReactTable as eo, filterFns as to, getSortedRowModel as no, getExpandedRowModel as so, getFilteredRowModel as oo, getCoreRowModel as ro, flexRender as Cn } from "@tanstack/react-table";
|
|
5
5
|
import Ye from "clsx";
|
|
6
|
-
import { v as ds, w as
|
|
7
|
-
import { B as
|
|
8
|
-
import { c as
|
|
9
|
-
import { SEARCH_FILTER_ID as
|
|
6
|
+
import { v as ds, w as io, x as ao, y as Un, z as lo, F as Ct, a as dt, G as co, H as us, I as uo, b as Ke, J as ut, K as cn, N as dn, O as et, p as de, Q as fo, R as qt, V as po, W as mo, X as go, Y as yo, Z as ho, P as bo, _ as Io, $ as fs, a0 as Me, a1 as wo, a2 as Co, g as Tn, a3 as To, a4 as Tt, a5 as nn, U as Gn, a6 as So, a7 as bn, a8 as Dt, a9 as vo, aa as Eo, C as xo, ab as ko, ac as Sn, ad as Ro, ae as Ao, af as Po, ag as Do, ah as Lo, ai as ps, aj as vn, ak as Oo, al as _o, am as Fo, an as No, ao as Wn, ap as Mo, aq as ms, ar as $o, as as gs, j as jn, at as Vo, au as zo, av as ys, aw as Bo, ax as Uo, ay as Go, az as Wo } from "./chunks/MetaWidget.es.js";
|
|
7
|
+
import { B as rc, aA as ic, aB as ac, aC as lc, aD as cc, aE as dc, aF as uc, D as fc, aG as pc, aH as mc, aI as gc, aJ as yc, aK as hc, aL as bc, aM as Ic, E as wc, aN as Cc, aO as Tc, aP as Sc, aQ as vc, aR as Ec, aS as xc, M as kc, aT as Rc, aU as Ac, aV as Pc, aW as Dc, aX as Lc, aY as Oc, aZ as _c, a_ as Fc, a$ as Nc, b0 as Mc, b1 as $c, t as Vc, T as zc, b2 as Bc, b3 as Uc, b4 as Gc, b5 as Wc, b6 as jc, b7 as Hc, b8 as Kc, b9 as qc, ba as Qc, bb as Xc, bc as Yc, bd as Jc, be as Zc, bf as ed, bg as td, bh as nd, bi as sd, bj as od, bk as rd, bl as id, bm as ad, bn as ld, bo as cd, bp as dd, bq as ud, br as fd, bs as pd, bt as md, bu as gd, i as yd, bv as hd, h as bd, bw as Id } from "./chunks/MetaWidget.es.js";
|
|
8
|
+
import { c as jo, T as Ho, g as rn, d as an, H as Hn } from "./chunks/addonColumnTags.es.js";
|
|
9
|
+
import { SEARCH_FILTER_ID as Ko, Icon as Ft, applyMixedChange as qo, Button as un } from "@ynput/ayon-react-components";
|
|
10
10
|
import "@module-federation/enhanced/runtime";
|
|
11
|
-
import { menuItemsAt as
|
|
11
|
+
import { menuItemsAt as Qo, usePiece as Xo, reportContributionError as Yo, onTableColumnRefresh as Jo } from "@ynput/ayon-addon/host";
|
|
12
12
|
import { toast as Fe } from "react-toastify";
|
|
13
|
-
import { aH as Kn,
|
|
14
|
-
import { aZ as
|
|
15
|
-
import {
|
|
13
|
+
import { aH as Kn, bs as hs } from "./chunks/searchTerms.es.js";
|
|
14
|
+
import { aZ as Zo, aK as er, dB as bs, dK as en, c2 as tr, cA as nr, c3 as sr, ch as or, bC as qn, ct as rr, bR as ir, ar, dM as lr, cY as cr } from "./chunks/getUris.es.js";
|
|
15
|
+
import { dN as Cd, dL as Td } from "./chunks/getUris.es.js";
|
|
16
16
|
import "primereact/confirmdialog";
|
|
17
|
-
import {
|
|
18
|
-
import { isEqual as wt, debounce as gr, throttle as yr } from "lodash";
|
|
17
|
+
import { isEqual as wt, debounce as dr, throttle as ur } from "lodash";
|
|
19
18
|
import "uuid";
|
|
20
|
-
import { v as
|
|
21
|
-
import { C as
|
|
19
|
+
import { v as Is, g as In, R as pe, D as je, e as fr, M as En } from "./chunks/realtimeUpdatesUtils.es.js";
|
|
20
|
+
import { C as vd, L as Ed, l as xd, W as kd, m as Rd } from "./chunks/realtimeUpdatesUtils.es.js";
|
|
22
21
|
import "axios";
|
|
22
|
+
import { q as Ue, c as pr, ae as mr, am as gr, s as yr, u as ws, b as hr, a9 as br } from "./chunks/TableExportContextInstance.es.js";
|
|
23
23
|
import "semver";
|
|
24
24
|
import "./chunks/ContextMenuContextInstance.es.js";
|
|
25
25
|
import { createPortal as sn } from "react-dom";
|
|
26
|
-
import "react-redux";
|
|
27
26
|
import "react-router-dom";
|
|
28
|
-
import {
|
|
27
|
+
import { a9 as Ir, T as wr } from "./chunks/FilmstripEntityCard.es.js";
|
|
29
28
|
import "lexical";
|
|
30
29
|
import "@lexical/markdown";
|
|
31
30
|
import "match-sorter";
|
|
@@ -37,33 +36,34 @@ import "@lexical/selection";
|
|
|
37
36
|
import "@lexical/utils";
|
|
38
37
|
import "@lexical/react/LexicalBlockWithAlignableContents";
|
|
39
38
|
import "@lexical/react/LexicalDecoratorBlockNode";
|
|
40
|
-
import { addonColumnId as
|
|
41
|
-
import { i as
|
|
42
|
-
import { a as
|
|
43
|
-
import
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
46
|
-
import {
|
|
39
|
+
import { addonColumnId as Cr, ADDON_COLUMN_PREFIX as Tr, useContributions as Cs, prefetchPiece as wn, runContribution as Sr, ContributionView as vr } from "@ynput/ayon-addon";
|
|
40
|
+
import { i as Er, u as xr, T as Qn } from "./chunks/ColumnDropIndicator.es.js";
|
|
41
|
+
import { a as Pd, b as Dd, c as Ld } from "./chunks/ColumnDropIndicator.es.js";
|
|
42
|
+
import "react-redux";
|
|
43
|
+
import { C as kr } from "./chunks/ColumnHeaderMenuUI.es.js";
|
|
44
|
+
import { useSensors as Rr, useSensor as fn, MouseSensor as Ar, TouchSensor as Pr, KeyboardSensor as Dr, closestCenter as Xn, DndContext as Lr, useDndMonitor as Or, DragOverlay as Ts, useDndContext as _r } from "@dnd-kit/core";
|
|
45
|
+
import { arrayMove as Yn, SortableContext as Ss, verticalListSortingStrategy as Fr, horizontalListSortingStrategy as Nr, useSortable as vs } from "@dnd-kit/sortable";
|
|
46
|
+
import { l as Mr } from "./chunks/sortLists.es.js";
|
|
47
47
|
import { E as pn } from "./chunks/EmptyPlaceholder.es.js";
|
|
48
48
|
import "./chunks/EmptyPlaceholderFlex.styled.es.js";
|
|
49
|
-
import { I as
|
|
50
|
-
import { F as
|
|
51
|
-
import { u as
|
|
52
|
-
import { u as
|
|
49
|
+
import { I as $r } from "./chunks/InfoMessage.es.js";
|
|
50
|
+
import { F as Vr } from "./chunks/FilterErrorActions.es.js";
|
|
51
|
+
import { u as zr } from "./chunks/useLoadModule.es.js";
|
|
52
|
+
import { u as Br } from "./chunks/useCreateContextMenu.es.js";
|
|
53
53
|
import { a as Qt, K as Xt } from "./chunks/platform.es.js";
|
|
54
|
-
import { u as
|
|
54
|
+
import { u as Ur } from "./chunks/useHierarchySelection.es.js";
|
|
55
55
|
import { n as It } from "./chunks/entityDefinitions.es.js";
|
|
56
56
|
import { CSS as Es } from "@dnd-kit/utilities";
|
|
57
|
-
import { u as
|
|
58
|
-
import { a as
|
|
59
|
-
import { g as
|
|
60
|
-
import { a as
|
|
61
|
-
import { c as
|
|
62
|
-
import { e as
|
|
63
|
-
import { c as
|
|
64
|
-
import { r as
|
|
65
|
-
import { u as
|
|
66
|
-
import { g as
|
|
57
|
+
import { u as Gr } from "./chunks/useAttributeEnums.es.js";
|
|
58
|
+
import { a as _d } from "./chunks/useAttributeEnums.es.js";
|
|
59
|
+
import { g as Wr, A as jr } from "./chunks/SimpleTable.es.js";
|
|
60
|
+
import { a as Hr } from "./chunks/queryFilterToClientFilter.es.js";
|
|
61
|
+
import { c as Nd, q as Md, t as $d, b as Vd } from "./chunks/queryFilterToClientFilter.es.js";
|
|
62
|
+
import { e as Kr } from "./chunks/expandRelativeDates.es.js";
|
|
63
|
+
import { c as Bd, i as Ud, r as Gd } from "./chunks/expandRelativeDates.es.js";
|
|
64
|
+
import { r as qr, a as Qr } from "./chunks/refreshActiveAndPurgeOthers.es.js";
|
|
65
|
+
import { u as Xr } from "./chunks/useGroupedPagination.es.js";
|
|
66
|
+
import { g as Yr } from "./chunks/getGroupByDataType.es.js";
|
|
67
67
|
const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => ({
|
|
68
68
|
id: `loading-${n}-${s}`,
|
|
69
69
|
primary: {
|
|
@@ -75,14 +75,14 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
75
75
|
attrib: t
|
|
76
76
|
},
|
|
77
77
|
isLoading: !0
|
|
78
|
-
})),
|
|
78
|
+
})), Jr = (e = 10) => Array(e).fill(null).map((t, n) => ({
|
|
79
79
|
name: `loading-attribute${n}`,
|
|
80
80
|
scope: ["folder", "task"],
|
|
81
81
|
data: {
|
|
82
82
|
type: "string"
|
|
83
83
|
},
|
|
84
84
|
position: n
|
|
85
|
-
})),
|
|
85
|
+
})), Zr = ({
|
|
86
86
|
expandedFoldersTasks: e,
|
|
87
87
|
expandedParentIds: t,
|
|
88
88
|
foldersMap: n
|
|
@@ -94,11 +94,11 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
94
94
|
d.has(i) || h.add(i);
|
|
95
95
|
const p = {};
|
|
96
96
|
for (const i of h) {
|
|
97
|
-
const
|
|
98
|
-
|
|
97
|
+
const l = n.get(i);
|
|
98
|
+
l && (p[i] = l.taskNames?.length || 0);
|
|
99
99
|
}
|
|
100
100
|
return p;
|
|
101
|
-
},
|
|
101
|
+
}, ei = ({
|
|
102
102
|
users: e,
|
|
103
103
|
statuses: t,
|
|
104
104
|
folderTypes: n,
|
|
@@ -108,41 +108,41 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
108
108
|
scopes: h
|
|
109
109
|
}) => {
|
|
110
110
|
const p = (i) => t.filter(
|
|
111
|
-
(
|
|
112
|
-
).map(({ name:
|
|
113
|
-
value:
|
|
114
|
-
label:
|
|
111
|
+
(l) => !l.scope || i.some((a) => l.scope?.includes(a))
|
|
112
|
+
).map(({ name: l, color: a, icon: b, scope: m }) => ({
|
|
113
|
+
value: l,
|
|
114
|
+
label: l,
|
|
115
115
|
color: a,
|
|
116
116
|
icon: b,
|
|
117
117
|
scope: m
|
|
118
118
|
}));
|
|
119
119
|
return {
|
|
120
120
|
// sorted by the label the dropdown shows, not the username
|
|
121
|
-
assignee: e.map(({ name: i, fullName:
|
|
121
|
+
assignee: e.map(({ name: i, fullName: l, hidden: a }) => ({
|
|
122
122
|
value: i,
|
|
123
|
-
label:
|
|
123
|
+
label: l?.trim() || i,
|
|
124
124
|
icon: `/api/users/${i}/avatar`,
|
|
125
125
|
hidden: a
|
|
126
|
-
})).sort((i,
|
|
126
|
+
})).sort((i, l) => Mr.compare(i.label, l.label)),
|
|
127
127
|
status: p(h),
|
|
128
128
|
folderStatus: p(["folder"]),
|
|
129
129
|
taskStatus: p(["task"]),
|
|
130
|
-
tag: d.map(({ name: i, color:
|
|
131
|
-
folderType: n.map(({ name: i, icon:
|
|
130
|
+
tag: d.map(({ name: i, color: l }) => ({ value: i, label: i, color: l })),
|
|
131
|
+
folderType: n.map(({ name: i, icon: l, color: a }) => ({
|
|
132
132
|
value: i,
|
|
133
133
|
label: i,
|
|
134
|
-
icon:
|
|
134
|
+
icon: l,
|
|
135
135
|
color: a
|
|
136
136
|
})),
|
|
137
|
-
taskType: o.map(({ name: i, icon:
|
|
138
|
-
productType: s.map(({ name: i, icon:
|
|
137
|
+
taskType: o.map(({ name: i, icon: l, color: a }) => ({ value: i, label: i, icon: l, color: a })),
|
|
138
|
+
productType: s.map(({ name: i, icon: l, color: a }) => ({
|
|
139
139
|
value: i,
|
|
140
140
|
label: i,
|
|
141
|
-
icon:
|
|
141
|
+
icon: l,
|
|
142
142
|
color: a
|
|
143
143
|
}))
|
|
144
144
|
};
|
|
145
|
-
},
|
|
145
|
+
}, xs = ["createdAt", "updatedAt", "createdBy", "updatedBy"], ti = {
|
|
146
146
|
name: ["name"],
|
|
147
147
|
label: ["label"],
|
|
148
148
|
status: ["status"],
|
|
@@ -154,40 +154,43 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
154
154
|
taskType: ["taskType", "task_type"],
|
|
155
155
|
productType: ["productType", "product_type"],
|
|
156
156
|
author: ["author"]
|
|
157
|
-
},
|
|
158
|
-
let o = e.filter((
|
|
157
|
+
}, ni = (e, t, n = []) => {
|
|
158
|
+
let o = e.filter((l) => l.readOnly).map((l) => l.name), s;
|
|
159
159
|
const d = [];
|
|
160
160
|
let h = !1, p = !1;
|
|
161
161
|
if (t) {
|
|
162
|
-
const
|
|
163
|
-
Object.entries(
|
|
162
|
+
const l = new Set(t), a = (b) => b.some((m) => l.has(m));
|
|
163
|
+
Object.entries(ti).forEach(([b, m]) => {
|
|
164
164
|
a(m) || (d.push(b), b === "folderType" && (h = !0), b === "taskType" && (p = !0));
|
|
165
165
|
});
|
|
166
166
|
}
|
|
167
|
-
if (n?.includes("attrib") ? (o = e.filter((
|
|
168
|
-
...o.map((
|
|
167
|
+
if (n?.includes("attrib") ? (o = e.filter((l) => l.builtin || l.readOnly).map((l) => l.name), s = /* @__PURE__ */ new Set([
|
|
168
|
+
...o.map((l) => "attrib_" + l),
|
|
169
169
|
// Add the read-only attribute columns to the set
|
|
170
170
|
...d,
|
|
171
171
|
// Also include read-only built-in fields
|
|
172
172
|
...n || []
|
|
173
173
|
// Add any other specified readOnly columns
|
|
174
174
|
])) : (s = /* @__PURE__ */ new Set([
|
|
175
|
-
...o.map((
|
|
175
|
+
...o.map((l) => "attrib_" + l),
|
|
176
176
|
// Add readOnly attribute columns to the set
|
|
177
177
|
...d,
|
|
178
178
|
// Add read-only built-in fields to the set (field ids match column ids)
|
|
179
179
|
...n || []
|
|
180
180
|
// Add any other specified readOnly columns
|
|
181
|
-
]), n && n.forEach((
|
|
182
|
-
if (
|
|
183
|
-
const a =
|
|
181
|
+
]), n && n.forEach((l) => {
|
|
182
|
+
if (l.startsWith("attrib_")) {
|
|
183
|
+
const a = l.replace("attrib_", "");
|
|
184
184
|
e.find((b) => b.name === a) && !o.includes(a) && o.push(a);
|
|
185
185
|
}
|
|
186
186
|
})), h && p && (s.add("subType"), o.includes("subType") || o.push("subType")), d.length)
|
|
187
|
-
for (const
|
|
188
|
-
o.includes(
|
|
189
|
-
|
|
190
|
-
|
|
187
|
+
for (const l of d)
|
|
188
|
+
o.includes(l) || o.push(l);
|
|
189
|
+
o.push(...ds);
|
|
190
|
+
for (const l of xs)
|
|
191
|
+
s.add(l), o.push(l);
|
|
192
|
+
return { readOnlyColumns: Array.from(s), readOnlyAttribs: o };
|
|
193
|
+
}, si = {
|
|
191
194
|
status: "statuses",
|
|
192
195
|
folderType: "folderTypes",
|
|
193
196
|
taskType: "taskTypes"
|
|
@@ -198,7 +201,7 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
198
201
|
const d = s.split(" ");
|
|
199
202
|
n.push({ values: d, colIds: o });
|
|
200
203
|
}), n;
|
|
201
|
-
},
|
|
204
|
+
}, oi = (e, t) => {
|
|
202
205
|
if (t === "array")
|
|
203
206
|
try {
|
|
204
207
|
if (e === "")
|
|
@@ -219,7 +222,7 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
219
222
|
return e.toLowerCase() === "true" || e === "1" || e.toLowerCase() === "yes";
|
|
220
223
|
}
|
|
221
224
|
return e;
|
|
222
|
-
},
|
|
225
|
+
}, ri = ["assignees", "status", "subType"], ii = (e) => {
|
|
223
226
|
const {
|
|
224
227
|
colId: t,
|
|
225
228
|
isFolder: n,
|
|
@@ -229,15 +232,15 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
229
232
|
columnReadOnly: h,
|
|
230
233
|
rowIndex: p,
|
|
231
234
|
colIndex: i,
|
|
232
|
-
isSingleCellValue:
|
|
235
|
+
isSingleCellValue: l,
|
|
233
236
|
attribFields: a = []
|
|
234
237
|
} = e;
|
|
235
238
|
if (!o) return !0;
|
|
236
239
|
if (h.includes(t.replace("attrib_", "")))
|
|
237
240
|
return ze(`This column is read-only: "${t}". Paste operation cancelled.`), !1;
|
|
238
241
|
if (t.startsWith("link_"))
|
|
239
|
-
return o.split(",").map((f) => f.trim()).every((f) =>
|
|
240
|
-
if (
|
|
242
|
+
return o.split(",").map((f) => f.trim()).every((f) => Is(f)) ? !0 : (ze(`Invalid link id format: "${o}". Paste operation cancelled.`), !1);
|
|
243
|
+
if (ri.includes(t)) {
|
|
241
244
|
let r = t;
|
|
242
245
|
t === "assignees" ? r = "assignee" : t === "subType" ? r = n ? "folderType" : "taskType" : t === "status" && (r = "status");
|
|
243
246
|
const u = d[r] || [];
|
|
@@ -245,13 +248,13 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
245
248
|
return !0;
|
|
246
249
|
const f = o.split(",").map((O) => O.trim()), v = [];
|
|
247
250
|
for (const O of f) {
|
|
248
|
-
const R = u.find((
|
|
251
|
+
const R = u.find((c) => c.value === O || c.label === O);
|
|
249
252
|
if (R) {
|
|
250
253
|
v.push(String(R.value));
|
|
251
254
|
continue;
|
|
252
255
|
}
|
|
253
256
|
const y = u.find(
|
|
254
|
-
(
|
|
257
|
+
(c) => String(c.value).toLowerCase() === O.toLowerCase() || String(c.label).toLowerCase() === O.toLowerCase()
|
|
255
258
|
);
|
|
256
259
|
if (y) {
|
|
257
260
|
v.push(String(y.value));
|
|
@@ -265,7 +268,7 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
265
268
|
), !1;
|
|
266
269
|
const S = v.join(", ");
|
|
267
270
|
if (S !== o)
|
|
268
|
-
if (
|
|
271
|
+
if (l)
|
|
269
272
|
s[0].values[0] = S;
|
|
270
273
|
else {
|
|
271
274
|
const O = p % s.length, R = i % s[O].values.length;
|
|
@@ -296,11 +299,11 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
296
299
|
if (u.data.type === "string" && u.data.enum && u.data.enum.length > 0) {
|
|
297
300
|
const f = o.split(",").map((R) => R.trim()), { validValues: v, hasInvalidValues: S } = f.reduce(
|
|
298
301
|
(R, y) => {
|
|
299
|
-
const
|
|
302
|
+
const c = u.data.enum.find(
|
|
300
303
|
(k) => k.value === y || k.label === y
|
|
301
304
|
);
|
|
302
|
-
if (
|
|
303
|
-
return R.validValues.push(String(
|
|
305
|
+
if (c)
|
|
306
|
+
return R.validValues.push(String(c.value)), R;
|
|
304
307
|
const E = u.data.enum.find(
|
|
305
308
|
(k) => String(k.value).toLowerCase() === y.toLowerCase() || String(k.label).toLowerCase() === y.toLowerCase()
|
|
306
309
|
);
|
|
@@ -314,7 +317,7 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
314
317
|
), !1;
|
|
315
318
|
const O = v.join(", ");
|
|
316
319
|
if (O !== o)
|
|
317
|
-
if (
|
|
320
|
+
if (l)
|
|
318
321
|
s[0].values[0] = O;
|
|
319
322
|
else {
|
|
320
323
|
const R = p % s.length, y = i % s[R].values.length;
|
|
@@ -325,7 +328,7 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
325
328
|
}
|
|
326
329
|
}
|
|
327
330
|
let b = t === "subType" ? n ? "folderType" : "taskType" : t;
|
|
328
|
-
if (b =
|
|
331
|
+
if (b = si[b] || b, !(b in d)) return !0;
|
|
329
332
|
const m = d[b];
|
|
330
333
|
if (!Array.isArray(m) || m.length === 0) return !0;
|
|
331
334
|
const C = o.split(",").map((r) => r.trim()), { validValues: w, hasInvalidValues: T } = C.reduce(
|
|
@@ -344,14 +347,14 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
344
347
|
return ze(`Invalid ${b === "folderType" || b === "taskType" ? `${n ? "folder" : "task"} type` : b} value: "${o}". Paste operation cancelled.`), !1;
|
|
345
348
|
const I = w.join(", ");
|
|
346
349
|
if (I !== o)
|
|
347
|
-
if (
|
|
350
|
+
if (l)
|
|
348
351
|
s[0].values[0] = I;
|
|
349
352
|
else {
|
|
350
353
|
const r = p % s.length, u = i % s[r].values.length;
|
|
351
354
|
s[r].values[u] = I;
|
|
352
355
|
}
|
|
353
356
|
return !0;
|
|
354
|
-
},
|
|
357
|
+
}, ai = (e, t, n) => e.map((s) => [
|
|
355
358
|
t || "",
|
|
356
359
|
n || "",
|
|
357
360
|
s.label || "",
|
|
@@ -361,7 +364,7 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
361
364
|
(s.assignees || []).join(", "),
|
|
362
365
|
s.isDone ? "Done" : "Todo"
|
|
363
366
|
]).map((s) => s.join(" ")).join(`
|
|
364
|
-
`),
|
|
367
|
+
`), vl = (e, t, n) => [
|
|
365
368
|
t || "",
|
|
366
369
|
n || "",
|
|
367
370
|
e.label || "",
|
|
@@ -378,19 +381,19 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
378
381
|
return (n.includes("taskid") && n.includes("taskname") && n.includes("label") && n.includes("name") && n.includes("start date") && n.includes("end date") && n.includes("assignees") && n.includes("status") ? t.slice(1) : t).map((h) => {
|
|
379
382
|
const p = h.split(" ");
|
|
380
383
|
if (p.length < 6) return null;
|
|
381
|
-
let i,
|
|
382
|
-
p.length >= 8 ? ([i,
|
|
384
|
+
let i, l, a, b, m, C, w, T;
|
|
385
|
+
p.length >= 8 ? ([i, l, a, b, m, C, w, T] = p, i = i || void 0, l = l || void 0) : [a, b, m, C, w, T] = p.slice(0, 6);
|
|
383
386
|
const I = w ? w.split(",").map((f) => f.trim()).filter(Boolean) : [], r = T?.toLowerCase().trim() === "done", u = {
|
|
384
387
|
label: a || "",
|
|
385
388
|
name: b || "",
|
|
386
389
|
assignees: I,
|
|
387
390
|
isDone: r
|
|
388
391
|
};
|
|
389
|
-
return i && (u.taskId = i),
|
|
392
|
+
return i && (u.taskId = i), l && (u.taskName = l), m && (u.startDate = m), C && (u.endDate = C), u;
|
|
390
393
|
}).filter(
|
|
391
394
|
(h) => h !== null
|
|
392
395
|
);
|
|
393
|
-
},
|
|
396
|
+
}, li = (e) => {
|
|
394
397
|
const t = e.trim().split(`
|
|
395
398
|
`);
|
|
396
399
|
if (t.length === 0) return !1;
|
|
@@ -406,53 +409,53 @@ const Ot = (e = 50, t = {}, n = "table") => new Array(e).fill(0).map((o, s) => (
|
|
|
406
409
|
return d === "done" || d === "todo";
|
|
407
410
|
}
|
|
408
411
|
return !1;
|
|
409
|
-
},
|
|
412
|
+
}, ci = (e) => {
|
|
410
413
|
let t = e.replace(/[^a-zA-Z0-9_\.\-]/g, "_");
|
|
411
414
|
return t.length > 0 && !/^[a-zA-Z0-9_]/.test(t) && (t = "s_" + t), t.length > 0 && !/[a-zA-Z0-9_]$/.test(t) && (t = t + "_"), t || (t = "subtask"), t;
|
|
412
|
-
}, Yt = (e) => String(e).padStart(2, "0"),
|
|
415
|
+
}, Yt = (e) => String(e).padStart(2, "0"), di = (e) => {
|
|
413
416
|
if (!e) return "";
|
|
414
417
|
const t = new Date(e);
|
|
415
418
|
return isNaN(t.getTime()) ? "" : `${Yt(t.getDate())}/${Yt(t.getMonth() + 1)}/${t.getFullYear()} ${Yt(
|
|
416
419
|
t.getHours()
|
|
417
420
|
)}:${Yt(t.getMinutes())}`;
|
|
418
|
-
},
|
|
421
|
+
}, ui = (e) => e.replace(/ /gi, " ").replace(/</gi, "<").replace(/>/gi, ">").replace(/"/gi, '"').replace(/'/gi, "'").replace(/&/gi, "&"), fi = (e) => {
|
|
419
422
|
if (!e) return "";
|
|
420
423
|
let t = e;
|
|
421
424
|
return t = t.replace(/<br\s*\/?>/gi, " "), t = t.replace(/!\[[^\]]*\]\([^)]*\)/g, ""), t = t.replace(
|
|
422
425
|
/\[([^\]]*)\]\(([^)]*)\)/g,
|
|
423
|
-
(n, o, s) =>
|
|
424
|
-
), t = t.replace(/```([\s\S]*?)```/g, "$1"), t = t.replace(/`+/g, ""), t = t.replace(/^\s{0,3}#{1,6}\s+/gm, ""), t = t.replace(/^\s*[-=]{2,}\s*$/gm, ""), t = t.replace(/^\s*>\s?/gm, ""), t = t.replace(/^\s*[-*+]\s+\[[ xX]\]\s?/gm, ""), t = t.replace(/^\s*[-*+]\s+/gm, ""), t = t.replace(/^\s*\d+\.\s+/gm, ""), t = t.replace(/\*\*|__|~~/g, ""), t =
|
|
425
|
-
},
|
|
426
|
-
(t) => [
|
|
426
|
+
(n, o, s) => Ir.includes(String(s).split(":")[0]) ? String(o).replace(/^@/, "") : o
|
|
427
|
+
), t = t.replace(/```([\s\S]*?)```/g, "$1"), t = t.replace(/`+/g, ""), t = t.replace(/^\s{0,3}#{1,6}\s+/gm, ""), t = t.replace(/^\s*[-=]{2,}\s*$/gm, ""), t = t.replace(/^\s*>\s?/gm, ""), t = t.replace(/^\s*[-*+]\s+\[[ xX]\]\s?/gm, ""), t = t.replace(/^\s*[-*+]\s+/gm, ""), t = t.replace(/^\s*\d+\.\s+/gm, ""), t = t.replace(/\*\*|__|~~/g, ""), t = ui(t), t = t.replace(/[<>]/g, ""), t.replace(/\s+/g, " ").trim();
|
|
428
|
+
}, pi = (e = []) => e.map(
|
|
429
|
+
(t) => [fi(t.body), t.author, di(t.createdAt)].filter(Boolean).join(" - ")
|
|
427
430
|
).join(`
|
|
428
|
-
`), Zn = (e) => e.startsWith(
|
|
431
|
+
`), Zn = (e) => e.startsWith(Tr), es = (e) => Cr(e.addon.name, e.id), ks = (e, t) => !e.pages?.length || e.pages.includes(t), mi = "stale", St = /* @__PURE__ */ new Map(), tn = /* @__PURE__ */ new Map(), Rs = (e, t) => `${e}/${t}`, As = (e, t) => {
|
|
429
432
|
for (const n of t)
|
|
430
|
-
tn.get(
|
|
433
|
+
tn.get(Rs(e, n))?.forEach((o) => o());
|
|
431
434
|
}, _t = (e, t) => St.get(e)?.get(t), ts = (e, t) => {
|
|
432
435
|
const n = St.get(e) || /* @__PURE__ */ new Map();
|
|
433
|
-
St.set(e, n), Object.entries(t).forEach(([o, s]) => n.set(o, s)),
|
|
434
|
-
},
|
|
436
|
+
St.set(e, n), Object.entries(t).forEach(([o, s]) => n.set(o, s)), As(e, Object.keys(t));
|
|
437
|
+
}, gi = (e) => {
|
|
435
438
|
const t = St.get(e);
|
|
436
|
-
St.delete(e), t &&
|
|
437
|
-
},
|
|
439
|
+
St.delete(e), t && As(e, t.keys());
|
|
440
|
+
}, yi = (e) => {
|
|
438
441
|
const t = St.get(e);
|
|
439
|
-
t && t.forEach((n, o) => t.set(o, { ...n, version:
|
|
440
|
-
},
|
|
442
|
+
t && t.forEach((n, o) => t.set(o, { ...n, version: mi }));
|
|
443
|
+
}, hi = (e, t) => {
|
|
441
444
|
const n = q(
|
|
442
445
|
(o) => {
|
|
443
|
-
const s =
|
|
446
|
+
const s = Rs(e, t), d = tn.get(s) || /* @__PURE__ */ new Set();
|
|
444
447
|
return tn.set(s, d.add(o)), () => {
|
|
445
448
|
d.delete(o), d.size || tn.delete(s);
|
|
446
449
|
};
|
|
447
450
|
},
|
|
448
451
|
[e, t]
|
|
449
452
|
);
|
|
450
|
-
return
|
|
451
|
-
},
|
|
453
|
+
return Ys(n, () => _t(e, t));
|
|
454
|
+
}, bi = (e, t) => {
|
|
452
455
|
const n = _t(e, t)?.value;
|
|
453
456
|
return Array.isArray(n) ? n.filter((o) => typeof o != "object").join(", ") : typeof n == "string" || typeof n == "number" || typeof n == "boolean" ? String(n) : "";
|
|
454
457
|
}, ns = 100;
|
|
455
|
-
function
|
|
458
|
+
function Ii({
|
|
456
459
|
foldersMap: e,
|
|
457
460
|
tasksMap: t,
|
|
458
461
|
rows: n,
|
|
@@ -462,10 +465,10 @@ function hi({
|
|
|
462
465
|
isFlatFolderView: h = !1,
|
|
463
466
|
showEmptyFolders: p = !1,
|
|
464
467
|
loadingTasks: i = {},
|
|
465
|
-
isLoadingMore:
|
|
468
|
+
isLoadingMore: l = !1,
|
|
466
469
|
selectedFolders: a = []
|
|
467
470
|
}) {
|
|
468
|
-
const b = Ue(), m =
|
|
471
|
+
const b = Ue(), m = io({ projectInfo: b }), C = H(() => JSON.stringify(s), [s]), w = H(() => new Set(
|
|
469
472
|
Object.entries(s).filter(([u, f]) => f).map(([u]) => u)
|
|
470
473
|
), [C]), { childToParentMap: T, parentToChildrenMap: I } = H(() => {
|
|
471
474
|
const u = /* @__PURE__ */ new Map(), f = /* @__PURE__ */ new Map();
|
|
@@ -495,17 +498,17 @@ function hi({
|
|
|
495
498
|
}, [e, I, w]);
|
|
496
499
|
return H(() => {
|
|
497
500
|
const u = (R, y) => {
|
|
498
|
-
const
|
|
499
|
-
return E.primary.icon =
|
|
501
|
+
const c = m("task", R.taskType), E = ao(R, e.get(y || R.folderId));
|
|
502
|
+
return E.primary.icon = c?.icon || null, E.primary.color = c?.color || null, E.primary.links = Un(R.links, "task", b.anatomy), E.subRows = [], E;
|
|
500
503
|
}, f = (R) => {
|
|
501
|
-
const y = m("folder", R.folderType),
|
|
502
|
-
return
|
|
504
|
+
const y = m("folder", R.folderType), c = lo(R);
|
|
505
|
+
return c.primary.icon = y?.icon || null, c.primary.color = y?.color || null, c.primary.links = Un(R.links, "folder", b.anatomy), c.subRows = [], c;
|
|
503
506
|
}, v = () => {
|
|
504
507
|
const R = [];
|
|
505
508
|
for (const y of a) {
|
|
506
509
|
if (e.has(y)) continue;
|
|
507
|
-
const
|
|
508
|
-
for (const E of
|
|
510
|
+
const c = o.get(y) || [];
|
|
511
|
+
for (const E of c) {
|
|
509
512
|
const k = t.get(E);
|
|
510
513
|
k && R.push(u(k));
|
|
511
514
|
}
|
|
@@ -516,8 +519,8 @@ function hi({
|
|
|
516
519
|
const R = [];
|
|
517
520
|
for (const y of e.values()) {
|
|
518
521
|
if (!y?.id) continue;
|
|
519
|
-
const
|
|
520
|
-
if (!p && !
|
|
522
|
+
const c = y.hasTasks ?? o.has(y.id);
|
|
523
|
+
if (!p && !c) continue;
|
|
521
524
|
const E = f(y);
|
|
522
525
|
if (E.childOnlyMatch = y.childOnlyMatch || !1, w.has(y.id)) {
|
|
523
526
|
const F = (o.get(y.id) || []).flatMap((V) => t.get(V) || []);
|
|
@@ -540,11 +543,11 @@ function hi({
|
|
|
540
543
|
y.id && R.push(u(y));
|
|
541
544
|
for (const y of n || [])
|
|
542
545
|
R.push(y);
|
|
543
|
-
if (
|
|
546
|
+
if (l) {
|
|
544
547
|
const y = ns;
|
|
545
548
|
{
|
|
546
|
-
const
|
|
547
|
-
R.push(...
|
|
549
|
+
const c = Ot(y, {}, "more");
|
|
550
|
+
R.push(...c);
|
|
548
551
|
}
|
|
549
552
|
}
|
|
550
553
|
return R;
|
|
@@ -553,8 +556,8 @@ function hi({
|
|
|
553
556
|
for (const R of r) {
|
|
554
557
|
const y = e.get(R);
|
|
555
558
|
if (!y) continue;
|
|
556
|
-
const
|
|
557
|
-
if (
|
|
559
|
+
const c = f(y);
|
|
560
|
+
if (c.childOnlyMatch = y.childOnlyMatch || !1, S.set(R, c), (!y.parentId || !e.has(y.parentId)) && O.push(c), w.has(R)) {
|
|
558
561
|
const k = (o.get(R) || []).flatMap((F) => t.get(F) || []);
|
|
559
562
|
if (k.length || i[R]) {
|
|
560
563
|
const F = new Array(k.length);
|
|
@@ -567,17 +570,17 @@ function hi({
|
|
|
567
570
|
F.push(...g);
|
|
568
571
|
}
|
|
569
572
|
}
|
|
570
|
-
|
|
573
|
+
c.subRows = F;
|
|
571
574
|
}
|
|
572
575
|
}
|
|
573
576
|
}
|
|
574
577
|
for (const R of r) {
|
|
575
578
|
const y = T.get(R);
|
|
576
579
|
if (!y || !w.has(y)) continue;
|
|
577
|
-
const
|
|
578
|
-
!
|
|
580
|
+
const c = S.get(R), E = S.get(y);
|
|
581
|
+
!c || !E || E.subRows?.push(c);
|
|
579
582
|
}
|
|
580
|
-
if (O.push(...v()), d &&
|
|
583
|
+
if (O.push(...v()), d && l) {
|
|
581
584
|
const R = ns;
|
|
582
585
|
O.push(...Ot(R, {}, "more"));
|
|
583
586
|
}
|
|
@@ -596,11 +599,11 @@ function hi({
|
|
|
596
599
|
h,
|
|
597
600
|
p,
|
|
598
601
|
i,
|
|
599
|
-
|
|
602
|
+
l,
|
|
600
603
|
a
|
|
601
604
|
]);
|
|
602
605
|
}
|
|
603
|
-
function
|
|
606
|
+
function wi({
|
|
604
607
|
tasksMap: e,
|
|
605
608
|
entitiesMap: t,
|
|
606
609
|
tasksByFolderMap: n,
|
|
@@ -651,7 +654,7 @@ function bi({
|
|
|
651
654
|
return w;
|
|
652
655
|
},
|
|
653
656
|
[t]
|
|
654
|
-
),
|
|
657
|
+
), l = q(
|
|
655
658
|
(C) => {
|
|
656
659
|
const w = e?.get(C);
|
|
657
660
|
if (!w || !w.folderId) return [];
|
|
@@ -694,7 +697,7 @@ function bi({
|
|
|
694
697
|
if (f.length)
|
|
695
698
|
for (const v of f) {
|
|
696
699
|
const S = r.filter(
|
|
697
|
-
([y]) => !v.ownAttrib?.includes(y) && d?.find((
|
|
700
|
+
([y]) => !v.ownAttrib?.includes(y) && d?.find((c) => c.name === y)?.data?.inherit
|
|
698
701
|
), O = r.filter(
|
|
699
702
|
([y]) => v.ownAttrib?.includes(y)
|
|
700
703
|
);
|
|
@@ -702,14 +705,14 @@ function bi({
|
|
|
702
705
|
T.get(v.id).add(y);
|
|
703
706
|
}));
|
|
704
707
|
const R = S.filter(([y]) => {
|
|
705
|
-
const
|
|
706
|
-
for (const E of
|
|
708
|
+
const c = v.entityType === "task" ? l(v.id) : i(v.id);
|
|
709
|
+
for (const E of c)
|
|
707
710
|
if (T.has(E) && T.get(E).has(y))
|
|
708
711
|
return !1;
|
|
709
712
|
return !0;
|
|
710
713
|
});
|
|
711
714
|
if (R.length) {
|
|
712
|
-
const y = w.findIndex((
|
|
715
|
+
const y = w.findIndex((c) => c.entityId === v.id);
|
|
713
716
|
y !== -1 ? w[y].attrib = {
|
|
714
717
|
...w[y].attrib,
|
|
715
718
|
...Object.fromEntries(R)
|
|
@@ -723,7 +726,7 @@ function bi({
|
|
|
723
726
|
}
|
|
724
727
|
return w;
|
|
725
728
|
},
|
|
726
|
-
[p, e,
|
|
729
|
+
[p, e, l, i]
|
|
727
730
|
), m = q(
|
|
728
731
|
(C, w, T) => {
|
|
729
732
|
const I = o(C);
|
|
@@ -749,7 +752,7 @@ function bi({
|
|
|
749
752
|
getAncestorsOf: i
|
|
750
753
|
};
|
|
751
754
|
}
|
|
752
|
-
const
|
|
755
|
+
const El = ({
|
|
753
756
|
children: e,
|
|
754
757
|
foldersMap: t,
|
|
755
758
|
tableRows: n,
|
|
@@ -759,7 +762,7 @@ const Sl = ({
|
|
|
759
762
|
selectedFolders: h,
|
|
760
763
|
expanded: p,
|
|
761
764
|
showHierarchy: i,
|
|
762
|
-
loadingTasks:
|
|
765
|
+
loadingTasks: l,
|
|
763
766
|
isLoadingMore: a,
|
|
764
767
|
isLoading: b,
|
|
765
768
|
error: m,
|
|
@@ -775,7 +778,7 @@ const Sl = ({
|
|
|
775
778
|
groupCounts: O,
|
|
776
779
|
groupCountsComplete: R,
|
|
777
780
|
queryFilters: y,
|
|
778
|
-
updateShowHierarchy:
|
|
781
|
+
updateShowHierarchy: c,
|
|
779
782
|
toggleExpanded: E,
|
|
780
783
|
updateExpanded: k,
|
|
781
784
|
fetchNextPage: F,
|
|
@@ -783,7 +786,7 @@ const Sl = ({
|
|
|
783
786
|
setExpanded: g,
|
|
784
787
|
contextMenuItems: x,
|
|
785
788
|
powerpack: D,
|
|
786
|
-
modules:
|
|
789
|
+
modules: N,
|
|
787
790
|
loadingLinksEntityIds: z,
|
|
788
791
|
groupByConfig: B,
|
|
789
792
|
hierarchyOptions: X,
|
|
@@ -804,9 +807,9 @@ const Sl = ({
|
|
|
804
807
|
dispatch: A
|
|
805
808
|
}) => {
|
|
806
809
|
const { attrib: K } = Ue(), {
|
|
807
|
-
groupBy:
|
|
810
|
+
groupBy: M,
|
|
808
811
|
groupByConfig: { showEmpty: Y = !0 } = {}
|
|
809
|
-
} = dt(), ee =
|
|
812
|
+
} = dt(), ee = Ii({
|
|
810
813
|
foldersMap: t,
|
|
811
814
|
tasksMap: o,
|
|
812
815
|
rows: n,
|
|
@@ -815,10 +818,10 @@ const Sl = ({
|
|
|
815
818
|
showHierarchy: i,
|
|
816
819
|
isFlatFolderView: L,
|
|
817
820
|
showEmptyFolders: Y,
|
|
818
|
-
loadingTasks:
|
|
821
|
+
loadingTasks: l,
|
|
819
822
|
isLoadingMore: a,
|
|
820
823
|
selectedFolders: h
|
|
821
|
-
}), se = L ? void 0 : S ||
|
|
824
|
+
}), se = L ? void 0 : S || M, ne = co({
|
|
822
825
|
entities: s,
|
|
823
826
|
entityType: B?.entityType || "unknown",
|
|
824
827
|
groups: f,
|
|
@@ -863,7 +866,7 @@ const Sl = ({
|
|
|
863
866
|
findInheritedValueFromAncestors: J,
|
|
864
867
|
findNonInheritedValues: _,
|
|
865
868
|
getAncestorsOf: j
|
|
866
|
-
} =
|
|
869
|
+
} = wi({
|
|
867
870
|
entitiesMap: s,
|
|
868
871
|
tasksMap: o,
|
|
869
872
|
tasksByFolderMap: d,
|
|
@@ -893,7 +896,7 @@ const Sl = ({
|
|
|
893
896
|
[p, g]
|
|
894
897
|
);
|
|
895
898
|
return /* @__PURE__ */ U(
|
|
896
|
-
|
|
899
|
+
uo.Provider,
|
|
897
900
|
{
|
|
898
901
|
value: {
|
|
899
902
|
// from this context
|
|
@@ -919,7 +922,7 @@ const Sl = ({
|
|
|
919
922
|
loadingLinksEntityIds: z,
|
|
920
923
|
// hierarchy
|
|
921
924
|
showHierarchy: i,
|
|
922
|
-
updateShowHierarchy:
|
|
925
|
+
updateShowHierarchy: c,
|
|
923
926
|
hierarchyOptions: X,
|
|
924
927
|
hierarchyActive: P,
|
|
925
928
|
// flat folder view
|
|
@@ -942,7 +945,7 @@ const Sl = ({
|
|
|
942
945
|
contextMenuItems: x,
|
|
943
946
|
// powerpack context
|
|
944
947
|
powerpack: D,
|
|
945
|
-
modules:
|
|
948
|
+
modules: N,
|
|
946
949
|
// SubtasksManager
|
|
947
950
|
SubtasksManager: G,
|
|
948
951
|
// player
|
|
@@ -962,25 +965,25 @@ const Sl = ({
|
|
|
962
965
|
children: e
|
|
963
966
|
}
|
|
964
967
|
);
|
|
965
|
-
},
|
|
966
|
-
const { projectName: t } = Ue(), { getEntityById: n } = Ke(), o = t, { history: s } = ut(), [d] =
|
|
968
|
+
}, Ci = (e) => {
|
|
969
|
+
const { projectName: t } = Ue(), { getEntityById: n } = Ke(), o = t, { history: s } = ut(), [d] = Zo(), [h] = er();
|
|
967
970
|
return { pasteTableLinks: q(
|
|
968
971
|
async (i) => {
|
|
969
972
|
if (!o || !i.length) return;
|
|
970
|
-
const
|
|
973
|
+
const l = /* @__PURE__ */ new Map();
|
|
971
974
|
for (const C of i) {
|
|
972
975
|
const w = `${C.sourceEntityId}-${C.linkType}-${C.direction}`;
|
|
973
|
-
|
|
976
|
+
l.has(w) || l.set(w, []), l.get(w).push(C);
|
|
974
977
|
}
|
|
975
978
|
const a = [], b = [], m = [];
|
|
976
|
-
for (const [, C] of
|
|
979
|
+
for (const [, C] of l) {
|
|
977
980
|
const { sourceEntityId: w } = C[0], T = /* @__PURE__ */ new Set();
|
|
978
981
|
if (C.forEach((I) => I.targetEntityIds.forEach((r) => T.add(r))), T.has(w)) {
|
|
979
982
|
Fe.error("You can't link an entity to itself");
|
|
980
983
|
return;
|
|
981
984
|
}
|
|
982
985
|
}
|
|
983
|
-
for (const [C, w] of
|
|
986
|
+
for (const [C, w] of l) {
|
|
984
987
|
const T = w[0], {
|
|
985
988
|
sourceEntityId: I,
|
|
986
989
|
sourceEntityType: r,
|
|
@@ -992,12 +995,12 @@ const Sl = ({
|
|
|
992
995
|
w.forEach((k) => {
|
|
993
996
|
k.targetEntityIds.forEach((F) => O.add(F));
|
|
994
997
|
});
|
|
995
|
-
const R = [], y = [],
|
|
996
|
-
if (!
|
|
998
|
+
const R = [], y = [], c = n(I);
|
|
999
|
+
if (!c) {
|
|
997
1000
|
console.warn(`Entity not found: ${I}`);
|
|
998
1001
|
continue;
|
|
999
1002
|
}
|
|
1000
|
-
const E =
|
|
1003
|
+
const E = c.links;
|
|
1001
1004
|
if (S === "replace") {
|
|
1002
1005
|
if (Array.isArray(E))
|
|
1003
1006
|
for (const k of E)
|
|
@@ -1082,61 +1085,61 @@ const Sl = ({
|
|
|
1082
1085
|
},
|
|
1083
1086
|
[o, n, d, h, s]
|
|
1084
1087
|
) };
|
|
1085
|
-
},
|
|
1088
|
+
}, Ti = [
|
|
1086
1089
|
{ value: ",", label: "Comma" },
|
|
1087
1090
|
{ value: ";", label: "Semicolon" },
|
|
1088
1091
|
{ value: " ", label: "Tab" }
|
|
1089
|
-
],
|
|
1092
|
+
], Si = (e, t) => {
|
|
1090
1093
|
const n = (/* @__PURE__ */ new Date()).toLocaleDateString("sv");
|
|
1091
1094
|
return `${e}-selection-${n}.${t === " " ? "tsv" : "csv"}`;
|
|
1092
|
-
},
|
|
1095
|
+
}, vi = (e, t) => {
|
|
1093
1096
|
const n = document.createElement("a");
|
|
1094
1097
|
n.href = e, n.download = t, n.click(), setTimeout(() => URL.revokeObjectURL(e), 1e3);
|
|
1095
|
-
},
|
|
1098
|
+
}, Ei = /* @__PURE__ */ new Set([
|
|
1096
1099
|
"version",
|
|
1097
1100
|
"version_entity",
|
|
1098
1101
|
"product",
|
|
1099
1102
|
"productBaseType",
|
|
1100
1103
|
"task_entity"
|
|
1101
|
-
]),
|
|
1104
|
+
]), xi = {
|
|
1102
1105
|
folder_entity: "folder",
|
|
1103
1106
|
version_entity: "versionName"
|
|
1104
|
-
},
|
|
1107
|
+
}, ki = ({
|
|
1105
1108
|
children: e,
|
|
1106
1109
|
entitiesMap: t,
|
|
1107
1110
|
columnEnums: n,
|
|
1108
1111
|
columnReadOnly: o,
|
|
1109
1112
|
visibleColumns: s
|
|
1110
1113
|
}) => {
|
|
1111
|
-
const { selectedCells: d, gridMap: h, focusedCellId: p } = et(), { updateEntities: i, history:
|
|
1112
|
-
const
|
|
1114
|
+
const { selectedCells: d, gridMap: h, focusedCellId: p } = et(), { updateEntities: i, history: l } = ut(), { pasteTableLinks: a } = Ci(), { getEntityById: b, attribFields: m, tableData: C, isRowReadOnly: w } = Ke(), T = H(() => {
|
|
1115
|
+
const c = /* @__PURE__ */ new Map(), E = (k) => {
|
|
1113
1116
|
for (const F of k)
|
|
1114
|
-
|
|
1117
|
+
c.set(F.id, F), F.subRows?.length && E(F.subRows);
|
|
1115
1118
|
};
|
|
1116
|
-
return E(C || []),
|
|
1119
|
+
return E(C || []), c;
|
|
1117
1120
|
}, [C]), { projectName: I } = Ue(), [r] = bs(), u = q(
|
|
1118
|
-
async (
|
|
1121
|
+
async (c, E) => {
|
|
1119
1122
|
const { headers: k, fullRow: F, delimiter: V = " " } = E || {}, g = (x) => x.includes(V) || /[\n\r"]/.test(x) ? `"${x.replace(/"/g, '""')}"` : x;
|
|
1120
1123
|
try {
|
|
1121
1124
|
const x = s.map((P) => P.id).filter((P) => P !== pe), D = /* @__PURE__ */ new Map();
|
|
1122
|
-
|
|
1125
|
+
c.forEach((P) => {
|
|
1123
1126
|
const L = de(P);
|
|
1124
1127
|
if (!L) return;
|
|
1125
1128
|
const { rowId: G, colId: te } = L;
|
|
1126
1129
|
te === pe || !x.includes(te) || (D.has(G) || D.set(G, /* @__PURE__ */ new Set()), D.get(G)?.add(te));
|
|
1127
|
-
}), F &&
|
|
1130
|
+
}), F && c.filter(
|
|
1128
1131
|
(L) => de(L)?.rowId && de(L)?.colId === pe
|
|
1129
1132
|
).map((L) => de(L)?.rowId).forEach((L) => {
|
|
1130
1133
|
D.has(L) || D.set(L, /* @__PURE__ */ new Set()), Array.from(h.colIdToIndex.keys()).forEach((te) => {
|
|
1131
1134
|
D.get(L)?.add(te);
|
|
1132
1135
|
});
|
|
1133
1136
|
});
|
|
1134
|
-
const
|
|
1137
|
+
const N = Array.from(D.keys()).sort((P, L) => {
|
|
1135
1138
|
const G = h.rowIdToIndex.get(P) ?? 1 / 0, te = h.rowIdToIndex.get(L) ?? 1 / 0;
|
|
1136
1139
|
return G - te;
|
|
1137
1140
|
});
|
|
1138
1141
|
let z = "";
|
|
1139
|
-
const B =
|
|
1142
|
+
const B = N[0];
|
|
1140
1143
|
if (!B) return "";
|
|
1141
1144
|
const X = Array.from(D.get(B) || []).sort((P, L) => {
|
|
1142
1145
|
const G = h.colIdToIndex.get(P) ?? 1 / 0, te = h.colIdToIndex.get(L) ?? 1 / 0;
|
|
@@ -1149,7 +1152,7 @@ const Sl = ({
|
|
|
1149
1152
|
z += P.join(V) + `
|
|
1150
1153
|
`;
|
|
1151
1154
|
}
|
|
1152
|
-
for (const P of
|
|
1155
|
+
for (const P of N) {
|
|
1153
1156
|
const L = b(P);
|
|
1154
1157
|
if (!L) {
|
|
1155
1158
|
console.warn(`Entity not found for rowId: ${P}`);
|
|
@@ -1162,28 +1165,28 @@ const Sl = ({
|
|
|
1162
1165
|
for (const re of be) {
|
|
1163
1166
|
let ae = "";
|
|
1164
1167
|
if (Zn(re))
|
|
1165
|
-
ae =
|
|
1168
|
+
ae = bi(re, L.entityId || L.id);
|
|
1166
1169
|
else if (re.startsWith("link_"))
|
|
1167
|
-
ae =
|
|
1170
|
+
ae = fo(L.links, re);
|
|
1168
1171
|
else if (re === "subtasks") {
|
|
1169
1172
|
const W = qt(L, re) || [];
|
|
1170
|
-
ae =
|
|
1173
|
+
ae = ai(W, L.id, L.name);
|
|
1171
1174
|
} else if (re === "comments") {
|
|
1172
1175
|
const W = qt(L, "latestComments") || [];
|
|
1173
|
-
ae =
|
|
1176
|
+
ae = pi(W);
|
|
1174
1177
|
} else {
|
|
1175
|
-
const W =
|
|
1178
|
+
const W = xi[re] || re;
|
|
1176
1179
|
let $ = re === "task_entity" ? G?.parents?.task?.label || G?.parents?.task?.name || L.task?.label || L.task?.name : qt(L, W);
|
|
1177
1180
|
if (re === "folder_entity") {
|
|
1178
|
-
const A = G &&
|
|
1181
|
+
const A = G && po(G);
|
|
1179
1182
|
if (A)
|
|
1180
1183
|
$ = A;
|
|
1181
1184
|
else if (typeof $ != "string") {
|
|
1182
|
-
const K = $ || L.product?.folder,
|
|
1183
|
-
$ = K?.label || K?.name ||
|
|
1185
|
+
const K = $ || L.product?.folder, M = "parents" in L ? L.parents : void 0;
|
|
1186
|
+
$ = K?.label || K?.name || M?.[M.length - 1] || "";
|
|
1184
1187
|
}
|
|
1185
1188
|
}
|
|
1186
|
-
if (G && (
|
|
1189
|
+
if (G && (Ei.has(re) || $ === void 0 || $ === null || $ === "" || typeof $ == "object")) {
|
|
1187
1190
|
const A = qt(G, W);
|
|
1188
1191
|
A != null && A !== "" && ($ = A);
|
|
1189
1192
|
}
|
|
@@ -1217,14 +1220,14 @@ const Sl = ({
|
|
|
1217
1220
|
T
|
|
1218
1221
|
]
|
|
1219
1222
|
), f = async () => {
|
|
1220
|
-
const
|
|
1221
|
-
if (!
|
|
1222
|
-
const E = Jn(
|
|
1223
|
-
return E.length === 0 ? !1 : E.every((k) => k.values.every((F) => F.split(",").every((V) =>
|
|
1223
|
+
const c = await O();
|
|
1224
|
+
if (!c) return !1;
|
|
1225
|
+
const E = Jn(c);
|
|
1226
|
+
return E.length === 0 ? !1 : E.every((k) => k.values.every((F) => F.split(",").every((V) => Is(V))));
|
|
1224
1227
|
}, v = q(
|
|
1225
|
-
async (
|
|
1226
|
-
if (
|
|
1227
|
-
const k = await u(
|
|
1228
|
+
async (c, E) => {
|
|
1229
|
+
if (c = c || Array.from(d), !c.length) return;
|
|
1230
|
+
const k = await u(c, { fullRow: E });
|
|
1228
1231
|
if (k) {
|
|
1229
1232
|
if (!navigator.clipboard) {
|
|
1230
1233
|
ze("Clipboard API not supported in this browser.");
|
|
@@ -1243,14 +1246,14 @@ const Sl = ({
|
|
|
1243
1246
|
},
|
|
1244
1247
|
[d, t, h]
|
|
1245
1248
|
), S = q(
|
|
1246
|
-
async (
|
|
1247
|
-
if (
|
|
1248
|
-
const F =
|
|
1249
|
+
async (c, E, k) => {
|
|
1250
|
+
if (c = c || Array.from(d), !c.length) return;
|
|
1251
|
+
const F = c.some((V) => de(V)?.colId === pe);
|
|
1249
1252
|
try {
|
|
1250
|
-
const V = await u(
|
|
1253
|
+
const V = await u(c, { headers: !0, fullRow: F, delimiter: k });
|
|
1251
1254
|
if (!V) return;
|
|
1252
1255
|
const g = k === " " ? "text/tab-separated-values" : "text/csv", x = URL.createObjectURL(new Blob([V], { type: g }));
|
|
1253
|
-
|
|
1256
|
+
vi(x, Si(E, k));
|
|
1254
1257
|
} catch (V) {
|
|
1255
1258
|
console.error("Failed to export selection:", V);
|
|
1256
1259
|
}
|
|
@@ -1265,39 +1268,39 @@ const Sl = ({
|
|
|
1265
1268
|
ze("Clipboard operations require a secure HTTPS context.");
|
|
1266
1269
|
return;
|
|
1267
1270
|
}
|
|
1268
|
-
let
|
|
1271
|
+
let c;
|
|
1269
1272
|
try {
|
|
1270
|
-
return
|
|
1273
|
+
return c = await navigator.clipboard.readText(), c;
|
|
1271
1274
|
} catch (E) {
|
|
1272
1275
|
ze(`Failed to read from clipboard: ${E.message}`);
|
|
1273
1276
|
return;
|
|
1274
1277
|
}
|
|
1275
1278
|
}, R = q(
|
|
1276
|
-
async (
|
|
1279
|
+
async (c, E) => {
|
|
1277
1280
|
const { method: k = "replace" } = E || {};
|
|
1278
|
-
if (!
|
|
1281
|
+
if (!c.length) return;
|
|
1279
1282
|
const F = await O();
|
|
1280
1283
|
if (!F) return;
|
|
1281
1284
|
let V = !1, g = F;
|
|
1282
|
-
|
|
1285
|
+
li(F) && (V = !0);
|
|
1283
1286
|
const x = Jn(F);
|
|
1284
1287
|
if (!x.length) return;
|
|
1285
|
-
const D = x.length === 1 && x[0].values.length === 1,
|
|
1288
|
+
const D = x.length === 1 && x[0].values.length === 1, N = s.map((W) => W.id).filter((W) => W !== pe), z = (W, $, A) => {
|
|
1286
1289
|
const K = {};
|
|
1287
|
-
return A && A.length > 0 ? A.forEach((
|
|
1290
|
+
return A && A.length > 0 ? A.forEach((M, Y) => {
|
|
1288
1291
|
const ee = $.find(
|
|
1289
|
-
(se) => se ===
|
|
1292
|
+
(se) => se === M || se.replace("attrib_", "") === M || se === `attrib_${M}` || se.toLowerCase() === M.toLowerCase()
|
|
1290
1293
|
);
|
|
1291
1294
|
ee && Y < W.values.length && (K[ee] = W.values[Y]);
|
|
1292
|
-
}) : $.forEach((
|
|
1293
|
-
Y < W.values.length && (K[
|
|
1295
|
+
}) : $.forEach((M, Y) => {
|
|
1296
|
+
Y < W.values.length && (K[M] = W.values[Y]);
|
|
1294
1297
|
}), K;
|
|
1295
1298
|
}, B = x[0]?.colIds || void 0, X = /* @__PURE__ */ new Map();
|
|
1296
|
-
if (Array.from(
|
|
1299
|
+
if (Array.from(c).forEach((W) => {
|
|
1297
1300
|
const $ = de(W);
|
|
1298
1301
|
if (!$) return;
|
|
1299
1302
|
const { rowId: A, colId: K } = $;
|
|
1300
|
-
K === pe || !
|
|
1303
|
+
K === pe || !N.includes(K) || Zn(K) || w(A) || (X.has(A) || X.set(A, /* @__PURE__ */ new Set()), X.get(A)?.add(K));
|
|
1301
1304
|
}), !X.size) {
|
|
1302
1305
|
ze("These rows are read-only. Paste operation cancelled.");
|
|
1303
1306
|
return;
|
|
@@ -1310,11 +1313,11 @@ const Sl = ({
|
|
|
1310
1313
|
return A - K;
|
|
1311
1314
|
});
|
|
1312
1315
|
for (let W = 0; W < P.length; W++) {
|
|
1313
|
-
const $ = P[W], A = Ct($, t)?.entityType, K = A === "folder",
|
|
1316
|
+
const $ = P[W], A = Ct($, t)?.entityType, K = A === "folder", M = A === "product" || A === "version", Y = W % x.length, ee = x[Y], se = D ? { [G[0]]: x[0].values[0] } : z(ee, G, B);
|
|
1314
1317
|
for (const ne of G) {
|
|
1315
|
-
if (ne === "subType" &&
|
|
1318
|
+
if (ne === "subType" && M) continue;
|
|
1316
1319
|
const Te = se[ne] || "";
|
|
1317
|
-
if (!
|
|
1320
|
+
if (!ii({
|
|
1318
1321
|
colId: ne,
|
|
1319
1322
|
isFolder: K,
|
|
1320
1323
|
pasteValue: Te,
|
|
@@ -1383,7 +1386,7 @@ const Sl = ({
|
|
|
1383
1386
|
if (!ve || ve.length === 0) continue;
|
|
1384
1387
|
const De = ve.map((J, _) => ({
|
|
1385
1388
|
id: In(),
|
|
1386
|
-
name:
|
|
1389
|
+
name: ci(J.name || J.label || `Subtask ${_ + 1}`),
|
|
1387
1390
|
label: J.label || "",
|
|
1388
1391
|
assignees: J.assignees || [],
|
|
1389
1392
|
description: J.label || "",
|
|
@@ -1418,35 +1421,35 @@ const Sl = ({
|
|
|
1418
1421
|
}
|
|
1419
1422
|
continue;
|
|
1420
1423
|
}
|
|
1421
|
-
let A = !1, K = !1,
|
|
1424
|
+
let A = !1, K = !1, M = "string";
|
|
1422
1425
|
if (P.length > 0) {
|
|
1423
1426
|
const Y = P[0];
|
|
1424
1427
|
if (b(Y))
|
|
1425
1428
|
if (A = $.startsWith("attrib_"), K = $.startsWith("link_"), $ === "status" || $ === "subType")
|
|
1426
|
-
|
|
1429
|
+
M = "string", A = !1;
|
|
1427
1430
|
else if ($ === "tags" || $ === "assignees")
|
|
1428
|
-
|
|
1431
|
+
M = "array";
|
|
1429
1432
|
else if (A) {
|
|
1430
1433
|
const se = $.replace("attrib_", ""), ne = m.find((Te) => Te.name === se);
|
|
1431
1434
|
if (ne)
|
|
1432
1435
|
switch (ne.data.type) {
|
|
1433
1436
|
case "boolean":
|
|
1434
|
-
|
|
1437
|
+
M = "boolean";
|
|
1435
1438
|
break;
|
|
1436
1439
|
case "float":
|
|
1437
1440
|
case "integer":
|
|
1438
|
-
|
|
1441
|
+
M = "number";
|
|
1439
1442
|
break;
|
|
1440
1443
|
case "list_of_strings":
|
|
1441
1444
|
case "list_of_any":
|
|
1442
1445
|
case "list_of_integers":
|
|
1443
1446
|
case "list_of_submodels":
|
|
1444
|
-
|
|
1447
|
+
M = "array";
|
|
1445
1448
|
break;
|
|
1446
1449
|
default:
|
|
1447
|
-
|
|
1450
|
+
M = "string";
|
|
1448
1451
|
}
|
|
1449
|
-
} else K && (
|
|
1452
|
+
} else K && (M = "array");
|
|
1450
1453
|
}
|
|
1451
1454
|
for (let Y = 0; Y < P.length; Y++) {
|
|
1452
1455
|
const ee = P[Y], se = Ct(ee, t)?.entityType, ne = se === "folder";
|
|
@@ -1474,7 +1477,7 @@ const Sl = ({
|
|
|
1474
1477
|
let Re = $.split("_").pop() || $;
|
|
1475
1478
|
if ($ === "subType" && (se === "product" || se === "version" || (Re = ne ? "folderType" : "taskType", A = !1, !Te)))
|
|
1476
1479
|
continue;
|
|
1477
|
-
const Ie =
|
|
1480
|
+
const Ie = oi(Te, M), Ce = b(ee)?.entityId || ee, Se = `${ee}-${se}`;
|
|
1478
1481
|
!te.has(Se) && se && te.set(Se, {
|
|
1479
1482
|
rowId: ee,
|
|
1480
1483
|
id: Ce,
|
|
@@ -1510,15 +1513,15 @@ const Sl = ({
|
|
|
1510
1513
|
isAttrib: !0
|
|
1511
1514
|
});
|
|
1512
1515
|
}), Object.entries(W.links).forEach(([$, A]) => {
|
|
1513
|
-
const [K,
|
|
1516
|
+
const [K, M] = $.split("_"), Y = K.split("|");
|
|
1514
1517
|
if (Y.length >= 3) {
|
|
1515
|
-
const ee = Y[0], se = Y[1], ne = Y[2], Te = `${ee}|${se}|${ne}`, Re =
|
|
1518
|
+
const ee = Y[0], se = Y[1], ne = Y[2], Te = `${ee}|${se}|${ne}`, Re = M === "out" ? ne : se, Ie = `${W.id}-${Te}-${M}`;
|
|
1516
1519
|
he.set(Ie, {
|
|
1517
1520
|
rowId: W.rowId,
|
|
1518
1521
|
sourceEntityId: W.id,
|
|
1519
1522
|
sourceEntityType: W.type,
|
|
1520
1523
|
linkType: Te,
|
|
1521
|
-
direction:
|
|
1524
|
+
direction: M,
|
|
1522
1525
|
targetEntityType: Re,
|
|
1523
1526
|
operation: k,
|
|
1524
1527
|
targetEntityIds: Array.isArray(A) ? A : []
|
|
@@ -1536,15 +1539,15 @@ const Sl = ({
|
|
|
1536
1539
|
});
|
|
1537
1540
|
const Ae = [];
|
|
1538
1541
|
if (be.length > 0 && Ae.push(i(be)), re.length > 0 && Ae.push(a(re)), ae.length > 0) {
|
|
1539
|
-
|
|
1540
|
-
const
|
|
1541
|
-
r({ projectName: I, taskId: $, subtasks:
|
|
1542
|
+
l && ae.forEach(({ taskId: $, subtasks: A, previousSubtasks: K }) => {
|
|
1543
|
+
const M = K || [], Y = A || [], ee = () => {
|
|
1544
|
+
r({ projectName: I, taskId: $, subtasks: M }).unwrap().catch(() => {
|
|
1542
1545
|
});
|
|
1543
1546
|
}, se = () => {
|
|
1544
1547
|
r({ projectName: I, taskId: $, subtasks: Y }).unwrap().catch(() => {
|
|
1545
1548
|
});
|
|
1546
1549
|
};
|
|
1547
|
-
|
|
1550
|
+
l.pushHistory([ee], [se]);
|
|
1548
1551
|
});
|
|
1549
1552
|
const W = ae.map(
|
|
1550
1553
|
({ taskId: $, subtasks: A }) => r({ projectName: I, taskId: $, subtasks: A }).unwrap()
|
|
@@ -1571,11 +1574,11 @@ const Sl = ({
|
|
|
1571
1574
|
m,
|
|
1572
1575
|
I,
|
|
1573
1576
|
r,
|
|
1574
|
-
|
|
1577
|
+
l
|
|
1575
1578
|
]
|
|
1576
1579
|
);
|
|
1577
1580
|
$e(() => {
|
|
1578
|
-
const
|
|
1581
|
+
const c = async (E) => {
|
|
1579
1582
|
if ((E.ctrlKey || E.metaKey) && E.key === "c") {
|
|
1580
1583
|
const k = document.activeElement, F = k?.closest("table") !== null || k?.closest(".table-container") !== null || k?.tagName === "TD" || k?.tagName === "TH", V = k?.tagName === "INPUT" || k?.tagName === "TEXTAREA" || k?.isContentEditable;
|
|
1581
1584
|
if ((window.getSelection()?.toString().length ?? !1) && !F || V && !F)
|
|
@@ -1595,8 +1598,8 @@ const Sl = ({
|
|
|
1595
1598
|
});
|
|
1596
1599
|
}
|
|
1597
1600
|
};
|
|
1598
|
-
return window.addEventListener("keydown",
|
|
1599
|
-
window.removeEventListener("keydown",
|
|
1601
|
+
return window.addEventListener("keydown", c), () => {
|
|
1602
|
+
window.removeEventListener("keydown", c);
|
|
1600
1603
|
};
|
|
1601
1604
|
}, [v, R]);
|
|
1602
1605
|
const y = H(
|
|
@@ -1607,15 +1610,15 @@ const Sl = ({
|
|
|
1607
1610
|
}),
|
|
1608
1611
|
[v, R]
|
|
1609
1612
|
);
|
|
1610
|
-
return /* @__PURE__ */ U(
|
|
1611
|
-
},
|
|
1613
|
+
return /* @__PURE__ */ U(mo.Provider, { value: y, children: e });
|
|
1614
|
+
}, xl = ({
|
|
1612
1615
|
children: e,
|
|
1613
1616
|
config: t,
|
|
1614
1617
|
onChange: n,
|
|
1615
1618
|
defaultColumnVisibility: o,
|
|
1616
1619
|
columnIdAliases: s
|
|
1617
1620
|
}) => {
|
|
1618
|
-
const d = ot.useRef([]), h = ot.useRef(null), p = ot.useRef(null), i = ot.useRef(null),
|
|
1621
|
+
const d = ot.useRef([]), h = ot.useRef(null), p = ot.useRef(null), i = ot.useRef(null), l = ot.useRef(void 0), a = ot.useRef(null), [b, m] = Ge(null), [C, w] = Ge(null), [T, I] = Ge(null), r = (_) => {
|
|
1619
1622
|
d.current = Array.from(new Set(_));
|
|
1620
1623
|
}, u = () => d.current, f = (_) => {
|
|
1621
1624
|
const j = d.current, le = /* @__PURE__ */ new Set([je, pe]);
|
|
@@ -1631,12 +1634,12 @@ const Sl = ({
|
|
|
1631
1634
|
);
|
|
1632
1635
|
} else
|
|
1633
1636
|
n(_, j);
|
|
1634
|
-
}, v =
|
|
1637
|
+
}, v = go(t, s), {
|
|
1635
1638
|
columnOrder: S = [],
|
|
1636
1639
|
columnPinning: O = {},
|
|
1637
1640
|
columnVisibility: R = {},
|
|
1638
1641
|
columnSizing: y = {},
|
|
1639
|
-
sorting:
|
|
1642
|
+
sorting: c = [],
|
|
1640
1643
|
groupBy: E,
|
|
1641
1644
|
groupByConfig: k = {},
|
|
1642
1645
|
rowHeight: F = 34,
|
|
@@ -1644,8 +1647,8 @@ const Sl = ({
|
|
|
1644
1647
|
columnSummaryScopes: g = {},
|
|
1645
1648
|
columnSummaryFormats: x = {}
|
|
1646
1649
|
} = v || {};
|
|
1647
|
-
|
|
1648
|
-
const D = C ?? F,
|
|
1650
|
+
l.current !== F && l.current !== void 0 && (C !== null && w(null), p.current && (clearTimeout(p.current), p.current = null)), l.current = F;
|
|
1651
|
+
const D = C ?? F, N = [...c], B = [...T ?? [...S]], X = { ...O }, P = ["thumbnail", "name", "subType", "status", "tags"];
|
|
1649
1652
|
P.forEach((_, j) => {
|
|
1650
1653
|
if (!B.includes(_)) {
|
|
1651
1654
|
const le = P[j - 1], ue = P[j + 1];
|
|
@@ -1732,7 +1735,7 @@ const Sl = ({
|
|
|
1732
1735
|
columnPinning: le
|
|
1733
1736
|
}), I(null);
|
|
1734
1737
|
}, 300);
|
|
1735
|
-
},
|
|
1738
|
+
}, M = (_) => {
|
|
1736
1739
|
const j = $(_);
|
|
1737
1740
|
f({
|
|
1738
1741
|
...v,
|
|
@@ -1825,11 +1828,11 @@ const Sl = ({
|
|
|
1825
1828
|
const j = Lt(_, re);
|
|
1826
1829
|
wt(j, re) || ae(j);
|
|
1827
1830
|
}, J = (_) => {
|
|
1828
|
-
const j = Lt(_,
|
|
1829
|
-
wt(j,
|
|
1831
|
+
const j = Lt(_, N);
|
|
1832
|
+
wt(j, N) || Y(j);
|
|
1830
1833
|
};
|
|
1831
1834
|
return /* @__PURE__ */ U(
|
|
1832
|
-
|
|
1835
|
+
yo.Provider,
|
|
1833
1836
|
{
|
|
1834
1837
|
value: {
|
|
1835
1838
|
// all columns ref
|
|
@@ -1844,7 +1847,7 @@ const Sl = ({
|
|
|
1844
1847
|
// column pinning
|
|
1845
1848
|
columnPinning: X,
|
|
1846
1849
|
setColumnPinning: he,
|
|
1847
|
-
updateColumnPinning:
|
|
1850
|
+
updateColumnPinning: M,
|
|
1848
1851
|
columnPinningOnChange: Se,
|
|
1849
1852
|
// column order
|
|
1850
1853
|
columnOrder: B,
|
|
@@ -1865,7 +1868,7 @@ const Sl = ({
|
|
|
1865
1868
|
columnSummaryFormats: x,
|
|
1866
1869
|
updateColumnSummaryFormat: ne,
|
|
1867
1870
|
// sorting
|
|
1868
|
-
sorting:
|
|
1871
|
+
sorting: N,
|
|
1869
1872
|
updateSorting: Y,
|
|
1870
1873
|
sortingOnChange: J,
|
|
1871
1874
|
// group by
|
|
@@ -1883,14 +1886,14 @@ const Sl = ({
|
|
|
1883
1886
|
children: e
|
|
1884
1887
|
}
|
|
1885
1888
|
);
|
|
1886
|
-
},
|
|
1889
|
+
}, kl = ({ children: e }) => {
|
|
1887
1890
|
const [t, n] = Ge(null), o = q((d) => {
|
|
1888
1891
|
n(d);
|
|
1889
1892
|
}, []), s = q(() => {
|
|
1890
1893
|
n(null);
|
|
1891
1894
|
}, []);
|
|
1892
1895
|
return /* @__PURE__ */ U(
|
|
1893
|
-
|
|
1896
|
+
ho.Provider,
|
|
1894
1897
|
{
|
|
1895
1898
|
value: {
|
|
1896
1899
|
selectedEntity: t,
|
|
@@ -1900,28 +1903,28 @@ const Sl = ({
|
|
|
1900
1903
|
children: e
|
|
1901
1904
|
}
|
|
1902
1905
|
);
|
|
1903
|
-
},
|
|
1906
|
+
}, Ri = ({ projectPermissions: e }) => {
|
|
1904
1907
|
const {
|
|
1905
1908
|
attributes: t,
|
|
1906
1909
|
isLoading: { siteInfo: n }
|
|
1907
|
-
} =
|
|
1910
|
+
} = pr(), { attrib_read: o, attrib_write: s } = e || {}, { enabled: d, attributes: h } = o || {}, {
|
|
1908
1911
|
enabled: p,
|
|
1909
1912
|
attributes: i,
|
|
1910
|
-
fields:
|
|
1911
|
-
} = s || {}, a = p ?
|
|
1913
|
+
fields: l
|
|
1914
|
+
} = s || {}, a = p ? l ?? [] : void 0;
|
|
1912
1915
|
return { attribFields: t.filter((m) => !d || h?.includes(m.name)).map((m) => ({
|
|
1913
1916
|
...m,
|
|
1914
1917
|
readOnly: p ? !i?.includes(m.name) : !1
|
|
1915
1918
|
})), writableFields: a, isLoading: n };
|
|
1916
|
-
},
|
|
1917
|
-
const { isLoading: n, isSuccess: o } = Ue(), { data: s } =
|
|
1919
|
+
}, Rl = ({ children: e, projectName: t }) => {
|
|
1920
|
+
const { isLoading: n, isSuccess: o } = Ue(), { data: s } = tr(
|
|
1918
1921
|
{ projectName: t },
|
|
1919
1922
|
{ skip: !t }
|
|
1920
1923
|
), { attrib_write: d } = s || {}, {
|
|
1921
1924
|
attribFields: h,
|
|
1922
1925
|
writableFields: p,
|
|
1923
1926
|
isLoading: i
|
|
1924
|
-
} =
|
|
1927
|
+
} = Ri({ projectPermissions: s }), { data: l = [] } = nr({ projectName: t }, { skip: !t }), a = l, b = H(() => d ? d.enabled ? !!d.fields?.includes("name") : !0 : !1, [d]), m = H(() => d ? d.enabled ? !!d.fields?.includes("label") : !0 : !1, [d]), C = o && !n && !i, w = H(
|
|
1925
1928
|
() => ({
|
|
1926
1929
|
isInitialized: C,
|
|
1927
1930
|
isLoading: n || i,
|
|
@@ -1942,13 +1945,13 @@ const Sl = ({
|
|
|
1942
1945
|
m
|
|
1943
1946
|
]
|
|
1944
1947
|
);
|
|
1945
|
-
return /* @__PURE__ */ U(
|
|
1946
|
-
},
|
|
1948
|
+
return /* @__PURE__ */ U(bo.Provider, { value: w, children: e });
|
|
1949
|
+
}, Al = ({
|
|
1947
1950
|
children: e,
|
|
1948
1951
|
updateEntities: t,
|
|
1949
1952
|
getFoldersTasks: n
|
|
1950
1953
|
}) => /* @__PURE__ */ U(
|
|
1951
|
-
|
|
1954
|
+
Io.Provider,
|
|
1952
1955
|
{
|
|
1953
1956
|
value: {
|
|
1954
1957
|
updateEntities: t,
|
|
@@ -1956,7 +1959,7 @@ const Sl = ({
|
|
|
1956
1959
|
},
|
|
1957
1960
|
children: e
|
|
1958
1961
|
}
|
|
1959
|
-
),
|
|
1962
|
+
), Pl = ({ children: e }) => {
|
|
1960
1963
|
const { selectedCells: t, gridMap: n, setSelectedCells: o, setFocusedCellId: s, setAnchorCell: d } = et();
|
|
1961
1964
|
let h;
|
|
1962
1965
|
try {
|
|
@@ -1972,19 +1975,19 @@ const Sl = ({
|
|
|
1972
1975
|
(n.rowIdToIndex.size === 0 || n.rowIdToIndex.has(I))
|
|
1973
1976
|
),
|
|
1974
1977
|
[t, n]
|
|
1975
|
-
),
|
|
1978
|
+
), l = H(() => {
|
|
1976
1979
|
const I = [...i].sort(), r = [...p.current].sort();
|
|
1977
1980
|
return I.length !== r.length || I.some((f, v) => f !== r[v]) ? (p.current = i, i) : p.current;
|
|
1978
1981
|
}, [i]);
|
|
1979
1982
|
$e(() => {
|
|
1980
|
-
|
|
1981
|
-
}, [
|
|
1983
|
+
l.length > 0 && h && h();
|
|
1984
|
+
}, [l.length, h]);
|
|
1982
1985
|
const a = q(() => {
|
|
1983
1986
|
const I = Array.from(n.rowIdToIndex.keys()), r = /* @__PURE__ */ new Set();
|
|
1984
1987
|
if (I.forEach((u) => {
|
|
1985
|
-
r.add(
|
|
1988
|
+
r.add(Me(u, pe));
|
|
1986
1989
|
}), o(r), I.length > 0) {
|
|
1987
|
-
const u =
|
|
1990
|
+
const u = Me(I[0], pe);
|
|
1988
1991
|
s(u), d(de(u));
|
|
1989
1992
|
}
|
|
1990
1993
|
}, [n]), b = q(() => {
|
|
@@ -1995,20 +1998,20 @@ const Sl = ({
|
|
|
1995
1998
|
}), r;
|
|
1996
1999
|
});
|
|
1997
2000
|
}, [o]), m = q(
|
|
1998
|
-
(I) =>
|
|
1999
|
-
[
|
|
2001
|
+
(I) => l.includes(I),
|
|
2002
|
+
[l]
|
|
2000
2003
|
), C = q(() => {
|
|
2001
2004
|
const I = n.rowIdToIndex.size;
|
|
2002
|
-
return I > 0 &&
|
|
2003
|
-
}, [n,
|
|
2004
|
-
selectedRows:
|
|
2005
|
+
return I > 0 && l.length === I;
|
|
2006
|
+
}, [n, l]), w = q(() => l.length > 0 && !C(), [l, C]), T = H(() => ({
|
|
2007
|
+
selectedRows: l,
|
|
2005
2008
|
selectAllRows: a,
|
|
2006
2009
|
clearRowsSelection: b,
|
|
2007
2010
|
isRowSelected: m,
|
|
2008
2011
|
areAllRowsSelected: C,
|
|
2009
2012
|
areSomeRowsSelected: w
|
|
2010
|
-
}), [
|
|
2011
|
-
return /* @__PURE__ */ U(
|
|
2013
|
+
}), [l, a, C, w, b]);
|
|
2014
|
+
return /* @__PURE__ */ U(wo.Provider, { value: T, children: e });
|
|
2012
2015
|
}, Jt = (e, t, n) => {
|
|
2013
2016
|
switch (e) {
|
|
2014
2017
|
case "unique-violation":
|
|
@@ -2022,13 +2025,13 @@ const Sl = ({
|
|
|
2022
2025
|
default:
|
|
2023
2026
|
return `Failed to update ${t}: ${n}`;
|
|
2024
2027
|
}
|
|
2025
|
-
},
|
|
2028
|
+
}, Ai = (e) => {
|
|
2026
2029
|
const { pushHistory: t, removeHistoryEntries: n } = e || {}, { projectName: o } = Ue(), {
|
|
2027
2030
|
getEntityById: s,
|
|
2028
2031
|
getInheritedDependents: d,
|
|
2029
2032
|
findInheritedValueFromAncestors: h,
|
|
2030
2033
|
findNonInheritedValues: p
|
|
2031
|
-
} = Ke(), { updateEntities: i } =
|
|
2034
|
+
} = Ke(), { updateEntities: i } = Co(), l = q(
|
|
2032
2035
|
async (b = [], m = !0) => {
|
|
2033
2036
|
if (!b.length || !o)
|
|
2034
2037
|
return;
|
|
@@ -2040,32 +2043,32 @@ const Sl = ({
|
|
|
2040
2043
|
return;
|
|
2041
2044
|
if (t && m) {
|
|
2042
2045
|
const S = C.map(
|
|
2043
|
-
({ rowId: R, id: y, type:
|
|
2046
|
+
({ rowId: R, id: y, type: c, field: E, isAttrib: k, meta: F, entityData: V }) => {
|
|
2044
2047
|
const g = s(y) || V;
|
|
2045
2048
|
if (!g)
|
|
2046
2049
|
throw "Entity not found: " + y;
|
|
2047
|
-
const x = g?.entityId || g.id, D = k ? g.attrib?.[E] ?? null : g[E] ?? null,
|
|
2050
|
+
const x = g?.entityId || g.id, D = k ? g.attrib?.[E] ?? null : g[E] ?? null, N = g?.ownAttrib || [], z = k && !N.includes(E);
|
|
2048
2051
|
return {
|
|
2049
2052
|
rowId: R,
|
|
2050
2053
|
id: x,
|
|
2051
|
-
type:
|
|
2054
|
+
type: c,
|
|
2052
2055
|
field: E,
|
|
2053
2056
|
value: D,
|
|
2054
2057
|
isAttrib: k,
|
|
2055
2058
|
wasInherited: z,
|
|
2056
2059
|
// Track inheritance status for undo
|
|
2057
|
-
ownAttrib:
|
|
2060
|
+
ownAttrib: N,
|
|
2058
2061
|
folderId: g?.folderId || g?.parentId,
|
|
2059
2062
|
meta: F
|
|
2060
2063
|
};
|
|
2061
2064
|
}
|
|
2062
2065
|
), O = C.flatMap(
|
|
2063
|
-
({ rowId: R, id: y, type:
|
|
2066
|
+
({ rowId: R, id: y, type: c, field: E, value: k, isAttrib: F, meta: V, entityData: g }) => {
|
|
2064
2067
|
const x = s(y) || g, D = x?.entityId || x?.id || y;
|
|
2065
2068
|
return x ? {
|
|
2066
2069
|
rowId: R,
|
|
2067
2070
|
id: D,
|
|
2068
|
-
type:
|
|
2071
|
+
type: c,
|
|
2069
2072
|
field: E,
|
|
2070
2073
|
value: k,
|
|
2071
2074
|
isAttrib: F,
|
|
@@ -2085,23 +2088,23 @@ const Sl = ({
|
|
|
2085
2088
|
];
|
|
2086
2089
|
let r = [];
|
|
2087
2090
|
for (const S of C) {
|
|
2088
|
-
let { id: O, type: R, field: y, value:
|
|
2091
|
+
let { id: O, type: R, field: y, value: c, isAttrib: E, meta: k, entityData: F } = S;
|
|
2089
2092
|
const V = s(O) || F, g = V?.entityId || V?.id || O;
|
|
2090
2093
|
let x = R;
|
|
2091
2094
|
if (!I.includes(x))
|
|
2092
2095
|
continue;
|
|
2093
|
-
const D = E ? { attrib: { [y]:
|
|
2096
|
+
const D = E ? { attrib: { [y]: c } } : { [y]: c };
|
|
2094
2097
|
if (E) {
|
|
2095
2098
|
const z = [...V?.ownAttrib || []];
|
|
2096
2099
|
z.includes(y) || z.push(y), D.ownAttrib = z;
|
|
2097
2100
|
}
|
|
2098
|
-
const
|
|
2101
|
+
const N = r.findIndex(
|
|
2099
2102
|
(z) => z.entityId === g && z.entityType === x
|
|
2100
2103
|
);
|
|
2101
|
-
if (
|
|
2102
|
-
const z = r[
|
|
2104
|
+
if (N !== -1) {
|
|
2105
|
+
const z = r[N];
|
|
2103
2106
|
let B = { ...z.data, ...D };
|
|
2104
|
-
z.data?.attrib && D.attrib && (B = { ...B, attrib: { ...z.data.attrib, ...D.attrib } }), r[
|
|
2107
|
+
z.data?.attrib && D.attrib && (B = { ...B, attrib: { ...z.data.attrib, ...D.attrib } }), r[N] = {
|
|
2105
2108
|
...z,
|
|
2106
2109
|
data: B
|
|
2107
2110
|
};
|
|
@@ -2136,13 +2139,13 @@ const Sl = ({
|
|
|
2136
2139
|
const O = Kn(S);
|
|
2137
2140
|
if (r.length === 1 && O.length > 0)
|
|
2138
2141
|
O.forEach((R) => {
|
|
2139
|
-
const y = r[0],
|
|
2142
|
+
const y = r[0], c = s(y.entityId), E = c?.label || c?.name || y.entityId || "", k = Jt(R, y.entityType, E);
|
|
2140
2143
|
Fe.error(k);
|
|
2141
2144
|
});
|
|
2142
2145
|
else {
|
|
2143
|
-
const R = r[0], y = R && s(R.entityId),
|
|
2146
|
+
const R = r[0], y = R && s(R.entityId), c = y?.label || y?.name || R?.entityId || "";
|
|
2144
2147
|
Fe.error(
|
|
2145
|
-
r.length === 1 ? Jt(void 0, R.entityType,
|
|
2148
|
+
r.length === 1 ? Jt(void 0, R.entityType, c) : "Failed to update entities"
|
|
2146
2149
|
);
|
|
2147
2150
|
}
|
|
2148
2151
|
t && m && n && n(1);
|
|
@@ -2204,8 +2207,8 @@ const Sl = ({
|
|
|
2204
2207
|
continue;
|
|
2205
2208
|
u = u;
|
|
2206
2209
|
const f = {};
|
|
2207
|
-
r.attribs.forEach((
|
|
2208
|
-
f[
|
|
2210
|
+
r.attribs.forEach((c) => {
|
|
2211
|
+
f[c] = null;
|
|
2209
2212
|
}), w.push({
|
|
2210
2213
|
entityType: u,
|
|
2211
2214
|
entityId: r.entityId,
|
|
@@ -2217,15 +2220,15 @@ const Sl = ({
|
|
|
2217
2220
|
meta: r.meta
|
|
2218
2221
|
});
|
|
2219
2222
|
const S = (() => {
|
|
2220
|
-
const
|
|
2221
|
-
let k =
|
|
2223
|
+
const c = r.folderId, E = [];
|
|
2224
|
+
let k = c, F = b.find((g) => g.entityId === k);
|
|
2222
2225
|
for (; F; )
|
|
2223
2226
|
E.push(F), k = F.folderId, F = b.find((g) => g.entityId === k);
|
|
2224
2227
|
return E.length > 0 ? E[E.length - 1] : null;
|
|
2225
2228
|
})(), O = S?.attribs || [], R = r.attribs.filter(
|
|
2226
|
-
(
|
|
2229
|
+
(c) => O.includes(c)
|
|
2227
2230
|
), y = r.attribs.filter(
|
|
2228
|
-
(
|
|
2231
|
+
(c) => !O.includes(c)
|
|
2229
2232
|
);
|
|
2230
2233
|
y.length > 0 && T.push({
|
|
2231
2234
|
...r,
|
|
@@ -2259,18 +2262,18 @@ const Sl = ({
|
|
|
2259
2262
|
}
|
|
2260
2263
|
}));
|
|
2261
2264
|
for (const y of R) {
|
|
2262
|
-
const
|
|
2265
|
+
const c = I.findIndex(
|
|
2263
2266
|
(E) => E.entityId === y.entityId
|
|
2264
2267
|
);
|
|
2265
|
-
if (
|
|
2266
|
-
const E = I[
|
|
2268
|
+
if (c !== -1) {
|
|
2269
|
+
const E = I[c];
|
|
2267
2270
|
let k = {
|
|
2268
2271
|
// @ts-ignore
|
|
2269
2272
|
...E.data?.attrib || {},
|
|
2270
2273
|
// @ts-ignore
|
|
2271
2274
|
...y.data?.attrib || {}
|
|
2272
2275
|
};
|
|
2273
|
-
I[
|
|
2276
|
+
I[c] = {
|
|
2274
2277
|
...E,
|
|
2275
2278
|
data: { attrib: k }
|
|
2276
2279
|
};
|
|
@@ -2312,9 +2315,9 @@ const Sl = ({
|
|
|
2312
2315
|
n
|
|
2313
2316
|
]
|
|
2314
2317
|
);
|
|
2315
|
-
return { updateEntities:
|
|
2316
|
-
},
|
|
2317
|
-
const { projectName: t } = Ue(), { getEntityById: n } = Ke(), { deleteEntities: o } =
|
|
2318
|
+
return { updateEntities: l, inheritFromParent: a };
|
|
2319
|
+
}, Pi = ({ onSuccess: e }) => {
|
|
2320
|
+
const { projectName: t } = Ue(), { getEntityById: n } = Ke(), { deleteEntities: o } = mr();
|
|
2318
2321
|
return q(
|
|
2319
2322
|
async (s) => {
|
|
2320
2323
|
if (!s || s.length === 0) {
|
|
@@ -2326,15 +2329,15 @@ const Sl = ({
|
|
|
2326
2329
|
const i = n(p);
|
|
2327
2330
|
if (!i || d.has(i.id)) continue;
|
|
2328
2331
|
d.add(i.id);
|
|
2329
|
-
const
|
|
2332
|
+
const l = i.entityType || ("folderId" in i ? "task" : "folder");
|
|
2330
2333
|
h.push({
|
|
2331
2334
|
id: i.id,
|
|
2332
|
-
entityType:
|
|
2335
|
+
entityType: l,
|
|
2333
2336
|
name: i.name,
|
|
2334
2337
|
label: i.label,
|
|
2335
2338
|
projectName: t,
|
|
2336
|
-
folderId:
|
|
2337
|
-
parentId:
|
|
2339
|
+
folderId: l === "folder" ? void 0 : i.folderId,
|
|
2340
|
+
parentId: l === "folder" ? i.parentId : void 0,
|
|
2338
2341
|
hasChildren: "hasChildren" in i ? i.hasChildren : void 0,
|
|
2339
2342
|
taskNames: "taskNames" in i ? i.taskNames : void 0
|
|
2340
2343
|
});
|
|
@@ -2347,7 +2350,7 @@ const Sl = ({
|
|
|
2347
2350
|
},
|
|
2348
2351
|
[n, t, o, e]
|
|
2349
2352
|
);
|
|
2350
|
-
},
|
|
2353
|
+
}, Di = ({
|
|
2351
2354
|
attribs: e,
|
|
2352
2355
|
headerLabels: t = [],
|
|
2353
2356
|
onOpenNew: n,
|
|
@@ -2358,17 +2361,17 @@ const Sl = ({
|
|
|
2358
2361
|
getEntityById: h,
|
|
2359
2362
|
toggleExpandAll: p,
|
|
2360
2363
|
toggleExpands: i,
|
|
2361
|
-
expanded:
|
|
2364
|
+
expanded: l,
|
|
2362
2365
|
contextMenuItems: a = [],
|
|
2363
2366
|
powerpack: b,
|
|
2364
2367
|
onOpenPlayer: m
|
|
2365
2368
|
} = Ke(), C = H(
|
|
2366
2369
|
() => [...a, ...o || []],
|
|
2367
2370
|
[a, o]
|
|
2368
|
-
), w =
|
|
2369
|
-
const { rowId:
|
|
2370
|
-
if (!
|
|
2371
|
-
const ee = h(
|
|
2371
|
+
), w = Ur(), T = Object.values(w || {}).some(Boolean), { canWriteLabelPermission: I, canWriteNamePermission: r } = Tn(), { copyToClipboard: u, exportCSV: f, pasteFromClipboard: v } = To(), { selectedCells: S, clearSelection: O, selectCell: R, focusCell: y } = et(), { inheritFromParent: c, history: E, setEditingCellId: k } = ut(), F = Pi({}), [V] = Br([], b), g = ($) => $.reduce((A, K) => {
|
|
2372
|
+
const { rowId: M, colId: Y } = de(K) || {};
|
|
2373
|
+
if (!M || !Y || !Y.startsWith("attrib_")) return A;
|
|
2374
|
+
const ee = h(M);
|
|
2372
2375
|
if (!ee) return A;
|
|
2373
2376
|
const se = ee.entityId || ee.id, ne = Y.replace("attrib_", ""), Re = e.find((Ie) => Ie.name === ne)?.data.inherit;
|
|
2374
2377
|
if (ee.ownAttrib?.includes(ne) && Re) {
|
|
@@ -2384,19 +2387,19 @@ const Sl = ({
|
|
|
2384
2387
|
});
|
|
2385
2388
|
}
|
|
2386
2389
|
return A;
|
|
2387
|
-
}, []), x = ($, A, K,
|
|
2390
|
+
}, []), x = ($, A, K, M) => [
|
|
2388
2391
|
{
|
|
2389
2392
|
label: "Copy",
|
|
2390
2393
|
icon: "content_copy",
|
|
2391
2394
|
shortcut: Qt("c", [Xt.Ctrl]),
|
|
2392
|
-
command: () => u(
|
|
2395
|
+
command: () => u(M.selectedCells),
|
|
2393
2396
|
hidden: A.isGroup || A.columnId === "thumbnail"
|
|
2394
2397
|
},
|
|
2395
2398
|
{
|
|
2396
|
-
label: `Copy row${
|
|
2399
|
+
label: `Copy row${M.selectedFullRows.length > 1 ? "s" : ""}`,
|
|
2397
2400
|
icon: "content_copy",
|
|
2398
|
-
command: () => u(
|
|
2399
|
-
hidden: A.columnId !== "name" || !
|
|
2401
|
+
command: () => u(M.selectedFullRows, !0),
|
|
2402
|
+
hidden: A.columnId !== "name" || !M.selectedFullRows.some(
|
|
2400
2403
|
(Y) => de(Y)?.rowId === de(A.cellId)?.rowId
|
|
2401
2404
|
)
|
|
2402
2405
|
},
|
|
@@ -2404,20 +2407,20 @@ const Sl = ({
|
|
|
2404
2407
|
label: "Paste",
|
|
2405
2408
|
icon: "content_paste",
|
|
2406
2409
|
shortcut: Qt("v", [Xt.Ctrl]),
|
|
2407
|
-
command: () => v(
|
|
2410
|
+
command: () => v(M.selectedCells),
|
|
2408
2411
|
hidden: A.columnId === "name" || A.columnId === "thumbnail" || A.isGroup,
|
|
2409
2412
|
disabled: A.attribField?.readOnly
|
|
2410
2413
|
}
|
|
2411
|
-
], D = ($, A, K,
|
|
2414
|
+
], D = ($, A, K, M) => ({
|
|
2412
2415
|
label: "Show details",
|
|
2413
2416
|
icon: "dock_to_left",
|
|
2414
2417
|
shortcut: "Double click",
|
|
2415
2418
|
command: () => {
|
|
2416
|
-
const Y =
|
|
2419
|
+
const Y = Me(A.entityId, pe);
|
|
2417
2420
|
R(Y, !1, !1);
|
|
2418
2421
|
},
|
|
2419
|
-
hidden: A.columnId !== "name" ||
|
|
2420
|
-
}),
|
|
2422
|
+
hidden: A.columnId !== "name" || M.selectedRows.length > 1 || A.isGroup || nn(A.entityType)
|
|
2423
|
+
}), N = ($, A) => ({
|
|
2421
2424
|
label: "Open in viewer",
|
|
2422
2425
|
icon: "play_circle",
|
|
2423
2426
|
shortcut: "Spacebar",
|
|
@@ -2425,40 +2428,40 @@ const Sl = ({
|
|
|
2425
2428
|
if (m) {
|
|
2426
2429
|
const K = h(A.entityId);
|
|
2427
2430
|
if (K) {
|
|
2428
|
-
const
|
|
2429
|
-
m(
|
|
2431
|
+
const M = xn(K);
|
|
2432
|
+
m(M, { quickView: !0 });
|
|
2430
2433
|
}
|
|
2431
2434
|
}
|
|
2432
2435
|
},
|
|
2433
2436
|
hidden: A.columnId !== "thumbnail" && A.columnId !== "name" || A.isGroup || A.entityType === "unknown"
|
|
2434
|
-
}), z = ($, A, K,
|
|
2437
|
+
}), z = ($, A, K, M) => [
|
|
2435
2438
|
{
|
|
2436
2439
|
label: "Expand children",
|
|
2437
2440
|
icon: "expand_all",
|
|
2438
2441
|
shortcut: Qt("click", [Xt.Alt]),
|
|
2439
|
-
command: () => p(
|
|
2442
|
+
command: () => p(M.selectedRows, !0),
|
|
2440
2443
|
hidden: A.columnId !== "name" || A.entityType !== "folder"
|
|
2441
2444
|
},
|
|
2442
2445
|
{
|
|
2443
2446
|
label: "Collapse children",
|
|
2444
2447
|
icon: "collapse_all",
|
|
2445
2448
|
shortcut: Qt("click", [Xt.Alt]),
|
|
2446
|
-
command: () => p(
|
|
2449
|
+
command: () => p(M.selectedRows, !1),
|
|
2447
2450
|
hidden: A.columnId !== "name" || A.entityType !== "folder"
|
|
2448
2451
|
},
|
|
2449
2452
|
{
|
|
2450
2453
|
label: "Expand",
|
|
2451
2454
|
icon: "expand_all",
|
|
2452
|
-
command: () => i(
|
|
2453
|
-
hidden: A.columnId !== "name" || !A.isGroup ||
|
|
2455
|
+
command: () => i(M.selectedRows, !0),
|
|
2456
|
+
hidden: A.columnId !== "name" || !A.isGroup || l[A.entityId]
|
|
2454
2457
|
},
|
|
2455
2458
|
{
|
|
2456
2459
|
label: "Collapse",
|
|
2457
2460
|
icon: "collapse_all",
|
|
2458
|
-
command: () => i(
|
|
2459
|
-
hidden: A.columnId !== "name" || !A.isGroup || !
|
|
2461
|
+
command: () => i(M.selectedRows, !1),
|
|
2462
|
+
hidden: A.columnId !== "name" || !A.isGroup || !l[A.entityId]
|
|
2460
2463
|
}
|
|
2461
|
-
], B = ($, A, K,
|
|
2464
|
+
], B = ($, A, K, M) => ({
|
|
2462
2465
|
label: "Delete",
|
|
2463
2466
|
icon: "delete",
|
|
2464
2467
|
danger: !0,
|
|
@@ -2468,21 +2471,21 @@ const Sl = ({
|
|
|
2468
2471
|
command: () => {
|
|
2469
2472
|
const Y = [
|
|
2470
2473
|
...new Set(
|
|
2471
|
-
|
|
2474
|
+
M.selectedCells.map((ee) => de(ee)?.rowId).filter((ee) => !!ee)
|
|
2472
2475
|
)
|
|
2473
2476
|
];
|
|
2474
|
-
F(Y.length ? Y :
|
|
2477
|
+
F(Y.length ? Y : M.selectedRows);
|
|
2475
2478
|
},
|
|
2476
2479
|
hidden: A.columnId !== "name" || A.isGroup
|
|
2477
|
-
}), X = ($, A, K,
|
|
2478
|
-
const Y = g(
|
|
2480
|
+
}), X = ($, A, K, M) => {
|
|
2481
|
+
const Y = g(M.selectedCells), ee = Y.length > 0 && d && !(M.selectedRows.length > 1 && M.selectedColumns.length > 1);
|
|
2479
2482
|
return {
|
|
2480
2483
|
label: "Inherit from parent",
|
|
2481
2484
|
icon: "disabled_by_default",
|
|
2482
|
-
command: () =>
|
|
2485
|
+
command: () => c(Y),
|
|
2483
2486
|
hidden: !ee
|
|
2484
2487
|
};
|
|
2485
|
-
}, P =
|
|
2488
|
+
}, P = gr(), L = ($, A) => P?.isAvailable && P.source ? {
|
|
2486
2489
|
label: "Export",
|
|
2487
2490
|
icon: "download",
|
|
2488
2491
|
command: () => P.openExport("selection"),
|
|
@@ -2490,20 +2493,20 @@ const Sl = ({
|
|
|
2490
2493
|
} : {
|
|
2491
2494
|
label: "Export selection",
|
|
2492
2495
|
icon: "download",
|
|
2493
|
-
items:
|
|
2494
|
-
label: `${
|
|
2496
|
+
items: Ti.map(({ value: K, label: M }) => ({
|
|
2497
|
+
label: `${M} separated (${K === " " ? ".tsv" : ".csv"})`,
|
|
2495
2498
|
command: () => f(Array.from(S), s, K)
|
|
2496
2499
|
})),
|
|
2497
2500
|
hidden: A.isGroup
|
|
2498
2501
|
}, G = ($, A) => {
|
|
2499
|
-
const
|
|
2502
|
+
const M = (A.length ? A : [$.entityId]).flatMap((Y) => {
|
|
2500
2503
|
const ee = h(Y);
|
|
2501
2504
|
return ee ? ee.entityType === "folder" || !("folderId" in ee) ? [ee.id] : ee.folderId ? [ee.folderId] : [] : [];
|
|
2502
2505
|
});
|
|
2503
|
-
return
|
|
2506
|
+
return M.length ? M : null;
|
|
2504
2507
|
}, te = ($, A, K) => {
|
|
2505
|
-
const
|
|
2506
|
-
n?.($,
|
|
2508
|
+
const M = G(A, K);
|
|
2509
|
+
n?.($, M ? { parentFolderIds: M } : void 0);
|
|
2507
2510
|
}, ae = {
|
|
2508
2511
|
"copy-paste": x,
|
|
2509
2512
|
"show-details": D,
|
|
@@ -2512,7 +2515,7 @@ const Sl = ({
|
|
|
2512
2515
|
icon: "titlecase",
|
|
2513
2516
|
shortcut: "R",
|
|
2514
2517
|
command: () => {
|
|
2515
|
-
const K =
|
|
2518
|
+
const K = Me(A.entityId, "name");
|
|
2516
2519
|
k(K);
|
|
2517
2520
|
},
|
|
2518
2521
|
hidden: A.columnId !== "name" || A.isGroup || A.entityType !== "folder" && A.entityType !== "task",
|
|
@@ -2522,12 +2525,12 @@ const Sl = ({
|
|
|
2522
2525
|
delete: B,
|
|
2523
2526
|
inherit: X,
|
|
2524
2527
|
export: L,
|
|
2525
|
-
"create-folder": ($, A, K,
|
|
2528
|
+
"create-folder": ($, A, K, M) => [
|
|
2526
2529
|
{
|
|
2527
2530
|
label: It.folder.createLabel,
|
|
2528
2531
|
icon: It.folder.icon,
|
|
2529
2532
|
command: () => {
|
|
2530
|
-
d ? te("folder", A,
|
|
2533
|
+
d ? te("folder", A, M.selectedRows) : n?.("folder");
|
|
2531
2534
|
},
|
|
2532
2535
|
hidden: A.columnId !== "name" || !n
|
|
2533
2536
|
},
|
|
@@ -2540,26 +2543,26 @@ const Sl = ({
|
|
|
2540
2543
|
hidden: A.columnId !== "name" || !n
|
|
2541
2544
|
}
|
|
2542
2545
|
],
|
|
2543
|
-
"create-task": ($, A, K,
|
|
2544
|
-
const Y = !!G(A,
|
|
2546
|
+
"create-task": ($, A, K, M) => {
|
|
2547
|
+
const Y = !!G(A, M.selectedRows) || T;
|
|
2545
2548
|
return {
|
|
2546
2549
|
label: It.task.createLabel,
|
|
2547
2550
|
icon: It.task.icon,
|
|
2548
|
-
command: () => te("task", A,
|
|
2551
|
+
command: () => te("task", A, M.selectedRows),
|
|
2549
2552
|
hidden: A.columnId !== "name" || !n,
|
|
2550
2553
|
disabled: !Y
|
|
2551
2554
|
};
|
|
2552
2555
|
},
|
|
2553
|
-
"open-viewer":
|
|
2556
|
+
"open-viewer": N
|
|
2554
2557
|
}, Ae = ($) => {
|
|
2555
2558
|
const { rowId: A, colId: K } = de($) || {};
|
|
2556
2559
|
if (!A || !K) return;
|
|
2557
|
-
const
|
|
2560
|
+
const M = h(A), Y = e.find((ne) => ne.name === K?.replace("attrib_", "")), ee = t.find((ne) => ne.id === K), se = M ? "parentId" in M ? M.parentId : "folderId" in M ? M.folderId : void 0 : void 0;
|
|
2558
2561
|
return {
|
|
2559
2562
|
cellId: $,
|
|
2560
2563
|
columnId: K,
|
|
2561
|
-
entityId:
|
|
2562
|
-
entityType:
|
|
2564
|
+
entityId: M?.entityId || M?.id || A,
|
|
2565
|
+
entityType: M?.entityType,
|
|
2563
2566
|
parentId: se,
|
|
2564
2567
|
attribField: Y,
|
|
2565
2568
|
isGroup: A.startsWith(Tt),
|
|
@@ -2567,13 +2570,13 @@ const Sl = ({
|
|
|
2567
2570
|
id: K,
|
|
2568
2571
|
label: ee?.label || ""
|
|
2569
2572
|
},
|
|
2570
|
-
data:
|
|
2573
|
+
data: M
|
|
2571
2574
|
};
|
|
2572
2575
|
};
|
|
2573
2576
|
return { handleTableBodyContextMenu: ($) => {
|
|
2574
|
-
const
|
|
2575
|
-
if (!
|
|
2576
|
-
const Y = Ae(
|
|
2577
|
+
const M = $.target.closest("td")?.querySelector(":scope > [id]")?.id;
|
|
2578
|
+
if (!M) return;
|
|
2579
|
+
const Y = Ae(M);
|
|
2577
2580
|
if (!Y) return;
|
|
2578
2581
|
let ee = Array.from(S);
|
|
2579
2582
|
const ne = ee.filter(
|
|
@@ -2581,7 +2584,7 @@ const Sl = ({
|
|
|
2581
2584
|
).some(
|
|
2582
2585
|
(J) => de(J)?.rowId === Y.entityId
|
|
2583
2586
|
);
|
|
2584
|
-
(!ee.includes(
|
|
2587
|
+
(!ee.includes(M) && !ne || !ee.length) && (ee = [M], R(M, !1, !1), y(M));
|
|
2585
2588
|
const Te = ee.filter(
|
|
2586
2589
|
(J) => de(J)?.colId !== pe
|
|
2587
2590
|
), Re = ee.flatMap((J) => Ae(J) || []), Ie = [
|
|
@@ -2624,7 +2627,7 @@ const Sl = ({
|
|
|
2624
2627
|
);
|
|
2625
2628
|
V($, De);
|
|
2626
2629
|
} };
|
|
2627
|
-
},
|
|
2630
|
+
}, Li = (e) => {
|
|
2628
2631
|
const {
|
|
2629
2632
|
expanded: t,
|
|
2630
2633
|
expandedParentIds: n,
|
|
@@ -2632,7 +2635,7 @@ const Sl = ({
|
|
|
2632
2635
|
excludeSelectedFolders: s,
|
|
2633
2636
|
getFolderById: d,
|
|
2634
2637
|
showHierarchy: h
|
|
2635
|
-
} = e, p = t, i = /* @__PURE__ */ new Map(),
|
|
2638
|
+
} = e, p = t, i = /* @__PURE__ */ new Map(), l = (a) => {
|
|
2636
2639
|
if (i.has(a)) return i.get(a);
|
|
2637
2640
|
const b = d(a);
|
|
2638
2641
|
if (!b)
|
|
@@ -2645,13 +2648,13 @@ const Sl = ({
|
|
|
2645
2648
|
return i.set(a, w), w;
|
|
2646
2649
|
}
|
|
2647
2650
|
if (h) {
|
|
2648
|
-
const w = p[m] === !0 &&
|
|
2651
|
+
const w = p[m] === !0 && l(m);
|
|
2649
2652
|
return i.set(a, w), w;
|
|
2650
2653
|
} else
|
|
2651
2654
|
return !0;
|
|
2652
2655
|
};
|
|
2653
|
-
return n.filter((a) =>
|
|
2654
|
-
},
|
|
2656
|
+
return n.filter((a) => l(a));
|
|
2657
|
+
}, Oi = 1e3, _i = 400, Fi = 100, ss = (e = 1) => Math.max(Fi, Math.min(_i, Math.round(Oi / e))), Ni = ({
|
|
2655
2658
|
groups: e = [],
|
|
2656
2659
|
filters: t = { conditions: [] },
|
|
2657
2660
|
groupBy: n,
|
|
@@ -2674,18 +2677,18 @@ const Sl = ({
|
|
|
2674
2677
|
key: n.id,
|
|
2675
2678
|
value: e.map((a) => a.value),
|
|
2676
2679
|
operator: d ? "excludesany" : "notin"
|
|
2677
|
-
},
|
|
2680
|
+
}, l = {
|
|
2678
2681
|
value: Gn,
|
|
2679
2682
|
count: ss() * (o[Gn] || 1),
|
|
2680
2683
|
filter: JSON.stringify({ ...t, conditions: [...h, i] })
|
|
2681
2684
|
};
|
|
2682
|
-
return [...p,
|
|
2683
|
-
},
|
|
2685
|
+
return [...p, l];
|
|
2686
|
+
}, Mi = 300, $i = (e, t) => fr(
|
|
2684
2687
|
e.map((n) => ({
|
|
2685
|
-
key:
|
|
2688
|
+
key: So(n.id, t, "task")?.replace("_", "."),
|
|
2686
2689
|
desc: n.desc
|
|
2687
2690
|
}))
|
|
2688
|
-
),
|
|
2691
|
+
), Dl = ({
|
|
2689
2692
|
projectName: e,
|
|
2690
2693
|
selectedFolders: t,
|
|
2691
2694
|
// comes from the slicer
|
|
@@ -2697,7 +2700,7 @@ const Sl = ({
|
|
|
2697
2700
|
sorting: h,
|
|
2698
2701
|
groupBy: p,
|
|
2699
2702
|
taskGroups: i = [],
|
|
2700
|
-
taskGroupsCount:
|
|
2703
|
+
taskGroupsCount: l,
|
|
2701
2704
|
expanded: a,
|
|
2702
2705
|
showHierarchy: b,
|
|
2703
2706
|
isFlatFolderView: m = !1,
|
|
@@ -2714,14 +2717,14 @@ const Sl = ({
|
|
|
2714
2717
|
taskStatsUninitialized: R,
|
|
2715
2718
|
dispatch: y
|
|
2716
2719
|
}) => {
|
|
2717
|
-
const { isLoading:
|
|
2720
|
+
const { isLoading: c } = w, {
|
|
2718
2721
|
folders: E,
|
|
2719
2722
|
isLoading: k,
|
|
2720
2723
|
isUninitialized: F,
|
|
2721
2724
|
getFolderById: V,
|
|
2722
2725
|
getFolderIdsWithoutChildren: g
|
|
2723
|
-
} =
|
|
2724
|
-
() =>
|
|
2726
|
+
} = yr(), x = Object.entries(a).filter(([, Z]) => Z).filter(([Z]) => !bn(Z)).map(([Z]) => Z), D = H(
|
|
2727
|
+
() => Li({
|
|
2725
2728
|
expanded: a,
|
|
2726
2729
|
expandedParentIds: x,
|
|
2727
2730
|
selectedFolders: t,
|
|
@@ -2737,17 +2740,17 @@ const Sl = ({
|
|
|
2737
2740
|
V,
|
|
2738
2741
|
b
|
|
2739
2742
|
]
|
|
2740
|
-
), [
|
|
2741
|
-
() =>
|
|
2743
|
+
), [N, z] = Ge(f), B = H(
|
|
2744
|
+
() => dr((Z) => z(Z), Mi),
|
|
2742
2745
|
[]
|
|
2743
2746
|
);
|
|
2744
2747
|
$e(() => (B(f), () => B.cancel()), [f, B]);
|
|
2745
2748
|
const X = H(() => {
|
|
2746
2749
|
if (!b || m)
|
|
2747
2750
|
return D;
|
|
2748
|
-
const Z = new Set(
|
|
2751
|
+
const Z = new Set(N);
|
|
2749
2752
|
return D.filter((ge) => Z.has(ge));
|
|
2750
|
-
}, [D, b, m,
|
|
2753
|
+
}, [D, b, m, N]), P = {
|
|
2751
2754
|
projectName: e,
|
|
2752
2755
|
parentIds: X,
|
|
2753
2756
|
filter: s.filterString,
|
|
@@ -2759,7 +2762,7 @@ const Sl = ({
|
|
|
2759
2762
|
isFetching: G,
|
|
2760
2763
|
error: te,
|
|
2761
2764
|
isUninitialized: be
|
|
2762
|
-
} =
|
|
2765
|
+
} = sr(P, {
|
|
2763
2766
|
skip: r || !X.length || !b && !m
|
|
2764
2767
|
}), he = !s.filterString && !d.filterString && !s.search && !d.search || !E.length || !b && !m, re = {
|
|
2765
2768
|
projectName: e,
|
|
@@ -2774,7 +2777,7 @@ const Sl = ({
|
|
|
2774
2777
|
isLoading: W,
|
|
2775
2778
|
isUninitialized: $,
|
|
2776
2779
|
error: A
|
|
2777
|
-
} =
|
|
2780
|
+
} = or(re, {
|
|
2778
2781
|
skip: r || he
|
|
2779
2782
|
}), K = H(() => {
|
|
2780
2783
|
const Z = /* @__PURE__ */ new Set(), ge = /* @__PURE__ */ new Set();
|
|
@@ -2786,18 +2789,18 @@ const Sl = ({
|
|
|
2786
2789
|
const fe = oe.parentId, ce = n ? t.includes(fe) : t.includes(oe.id);
|
|
2787
2790
|
(a[fe] === !0 || ce) && Z.add(oe.id);
|
|
2788
2791
|
});
|
|
2789
|
-
for (const oe of
|
|
2792
|
+
for (const oe of N)
|
|
2790
2793
|
ge.has(oe) && Z.add(oe);
|
|
2791
2794
|
return Z;
|
|
2792
2795
|
}, [
|
|
2793
|
-
|
|
2796
|
+
N,
|
|
2794
2797
|
E,
|
|
2795
2798
|
ae,
|
|
2796
2799
|
he,
|
|
2797
2800
|
a,
|
|
2798
2801
|
t,
|
|
2799
2802
|
n
|
|
2800
|
-
]),
|
|
2803
|
+
]), M = {
|
|
2801
2804
|
projectName: e,
|
|
2802
2805
|
entityIds: Array.from(K),
|
|
2803
2806
|
entityType: "folder"
|
|
@@ -2805,7 +2808,7 @@ const Sl = ({
|
|
|
2805
2808
|
data: Y = [],
|
|
2806
2809
|
isUninitialized: ee,
|
|
2807
2810
|
isFetching: se
|
|
2808
|
-
} = qn(
|
|
2811
|
+
} = qn(M, { skip: r || T }), ne = H(() => {
|
|
2809
2812
|
const Z = /* @__PURE__ */ new Map(), ge = (oe) => ({
|
|
2810
2813
|
...oe,
|
|
2811
2814
|
entityId: oe.id,
|
|
@@ -2820,13 +2823,13 @@ const Sl = ({
|
|
|
2820
2823
|
for (const ye of E)
|
|
2821
2824
|
fe.set(ye.id, ye);
|
|
2822
2825
|
const ce = (ye) => {
|
|
2823
|
-
const
|
|
2824
|
-
|
|
2826
|
+
const Ne = fe.get(ye);
|
|
2827
|
+
Ne && Ne.parentId && (oe.add(Ne.parentId), ce(Ne.parentId));
|
|
2825
2828
|
};
|
|
2826
2829
|
if (!m) {
|
|
2827
2830
|
const ye = [...oe];
|
|
2828
|
-
for (const
|
|
2829
|
-
ce(
|
|
2831
|
+
for (const Ne of ye)
|
|
2832
|
+
ce(Ne);
|
|
2830
2833
|
}
|
|
2831
2834
|
for (const ye of E)
|
|
2832
2835
|
oe.has(ye.id) && Z.set(ye.id, ge(ye));
|
|
@@ -2836,9 +2839,9 @@ const Sl = ({
|
|
|
2836
2839
|
if (t.length) {
|
|
2837
2840
|
const oe = t.map((ce) => E.find((ye) => ye.id === ce)?.path).filter(Boolean), fe = /* @__PURE__ */ new Map();
|
|
2838
2841
|
return Z.forEach((ce, ye) => {
|
|
2839
|
-
const
|
|
2842
|
+
const Ne = ce.path, mt = oe.includes(Ne);
|
|
2840
2843
|
(oe.some(
|
|
2841
|
-
(Ht) =>
|
|
2844
|
+
(Ht) => Ne.startsWith(Ht + "/")
|
|
2842
2845
|
) || mt && (!n || m)) && fe.set(ye, ge(ce));
|
|
2843
2846
|
}), fe;
|
|
2844
2847
|
}
|
|
@@ -2851,7 +2854,7 @@ const Sl = ({
|
|
|
2851
2854
|
n,
|
|
2852
2855
|
Y,
|
|
2853
2856
|
m
|
|
2854
|
-
]), Te = H(() => G ?
|
|
2857
|
+
]), Te = H(() => G ? Zr({
|
|
2855
2858
|
expandedFoldersTasks: L,
|
|
2856
2859
|
expandedParentIds: x,
|
|
2857
2860
|
foldersMap: ne
|
|
@@ -2859,7 +2862,7 @@ const Sl = ({
|
|
|
2859
2862
|
$e(() => {
|
|
2860
2863
|
Re && Ie("");
|
|
2861
2864
|
}, [h, Re]);
|
|
2862
|
-
const { sortBy: Le, desc: Ce } =
|
|
2865
|
+
const { sortBy: Le, desc: Ce } = $i(h, b), Se = t.length ? Array.from(
|
|
2863
2866
|
/* @__PURE__ */ new Set([...ne.keys(), ...n ? t : []])
|
|
2864
2867
|
) : void 0, ve = H(
|
|
2865
2868
|
() => g(t),
|
|
@@ -2886,7 +2889,7 @@ const Sl = ({
|
|
|
2886
2889
|
hasNextPage: Oe,
|
|
2887
2890
|
isFetchingNextPage: Ee,
|
|
2888
2891
|
isUninitialized: xe
|
|
2889
|
-
} =
|
|
2892
|
+
} = rr(_, {
|
|
2890
2893
|
// Skip flat task list for flat folder view (tasks loaded on folder expand).
|
|
2891
2894
|
// In hierarchy+slicer mode, run it to fetch tasks under selected-but-hidden folders.
|
|
2892
2895
|
// Always run it when entity list provides specific task IDs.
|
|
@@ -2895,23 +2898,23 @@ const Sl = ({
|
|
|
2895
2898
|
cursor: "",
|
|
2896
2899
|
desc: Ce
|
|
2897
2900
|
}
|
|
2898
|
-
}), _e = H(() => j?.pages ? j.pages.flatMap((Z) => Z.tasks || []) : [], [j?.pages]), { pageCounts: rt, incrementPageCount: qe } =
|
|
2901
|
+
}), _e = H(() => j?.pages ? j.pages.flatMap((Z) => Z.tasks || []) : [], [j?.pages]), { pageCounts: rt, incrementPageCount: qe } = Xr({
|
|
2899
2902
|
groups: i
|
|
2900
|
-
}), We =
|
|
2903
|
+
}), We = Yr(p, C), Nt = H(() => Object.entries(a).filter(([, Z]) => Z).filter(([Z]) => bn(Z)).map(([Z]) => Z.slice(Tt.length)), [a]), vt = H(() => p ? Ni({
|
|
2901
2904
|
groups: i,
|
|
2902
2905
|
// @ts-expect-error: filter is the same
|
|
2903
2906
|
filters: s.filter,
|
|
2904
2907
|
groupBy: p,
|
|
2905
2908
|
groupPageCounts: rt,
|
|
2906
2909
|
dataType: We
|
|
2907
|
-
}).filter((ge) =>
|
|
2910
|
+
}).filter((ge) => Nt.includes(ge.value)) : [], [
|
|
2908
2911
|
p,
|
|
2909
2912
|
i,
|
|
2910
2913
|
rt,
|
|
2911
2914
|
We,
|
|
2912
2915
|
s.filter,
|
|
2913
|
-
|
|
2914
|
-
]),
|
|
2916
|
+
Nt
|
|
2917
|
+
]), Mt = {
|
|
2915
2918
|
projectName: e,
|
|
2916
2919
|
groups: vt,
|
|
2917
2920
|
sortBy: Le,
|
|
@@ -2919,14 +2922,14 @@ const Sl = ({
|
|
|
2919
2922
|
search: s.search,
|
|
2920
2923
|
folderFilter: d.filterString,
|
|
2921
2924
|
folderIds: Se,
|
|
2922
|
-
groupCount:
|
|
2925
|
+
groupCount: l,
|
|
2923
2926
|
showComments: I
|
|
2924
2927
|
}, {
|
|
2925
2928
|
data: { tasks: $t = [] } = {},
|
|
2926
2929
|
isUninitialized: Vt,
|
|
2927
2930
|
error: ln
|
|
2928
|
-
} =
|
|
2929
|
-
skip: r || !p || !vt.length ||
|
|
2931
|
+
} = ir(Mt, {
|
|
2932
|
+
skip: r || !p || !vt.length || c
|
|
2930
2933
|
}), ft = H(() => o?.length ? _e : m ? L : b ? De ? [...L, ..._e] : L : p ? $t : _e, [
|
|
2931
2934
|
o,
|
|
2932
2935
|
b,
|
|
@@ -2979,17 +2982,17 @@ const Sl = ({
|
|
|
2979
2982
|
for (const fe of ft) {
|
|
2980
2983
|
const ce = fe.id, ye = fe.folderId;
|
|
2981
2984
|
if (Z.has(ce)) {
|
|
2982
|
-
const
|
|
2983
|
-
...
|
|
2985
|
+
const Ne = Z.get(ce), mt = oe(fe), Ze = {
|
|
2986
|
+
...Ne,
|
|
2984
2987
|
...mt,
|
|
2985
|
-
groups: [...
|
|
2988
|
+
groups: [...Ne.groups || [], ...mt.groups || []]
|
|
2986
2989
|
};
|
|
2987
2990
|
Z.set(ce, Ze);
|
|
2988
2991
|
} else
|
|
2989
2992
|
Z.set(ce, oe(fe));
|
|
2990
2993
|
if (ge.has(ye)) {
|
|
2991
|
-
const
|
|
2992
|
-
|
|
2994
|
+
const Ne = ge.get(ye);
|
|
2995
|
+
Ne.includes(ce) || Ne.push(ce);
|
|
2993
2996
|
} else
|
|
2994
2997
|
ge.set(ye, [ce]);
|
|
2995
2998
|
}
|
|
@@ -3020,18 +3023,18 @@ const Sl = ({
|
|
|
3020
3023
|
}), (ge || oe || fe) && !$ && ce.push({ endpointName: "getSearchFolders", args: re }), (ge || fe) && !be && ce.push({
|
|
3021
3024
|
endpointName: "getOverviewTasksByFolders",
|
|
3022
3025
|
args: P
|
|
3023
|
-
}), (ge || fe) && !xe && ce.push({ endpointName: "getTasksListInfinite", args: _ }), (ge || fe) && !Vt && ce.push({ endpointName: "getGroupedTasksList", args:
|
|
3026
|
+
}), (ge || fe) && !xe && ce.push({ endpointName: "getTasksListInfinite", args: _ }), (ge || fe) && !Vt && ce.push({ endpointName: "getGroupedTasksList", args: Mt }), (ge || oe) && !O && v && ce.push({ endpointName: "GetFolderColumnStats", args: v }), (ge || fe) && !R && S && ce.push({ endpointName: "GetTaskColumnStats", args: S }), (ge || oe) && !ee && ce.push({ endpointName: "getEntityLinks", args: M }), (ge || fe) && !zt && ce.push({ endpointName: "getEntityLinks", args: it }), await Promise.all([
|
|
3024
3027
|
...ce.map(
|
|
3025
|
-
({ endpointName: ye, args:
|
|
3026
|
-
|
|
3028
|
+
({ endpointName: ye, args: Ne }) => y(
|
|
3029
|
+
qr(ye, Ne, {
|
|
3027
3030
|
refreshOtherActiveQueries: !1
|
|
3028
3031
|
})
|
|
3029
3032
|
).unwrap()
|
|
3030
3033
|
),
|
|
3031
3034
|
// the Lists and Review sessions columns
|
|
3032
|
-
ge && y(
|
|
3035
|
+
ge && y(ar(e))
|
|
3033
3036
|
]), ce.map(
|
|
3034
|
-
({ endpointName: ye, args:
|
|
3037
|
+
({ endpointName: ye, args: Ne }) => y(Qr(ye, Ne))
|
|
3035
3038
|
);
|
|
3036
3039
|
}, jt = ue || A || ln, Je = H(() => {
|
|
3037
3040
|
if (te && u)
|
|
@@ -3050,7 +3053,7 @@ const Sl = ({
|
|
|
3050
3053
|
softError: te?.error,
|
|
3051
3054
|
// this is separate as we should still show the folders table so the user can make changes
|
|
3052
3055
|
softErrorAction: Je,
|
|
3053
|
-
isLoadingAll: r || k || le || W ||
|
|
3056
|
+
isLoadingAll: r || k || le || W || c,
|
|
3054
3057
|
// these all show a full loading state
|
|
3055
3058
|
isLoadingMore: Ee,
|
|
3056
3059
|
loadingTasks: Te,
|
|
@@ -3058,7 +3061,7 @@ const Sl = ({
|
|
|
3058
3061
|
fetchNextPage: at,
|
|
3059
3062
|
onSyncData: Wt
|
|
3060
3063
|
};
|
|
3061
|
-
},
|
|
3064
|
+
}, Vi = ({
|
|
3062
3065
|
queryFilters: e,
|
|
3063
3066
|
sliceFilter: t,
|
|
3064
3067
|
sliceFilters: n,
|
|
@@ -3068,7 +3071,7 @@ const Sl = ({
|
|
|
3068
3071
|
const d = [t, ...n || []];
|
|
3069
3072
|
for (const a of d) {
|
|
3070
3073
|
if (!a?.values?.length) continue;
|
|
3071
|
-
const b =
|
|
3074
|
+
const b = Hr([a]);
|
|
3072
3075
|
b.conditions?.length && (s = {
|
|
3073
3076
|
conditions: [...s?.conditions || [], ...b.conditions],
|
|
3074
3077
|
operator: "and"
|
|
@@ -3078,7 +3081,7 @@ const Sl = ({
|
|
|
3078
3081
|
if (s?.conditions?.length) {
|
|
3079
3082
|
const a = [], b = s.conditions.filter((m) => {
|
|
3080
3083
|
const C = m;
|
|
3081
|
-
if (C.key ===
|
|
3084
|
+
if (C.key === Ko) {
|
|
3082
3085
|
const w = C.value;
|
|
3083
3086
|
return w != null && String(w).trim() !== "" && a.push(String(w)), !1;
|
|
3084
3087
|
}
|
|
@@ -3100,7 +3103,7 @@ const Sl = ({
|
|
|
3100
3103
|
});
|
|
3101
3104
|
p = a.join(", "), s = b.length ? { ...s, conditions: b } : { ...s, conditions: [] };
|
|
3102
3105
|
}
|
|
3103
|
-
const i = s?.conditions?.length ?
|
|
3106
|
+
const i = s?.conditions?.length ? Ls(Kr(s)) : s;
|
|
3104
3107
|
return {
|
|
3105
3108
|
filterString: i?.conditions?.length ? JSON.stringify(i) : "",
|
|
3106
3109
|
filter: i,
|
|
@@ -3108,32 +3111,32 @@ const Sl = ({
|
|
|
3108
3111
|
combinedFilters: i,
|
|
3109
3112
|
displayFilters: h
|
|
3110
3113
|
};
|
|
3111
|
-
},
|
|
3114
|
+
}, Ll = (e) => {
|
|
3112
3115
|
const { queryFilters: t, sliceFilter: n, sliceFilters: o } = e;
|
|
3113
|
-
return H(() =>
|
|
3114
|
-
},
|
|
3116
|
+
return H(() => Vi(e), [t, n, o]);
|
|
3117
|
+
}, Ol = ({ foldersMap: e, tasksMap: t }) => H(() => {
|
|
3115
3118
|
const n = /* @__PURE__ */ new Map();
|
|
3116
3119
|
return e.forEach((o) => {
|
|
3117
3120
|
n.set(o.id, o);
|
|
3118
3121
|
}), t.forEach((o) => {
|
|
3119
3122
|
n.set(o.id, o);
|
|
3120
3123
|
}), n;
|
|
3121
|
-
}, [e, t]),
|
|
3124
|
+
}, [e, t]), Ps = "0".repeat(32), _l = (e, t, n) => {
|
|
3122
3125
|
if (!n || !e.length) return e;
|
|
3123
3126
|
const o = e.filter((s) => {
|
|
3124
3127
|
const d = t[s];
|
|
3125
3128
|
return !d || n.has(d);
|
|
3126
3129
|
});
|
|
3127
|
-
return o.length ? o : [
|
|
3128
|
-
},
|
|
3130
|
+
return o.length ? o : [Ps];
|
|
3131
|
+
}, zi = (e, t, n) => {
|
|
3129
3132
|
const o = e.find((a) => a.sliceType === "hierarchy"), s = e.find((a) => a.sliceType === "entityList"), d = Object.entries(o?.rowSelection || {}).filter(([, a]) => a).map(([a]) => a);
|
|
3130
3133
|
if (!(!!s && Object.entries(s.rowSelection).some(([a, b]) => b && !a.startsWith("folder-"))))
|
|
3131
3134
|
return { selectedFolders: d, folderScope: null, listPanelSelected: !1 };
|
|
3132
3135
|
const p = t?.length ? t : [], i = d.length && n ? new Set(n(d, !0)) : null;
|
|
3133
|
-
let
|
|
3136
|
+
let l = p;
|
|
3134
3137
|
if (i) {
|
|
3135
3138
|
const a = n && p.length ? new Set(n(p, !0)) : new Set(p);
|
|
3136
|
-
|
|
3139
|
+
l = [
|
|
3137
3140
|
.../* @__PURE__ */ new Set([
|
|
3138
3141
|
...p.filter((b) => i.has(b)),
|
|
3139
3142
|
...d.filter((b) => a.has(b))
|
|
@@ -3141,18 +3144,18 @@ const Sl = ({
|
|
|
3141
3144
|
];
|
|
3142
3145
|
}
|
|
3143
3146
|
return {
|
|
3144
|
-
selectedFolders:
|
|
3147
|
+
selectedFolders: l.length ? l : [Ps],
|
|
3145
3148
|
folderScope: i,
|
|
3146
3149
|
listPanelSelected: !0
|
|
3147
3150
|
};
|
|
3148
|
-
},
|
|
3151
|
+
}, Fl = ({
|
|
3149
3152
|
slices: e,
|
|
3150
3153
|
entityListFolderIds: t,
|
|
3151
3154
|
getChildFolderIds: n
|
|
3152
3155
|
}) => H(
|
|
3153
|
-
() =>
|
|
3156
|
+
() => zi(e, t, n),
|
|
3154
3157
|
[e, t, n]
|
|
3155
|
-
),
|
|
3158
|
+
), Nl = ({
|
|
3156
3159
|
attribFields: e,
|
|
3157
3160
|
allowedScopes: t = ["task", "folder"]
|
|
3158
3161
|
}) => H(
|
|
@@ -3160,7 +3163,7 @@ const Sl = ({
|
|
|
3160
3163
|
(n) => t.some((o) => n.scope?.includes(o))
|
|
3161
3164
|
),
|
|
3162
3165
|
[e, t]
|
|
3163
|
-
),
|
|
3166
|
+
), Ml = ({ expanded: e, setExpanded: t }) => {
|
|
3164
3167
|
const n = q(
|
|
3165
3168
|
(d) => {
|
|
3166
3169
|
t(Lt(d, e));
|
|
@@ -3180,7 +3183,7 @@ const Sl = ({
|
|
|
3180
3183
|
toggleExpanded: s,
|
|
3181
3184
|
expandedIds: o
|
|
3182
3185
|
};
|
|
3183
|
-
},
|
|
3186
|
+
}, Bi = ({
|
|
3184
3187
|
selectedCells: e,
|
|
3185
3188
|
setSelectedCells: t,
|
|
3186
3189
|
focusedCellId: n,
|
|
@@ -3202,12 +3205,12 @@ const Sl = ({
|
|
|
3202
3205
|
s(de(i || "")?.rowId || "") || p.add(i);
|
|
3203
3206
|
if (p.size > 0) {
|
|
3204
3207
|
const i = new Set(e);
|
|
3205
|
-
for (const
|
|
3206
|
-
i.delete(
|
|
3208
|
+
for (const l of p)
|
|
3209
|
+
i.delete(l);
|
|
3207
3210
|
t(i), p.has(n || "") && o(null);
|
|
3208
3211
|
}
|
|
3209
3212
|
}, [s, e, n, t, o, d]);
|
|
3210
|
-
},
|
|
3213
|
+
}, Ui = (e) => {
|
|
3211
3214
|
const { updateGroupBy: t } = dt(), { attribFields: n, scopes: o } = Ke(), s = e.startsWith("attrib_"), d = s ? e.replace("attrib_", "") : void 0, h = H(
|
|
3212
3215
|
() => s ? n.find((b) => b.name === d) : void 0,
|
|
3213
3216
|
[n, s, d]
|
|
@@ -3220,24 +3223,24 @@ const Sl = ({
|
|
|
3220
3223
|
return "productType";
|
|
3221
3224
|
}
|
|
3222
3225
|
if (["status", "assignees", "tags", "taskType"].includes(e)) return e;
|
|
3223
|
-
}, [e]), i = H(() => p ? s ? !!h &&
|
|
3226
|
+
}, [e]), i = H(() => p ? s ? !!h && Er(h, "task") : !0 : !1, [h, s, p]), l = H(() => s ? h?.data.title || h?.name || d || "Attribute" : e === "status" ? "Status" : e === "subType" ? "Type" : e === "assignees" ? "Assignees" : e === "tags" ? "Tags" : "Column", [h, d, e, s]), a = q(() => {
|
|
3224
3227
|
p && t({ id: p, desc: !1 });
|
|
3225
3228
|
}, [p, t]);
|
|
3226
3229
|
return {
|
|
3227
3230
|
targetGroupById: p,
|
|
3228
3231
|
canGroupThisColumn: i,
|
|
3229
|
-
groupLabel:
|
|
3232
|
+
groupLabel: l,
|
|
3230
3233
|
groupBySelectedColumn: a
|
|
3231
3234
|
};
|
|
3232
|
-
},
|
|
3235
|
+
}, $l = (e, t = "bottom") => {
|
|
3233
3236
|
const { contributions: n } = Cs("entityMenuItem"), { projectName: o } = Ue();
|
|
3234
3237
|
return q(
|
|
3235
3238
|
(s, d, h, p) => {
|
|
3236
|
-
const i =
|
|
3237
|
-
(T) =>
|
|
3239
|
+
const i = Qo(n, t).filter(
|
|
3240
|
+
(T) => ks(T, e)
|
|
3238
3241
|
);
|
|
3239
3242
|
if (!i.length) return;
|
|
3240
|
-
const
|
|
3243
|
+
const l = new Set(p.selectedCells), a = h.filter((T) => l.has(T.cellId)), b = a.length ? a : h.length ? h : [d], m = /* @__PURE__ */ new Map();
|
|
3241
3244
|
for (const T of b) {
|
|
3242
3245
|
const { entityId: I, entityType: r, isGroup: u, data: f } = T;
|
|
3243
3246
|
if (u || !I || !r || r === "unknown") continue;
|
|
@@ -3259,24 +3262,24 @@ const Sl = ({
|
|
|
3259
3262
|
id: T.key,
|
|
3260
3263
|
label: T.label,
|
|
3261
3264
|
icon: T.icon,
|
|
3262
|
-
command: () =>
|
|
3265
|
+
command: () => Sr(T, w)
|
|
3263
3266
|
}));
|
|
3264
3267
|
},
|
|
3265
3268
|
[n, o, e]
|
|
3266
3269
|
);
|
|
3267
|
-
},
|
|
3268
|
-
const [t, n] = Ge(/* @__PURE__ */ new Set()), [o, s] = Ge(null), [d, h] = Ge(!1), [p, i] = Ge(null), [
|
|
3270
|
+
}, Vl = ({ children: e }) => {
|
|
3271
|
+
const [t, n] = Ge(/* @__PURE__ */ new Set()), [o, s] = Ge(null), [d, h] = Ge(!1), [p, i] = Ge(null), [l, a] = Ge({
|
|
3269
3272
|
rowIdToIndex: /* @__PURE__ */ new Map(),
|
|
3270
3273
|
colIdToIndex: /* @__PURE__ */ new Map(),
|
|
3271
3274
|
indexToRowId: /* @__PURE__ */ new Map(),
|
|
3272
3275
|
indexToColId: /* @__PURE__ */ new Map()
|
|
3273
3276
|
}), b = (g) => JSON.stringify(Array.from(g.entries())), m = H(
|
|
3274
|
-
() =>
|
|
3277
|
+
() => l,
|
|
3275
3278
|
[
|
|
3276
|
-
b(
|
|
3277
|
-
b(
|
|
3278
|
-
b(
|
|
3279
|
-
b(
|
|
3279
|
+
b(l.rowIdToIndex),
|
|
3280
|
+
b(l.colIdToIndex),
|
|
3281
|
+
b(l.indexToRowId),
|
|
3282
|
+
b(l.indexToColId)
|
|
3280
3283
|
]
|
|
3281
3284
|
), C = He(!1), w = H(
|
|
3282
3285
|
() => Array.from(t).filter(
|
|
@@ -3284,40 +3287,40 @@ const Sl = ({
|
|
|
3284
3287
|
).map((g) => de(g)?.rowId),
|
|
3285
3288
|
[t]
|
|
3286
3289
|
);
|
|
3287
|
-
|
|
3290
|
+
Bi({
|
|
3288
3291
|
selectedCells: t,
|
|
3289
3292
|
setSelectedCells: n,
|
|
3290
3293
|
focusedCellId: o,
|
|
3291
3294
|
setFocusedCellId: s
|
|
3292
3295
|
});
|
|
3293
3296
|
const T = He(!1), I = q((g, x) => {
|
|
3294
|
-
const D = /* @__PURE__ */ new Map(),
|
|
3297
|
+
const D = /* @__PURE__ */ new Map(), N = /* @__PURE__ */ new Map(), z = /* @__PURE__ */ new Map(), B = /* @__PURE__ */ new Map();
|
|
3295
3298
|
g.forEach((X, P) => {
|
|
3296
3299
|
D.set(X, P), z.set(P, X);
|
|
3297
3300
|
}), x.forEach((X, P) => {
|
|
3298
|
-
|
|
3299
|
-
}), a({ rowIdToIndex: D, colIdToIndex:
|
|
3301
|
+
N.set(X, P), B.set(P, X);
|
|
3302
|
+
}), a({ rowIdToIndex: D, colIdToIndex: N, indexToRowId: z, indexToColId: B });
|
|
3300
3303
|
}, []), r = q((g, x) => {
|
|
3301
3304
|
n((D) => {
|
|
3302
|
-
let
|
|
3305
|
+
let N = new Set(g);
|
|
3303
3306
|
if (x.colId !== pe && x.colId !== je) {
|
|
3304
3307
|
const z = Array.from(D).filter(
|
|
3305
3308
|
(B) => de(B)?.colId === pe
|
|
3306
3309
|
);
|
|
3307
|
-
z.length && (
|
|
3310
|
+
z.length && (N = /* @__PURE__ */ new Set([...N, ...z]));
|
|
3308
3311
|
}
|
|
3309
|
-
return
|
|
3312
|
+
return N;
|
|
3310
3313
|
});
|
|
3311
3314
|
}, []), u = q(
|
|
3312
3315
|
(g, x, D) => {
|
|
3313
3316
|
D || r(/* @__PURE__ */ new Set(), g);
|
|
3314
|
-
const
|
|
3317
|
+
const N = m.rowIdToIndex.get(g.rowId) ?? 0, z = m.colIdToIndex.get(g.colId) ?? 0, B = m.rowIdToIndex.get(x.rowId) ?? 0, X = m.colIdToIndex.get(x.colId) ?? 0, P = Math.min(N, B), L = Math.max(N, B), G = Math.min(z, X), te = Math.max(z, X), be = new Set(D ? t : []);
|
|
3315
3318
|
for (let he = P; he <= L; he++) {
|
|
3316
3319
|
const re = m.indexToRowId.get(he);
|
|
3317
3320
|
if (re)
|
|
3318
3321
|
for (let ae = G; ae <= te; ae++) {
|
|
3319
3322
|
const Ae = m.indexToColId.get(ae);
|
|
3320
|
-
Ae && be.add(
|
|
3323
|
+
Ae && be.add(Me(re, Ae));
|
|
3321
3324
|
}
|
|
3322
3325
|
}
|
|
3323
3326
|
return be;
|
|
@@ -3326,8 +3329,8 @@ const Sl = ({
|
|
|
3326
3329
|
), f = q(
|
|
3327
3330
|
(g, x) => {
|
|
3328
3331
|
const D = de(g);
|
|
3329
|
-
D && (h(!0), T.current = x, C.current = t.has(g), x ? n((
|
|
3330
|
-
const z = new Set(
|
|
3332
|
+
D && (h(!0), T.current = x, C.current = t.has(g), x ? n((N) => {
|
|
3333
|
+
const z = new Set(N);
|
|
3331
3334
|
return z.has(g) ? (z.delete(g), o === g && (z.size > 0 ? s(Array.from(z)[Array.from(z).length - 1]) : s(null))) : (z.add(g), s(g), i(D)), z;
|
|
3332
3335
|
}) : t.size === 1 && t.has(g) && [pe, "name"].includes(D.colId) ? (n(/* @__PURE__ */ new Set()), i(null), s(null)) : (r(/* @__PURE__ */ new Set([g]), D), i(D), s(g)));
|
|
3333
3336
|
},
|
|
@@ -3338,18 +3341,18 @@ const Sl = ({
|
|
|
3338
3341
|
const D = de(g);
|
|
3339
3342
|
if (D)
|
|
3340
3343
|
if (x)
|
|
3341
|
-
n((
|
|
3342
|
-
const z = new Set(
|
|
3344
|
+
n((N) => {
|
|
3345
|
+
const z = new Set(N);
|
|
3343
3346
|
return de(g) && (C.current ? z.delete(g) : z.add(g)), z;
|
|
3344
3347
|
});
|
|
3345
3348
|
else {
|
|
3346
3349
|
if (T.current) return;
|
|
3347
|
-
const
|
|
3350
|
+
const N = u(
|
|
3348
3351
|
p,
|
|
3349
3352
|
D,
|
|
3350
3353
|
T.current
|
|
3351
3354
|
);
|
|
3352
|
-
r(
|
|
3355
|
+
r(N, D);
|
|
3353
3356
|
}
|
|
3354
3357
|
},
|
|
3355
3358
|
[d, p, u, r]
|
|
@@ -3357,33 +3360,33 @@ const Sl = ({
|
|
|
3357
3360
|
h(!1);
|
|
3358
3361
|
}, []), O = q(
|
|
3359
3362
|
(g, x, D) => {
|
|
3360
|
-
const
|
|
3361
|
-
if (
|
|
3363
|
+
const N = de(g);
|
|
3364
|
+
if (N)
|
|
3362
3365
|
if (D && p) {
|
|
3363
|
-
const z = u(p,
|
|
3364
|
-
r(z,
|
|
3366
|
+
const z = u(p, N, x);
|
|
3367
|
+
r(z, N);
|
|
3365
3368
|
} else x ? n((z) => {
|
|
3366
3369
|
const B = new Set(z);
|
|
3367
3370
|
return B.has(g) ? B.delete(g) : B.add(g), B;
|
|
3368
|
-
}) : (r(/* @__PURE__ */ new Set([g]),
|
|
3371
|
+
}) : (r(/* @__PURE__ */ new Set([g]), N), i(N));
|
|
3369
3372
|
},
|
|
3370
3373
|
[p, u, r]
|
|
3371
3374
|
), R = q((g) => {
|
|
3372
3375
|
s(g);
|
|
3373
3376
|
}, []), y = q(() => {
|
|
3374
3377
|
n(/* @__PURE__ */ new Set()), i(null), s(null);
|
|
3375
|
-
}, []),
|
|
3378
|
+
}, []), c = q((g) => t.has(g), [t]), E = q((g) => g === o, [o]), k = q((g) => de(g), []), F = q(
|
|
3376
3379
|
(g) => {
|
|
3377
|
-
if (!
|
|
3380
|
+
if (!c(g)) return [];
|
|
3378
3381
|
const x = de(g);
|
|
3379
3382
|
if (!x) return [];
|
|
3380
|
-
const D = m.rowIdToIndex.get(x.rowId),
|
|
3381
|
-
if (D === void 0 ||
|
|
3382
|
-
const z = m.indexToRowId.get(D - 1), B = m.indexToColId.get(
|
|
3383
|
+
const D = m.rowIdToIndex.get(x.rowId), N = m.colIdToIndex.get(x.colId);
|
|
3384
|
+
if (D === void 0 || N === void 0) return [];
|
|
3385
|
+
const z = m.indexToRowId.get(D - 1), B = m.indexToColId.get(N + 1), X = m.indexToRowId.get(D + 1), P = m.indexToColId.get(N - 1);
|
|
3383
3386
|
let L = Dt.None;
|
|
3384
|
-
return (!z || !t.has(
|
|
3387
|
+
return (!z || !t.has(Me(z, x.colId))) && (L |= Dt.Top), (!B || !t.has(Me(x.rowId, B))) && (L |= Dt.Right), (!X || !t.has(Me(X, x.colId))) && (L |= Dt.Bottom), (!P || !t.has(Me(x.rowId, P))) && (L |= Dt.Left), vo(L);
|
|
3385
3388
|
},
|
|
3386
|
-
[t, m,
|
|
3389
|
+
[t, m, c]
|
|
3387
3390
|
), V = H(
|
|
3388
3391
|
() => ({
|
|
3389
3392
|
selectedCells: t,
|
|
@@ -3402,7 +3405,7 @@ const Sl = ({
|
|
|
3402
3405
|
endSelection: S,
|
|
3403
3406
|
focusCell: R,
|
|
3404
3407
|
clearSelection: y,
|
|
3405
|
-
isCellSelected:
|
|
3408
|
+
isCellSelected: c,
|
|
3406
3409
|
isCellFocused: E,
|
|
3407
3410
|
getCellPositionFromId: k,
|
|
3408
3411
|
getCellBorderClasses: F
|
|
@@ -3424,17 +3427,17 @@ const Sl = ({
|
|
|
3424
3427
|
S,
|
|
3425
3428
|
R,
|
|
3426
3429
|
y,
|
|
3427
|
-
|
|
3430
|
+
c,
|
|
3428
3431
|
E,
|
|
3429
3432
|
k,
|
|
3430
3433
|
F
|
|
3431
3434
|
]
|
|
3432
3435
|
);
|
|
3433
|
-
return /* @__PURE__ */ U(
|
|
3434
|
-
},
|
|
3436
|
+
return /* @__PURE__ */ U(Eo.Provider, { value: V, children: e });
|
|
3437
|
+
}, zl = "count", Bl = (e) => e === "count" || e === "both", Ul = (e) => e === "percent" || e === "both", Gl = (e, t) => e && t ? "both" : e ? "count" : t ? "percent" : "none", Wl = "all", jl = (e) => e === "all" || e === "primary", Hl = (e) => e === "all" || e === "secondary", Kl = (e, t) => e && t ? "all" : e ? "primary" : t ? "secondary" : "none", ql = {
|
|
3435
3438
|
primary: "folders",
|
|
3436
3439
|
secondary: "tasks"
|
|
3437
|
-
},
|
|
3440
|
+
}, Gi = [
|
|
3438
3441
|
"invalid path",
|
|
3439
3442
|
"invalid key",
|
|
3440
3443
|
"invalid value",
|
|
@@ -3445,11 +3448,11 @@ const Sl = ({
|
|
|
3445
3448
|
"value type in list",
|
|
3446
3449
|
"empty path",
|
|
3447
3450
|
"json filter error"
|
|
3448
|
-
],
|
|
3451
|
+
], Wi = (e) => (e?.filter?.conditions ?? []).length > 0 || !!e?.search, ji = (e, t) => {
|
|
3449
3452
|
if (!e) return !1;
|
|
3450
3453
|
const n = hs(e).toLowerCase();
|
|
3451
|
-
return
|
|
3452
|
-
},
|
|
3454
|
+
return Gi.some((o) => n.includes(o)) ? !0 : Wi(t);
|
|
3455
|
+
}, Hi = (e = "Items") => `${e} were unable to load due to a corrupt filter.`, Ki = (e = []) => e.includes("product") ? "Products" : e.includes("version") ? "Versions" : e.includes("task") ? "Tasks" : e.includes("folder") ? "Folders" : "Items", Ql = (e, t, n) => `${e}-${t}-${n}`, gn = (e) => {
|
|
3453
3456
|
switch (e) {
|
|
3454
3457
|
case "boolean":
|
|
3455
3458
|
return !1;
|
|
@@ -3475,23 +3478,23 @@ const Sl = ({
|
|
|
3475
3478
|
[e.entityType + "Id"]: e.entityId
|
|
3476
3479
|
};
|
|
3477
3480
|
return e.entityType === "version" && "product" in e && e.product?.id && (t.productId = e.product?.id, "folder" in e.product && e.product?.folder?.id && (t.folderId = e.product?.folder.id)), t;
|
|
3478
|
-
}, on = "__",
|
|
3481
|
+
}, on = "__", qi = (e) => `${on}${e}`, Xl = (e, t) => `${e}${qi(t)}`, Ds = (e) => {
|
|
3479
3482
|
const t = e.lastIndexOf(on);
|
|
3480
3483
|
if (t === -1)
|
|
3481
3484
|
return null;
|
|
3482
3485
|
const n = e.slice(0, t), o = e.slice(t + on.length);
|
|
3483
3486
|
return { entityId: n, type: o };
|
|
3484
|
-
},
|
|
3487
|
+
}, Yl = (e) => e.includes(on) && Ds(e) !== null, Jl = (e, t) => Ds(e)?.type === t, Qi = (e) => "key" in e, Ls = (e) => ({
|
|
3485
3488
|
...e,
|
|
3486
3489
|
conditions: e.conditions?.map((t) => {
|
|
3487
|
-
if (!
|
|
3490
|
+
if (!Qi(t)) return Ls(t);
|
|
3488
3491
|
if ((t.operator === "isnull" || t.operator === "notnull") && t.value == null) {
|
|
3489
3492
|
const { value: n, ...o } = t;
|
|
3490
3493
|
return o;
|
|
3491
3494
|
}
|
|
3492
3495
|
return t;
|
|
3493
3496
|
})
|
|
3494
|
-
}),
|
|
3497
|
+
}), Xi = (e = 50) => {
|
|
3495
3498
|
const [t, n] = Ge([]), [o, s] = Ge([]), d = q(
|
|
3496
3499
|
(b, m) => {
|
|
3497
3500
|
b.length && (n((C) => {
|
|
@@ -3518,7 +3521,7 @@ const Sl = ({
|
|
|
3518
3521
|
if (o.length === 0) return null;
|
|
3519
3522
|
const b = [...o], m = b.pop();
|
|
3520
3523
|
return s(b), n((C) => [...C, m]), m.redo ? h(m.redo) : null;
|
|
3521
|
-
}, [o]),
|
|
3524
|
+
}, [o]), l = q((b) => {
|
|
3522
3525
|
n((m) => m.slice(0, Math.max(0, m.length - b))), s((m) => m.slice(0, Math.max(0, m.length - b)));
|
|
3523
3526
|
}, []), a = q(() => {
|
|
3524
3527
|
n([]), s([]);
|
|
@@ -3530,10 +3533,12 @@ const Sl = ({
|
|
|
3530
3533
|
canUndo: t.length > 0,
|
|
3531
3534
|
canRedo: o.length > 0,
|
|
3532
3535
|
clearHistory: a,
|
|
3533
|
-
removeHistoryEntries:
|
|
3536
|
+
removeHistoryEntries: l
|
|
3534
3537
|
};
|
|
3535
|
-
},
|
|
3538
|
+
}, Yi = (e = [], t) => {
|
|
3536
3539
|
for (const { isAttrib: n, value: o, field: s } of e) {
|
|
3540
|
+
if (!n && xs.includes(s))
|
|
3541
|
+
throw new Error(`“${s}” is read-only`);
|
|
3537
3542
|
if (!n) continue;
|
|
3538
3543
|
const d = t.find((f) => f.name === s);
|
|
3539
3544
|
if (!d) continue;
|
|
@@ -3556,7 +3561,7 @@ const Sl = ({
|
|
|
3556
3561
|
"maxLength",
|
|
3557
3562
|
"minItems",
|
|
3558
3563
|
"maxItems"
|
|
3559
|
-
],
|
|
3564
|
+
], l = Object.entries(d.data).reduce((f, [v, S]) => (i.includes(v) && (f[v] = S), f), {}), { ge: a, gt: b, le: m, lt: C, minLength: w, maxLength: T, minItems: I, maxItems: r } = l, u = d.data.regex;
|
|
3560
3565
|
if (typeof h == "number") {
|
|
3561
3566
|
if (a != null && h < a) throw new Error(`“${s}” must be ≥ ${a}`);
|
|
3562
3567
|
if (b != null && h <= b) throw new Error(`“${s}” must be > ${b}`);
|
|
@@ -3576,20 +3581,20 @@ const Sl = ({
|
|
|
3576
3581
|
throw new Error(`“${s}” items must be ≤ ${r}`);
|
|
3577
3582
|
}
|
|
3578
3583
|
}
|
|
3579
|
-
},
|
|
3584
|
+
}, Zl = ({ children: e }) => {
|
|
3580
3585
|
const [t, n] = Ge(null), o = He(null), s = q(() => o.current, []), d = q((g) => {
|
|
3581
3586
|
o.current = g;
|
|
3582
3587
|
}, []), h = q((g) => {
|
|
3583
3588
|
o.current = null, n(g);
|
|
3584
|
-
}, []), p = q((g) => g === t, [t]), i =
|
|
3585
|
-
pushHistory:
|
|
3589
|
+
}, []), p = q((g) => g === t, [t]), i = Xi(), {
|
|
3590
|
+
pushHistory: l,
|
|
3586
3591
|
undo: a,
|
|
3587
3592
|
redo: b,
|
|
3588
3593
|
canUndo: m,
|
|
3589
3594
|
canRedo: C,
|
|
3590
3595
|
removeHistoryEntries: w
|
|
3591
|
-
} = i, { selectedCells: T } = et(), { updateEntities: I, inheritFromParent: r } =
|
|
3592
|
-
pushHistory:
|
|
3596
|
+
} = i, { selectedCells: T } = et(), { updateEntities: I, inheritFromParent: r } = Ai({
|
|
3597
|
+
pushHistory: l,
|
|
3593
3598
|
removeHistoryEntries: w
|
|
3594
3599
|
}), { attribFields: u, getEntityById: f, isRowReadOnly: v } = Ke(), { projectName: S } = Ue(), [O] = bs(), R = q(
|
|
3595
3600
|
(g) => {
|
|
@@ -3602,13 +3607,13 @@ const Sl = ({
|
|
|
3602
3607
|
const D = R(g);
|
|
3603
3608
|
if (D.length)
|
|
3604
3609
|
try {
|
|
3605
|
-
return
|
|
3606
|
-
} catch (
|
|
3607
|
-
return Fe.error(
|
|
3610
|
+
return Yi(D, u), await I(D, x);
|
|
3611
|
+
} catch (N) {
|
|
3612
|
+
return Fe.error(N.message), Promise.reject(N);
|
|
3608
3613
|
}
|
|
3609
3614
|
},
|
|
3610
3615
|
[I, u, R]
|
|
3611
|
-
),
|
|
3616
|
+
), c = q(
|
|
3612
3617
|
async (g = [], x = !0) => {
|
|
3613
3618
|
const D = R(g);
|
|
3614
3619
|
if (D.length)
|
|
@@ -3625,13 +3630,13 @@ const Sl = ({
|
|
|
3625
3630
|
}
|
|
3626
3631
|
if (x && x.length > 0)
|
|
3627
3632
|
try {
|
|
3628
|
-
await
|
|
3633
|
+
await c(x, !1);
|
|
3629
3634
|
} catch {
|
|
3630
3635
|
Fe.error("Failed to inherit changes");
|
|
3631
3636
|
}
|
|
3632
|
-
D && D.length > 0 && D.forEach((
|
|
3637
|
+
D && D.length > 0 && D.forEach((N) => {
|
|
3633
3638
|
try {
|
|
3634
|
-
|
|
3639
|
+
N();
|
|
3635
3640
|
} catch {
|
|
3636
3641
|
Fe.error("Failed to execute custom undo action");
|
|
3637
3642
|
}
|
|
@@ -3646,20 +3651,20 @@ const Sl = ({
|
|
|
3646
3651
|
}
|
|
3647
3652
|
if (x && x.length > 0)
|
|
3648
3653
|
try {
|
|
3649
|
-
await
|
|
3654
|
+
await c(x, !1);
|
|
3650
3655
|
} catch {
|
|
3651
3656
|
Fe.error("Failed to inherit changes");
|
|
3652
3657
|
}
|
|
3653
|
-
D && D.length > 0 && D.forEach((
|
|
3658
|
+
D && D.length > 0 && D.forEach((N) => {
|
|
3654
3659
|
try {
|
|
3655
|
-
|
|
3660
|
+
N();
|
|
3656
3661
|
} catch {
|
|
3657
3662
|
Fe.error("Failed to execute custom redo action");
|
|
3658
3663
|
}
|
|
3659
3664
|
});
|
|
3660
3665
|
}, F = q(
|
|
3661
3666
|
async (g) => {
|
|
3662
|
-
const x = [], D = [],
|
|
3667
|
+
const x = [], D = [], N = [];
|
|
3663
3668
|
for (const z of g) {
|
|
3664
3669
|
const { colId: B, rowId: X } = de(z) || {};
|
|
3665
3670
|
if (!B || !X) {
|
|
@@ -3677,7 +3682,7 @@ const Sl = ({
|
|
|
3677
3682
|
if (B === "subtasks") {
|
|
3678
3683
|
if (P.entityType === "task") {
|
|
3679
3684
|
const he = "subtasks" in P && P.subtasks || [];
|
|
3680
|
-
|
|
3685
|
+
N.push({ taskId: X, previousSubtasks: he });
|
|
3681
3686
|
}
|
|
3682
3687
|
continue;
|
|
3683
3688
|
}
|
|
@@ -3727,15 +3732,15 @@ const Sl = ({
|
|
|
3727
3732
|
}
|
|
3728
3733
|
if (D.length > 0)
|
|
3729
3734
|
try {
|
|
3730
|
-
await
|
|
3735
|
+
await c(D, !0);
|
|
3731
3736
|
} catch {
|
|
3732
3737
|
Fe.error("Failed to inherit parent values for cleared cells");
|
|
3733
3738
|
}
|
|
3734
|
-
if (
|
|
3739
|
+
if (N.length > 0)
|
|
3735
3740
|
try {
|
|
3736
|
-
|
|
3741
|
+
l && N.forEach(({ taskId: B, previousSubtasks: X }) => {
|
|
3737
3742
|
const P = X || [];
|
|
3738
|
-
|
|
3743
|
+
l([() => {
|
|
3739
3744
|
O({ projectName: S, taskId: B, subtasks: P }).unwrap().catch(() => {
|
|
3740
3745
|
});
|
|
3741
3746
|
}], [() => {
|
|
@@ -3743,23 +3748,23 @@ const Sl = ({
|
|
|
3743
3748
|
});
|
|
3744
3749
|
}]);
|
|
3745
3750
|
});
|
|
3746
|
-
const z =
|
|
3751
|
+
const z = N.map(
|
|
3747
3752
|
({ taskId: B }) => O({ projectName: S, taskId: B, subtasks: [] }).unwrap()
|
|
3748
3753
|
);
|
|
3749
3754
|
await Promise.all(z);
|
|
3750
3755
|
} catch {
|
|
3751
3756
|
Fe.error("Failed to clear subtasks");
|
|
3752
3757
|
}
|
|
3753
|
-
x.length === 0 && D.length === 0 &&
|
|
3758
|
+
x.length === 0 && D.length === 0 && N.length === 0 && Fe.warn("No valid cells selected to clear");
|
|
3754
3759
|
},
|
|
3755
3760
|
[
|
|
3756
3761
|
u,
|
|
3757
3762
|
y,
|
|
3758
|
-
|
|
3763
|
+
c,
|
|
3759
3764
|
v,
|
|
3760
3765
|
S,
|
|
3761
3766
|
O,
|
|
3762
|
-
|
|
3767
|
+
l,
|
|
3763
3768
|
f
|
|
3764
3769
|
]
|
|
3765
3770
|
), V = H(
|
|
@@ -3768,7 +3773,7 @@ const Sl = ({
|
|
|
3768
3773
|
setEditingCellId: h,
|
|
3769
3774
|
isEditing: p,
|
|
3770
3775
|
updateEntities: y,
|
|
3771
|
-
inheritFromParent:
|
|
3776
|
+
inheritFromParent: c,
|
|
3772
3777
|
undo: E,
|
|
3773
3778
|
redo: k,
|
|
3774
3779
|
history: i,
|
|
@@ -3779,7 +3784,7 @@ const Sl = ({
|
|
|
3779
3784
|
t,
|
|
3780
3785
|
p,
|
|
3781
3786
|
y,
|
|
3782
|
-
|
|
3787
|
+
c,
|
|
3783
3788
|
E,
|
|
3784
3789
|
k,
|
|
3785
3790
|
i,
|
|
@@ -3808,8 +3813,8 @@ const Sl = ({
|
|
|
3808
3813
|
}
|
|
3809
3814
|
};
|
|
3810
3815
|
return document.addEventListener("keydown", g), () => document.removeEventListener("keydown", g);
|
|
3811
|
-
}, [m, C, E, k, T, F]), /* @__PURE__ */ U(
|
|
3812
|
-
},
|
|
3816
|
+
}, [m, C, E, k, T, F]), /* @__PURE__ */ U(xo.Provider, { value: V, children: e });
|
|
3817
|
+
}, Ji = ({
|
|
3813
3818
|
attributes: e,
|
|
3814
3819
|
listeners: t
|
|
3815
3820
|
}) => /* @__PURE__ */ U(
|
|
@@ -3834,7 +3839,7 @@ const Sl = ({
|
|
|
3834
3839
|
},
|
|
3835
3840
|
children: /* @__PURE__ */ U(Ft, { icon: "drag_handle" })
|
|
3836
3841
|
}
|
|
3837
|
-
),
|
|
3842
|
+
), Zi = ({
|
|
3838
3843
|
header: e,
|
|
3839
3844
|
canHide: t,
|
|
3840
3845
|
canPin: n,
|
|
@@ -3845,21 +3850,21 @@ const Sl = ({
|
|
|
3845
3850
|
isOpen: p,
|
|
3846
3851
|
extraMenuItems: i
|
|
3847
3852
|
}) => {
|
|
3848
|
-
const { column:
|
|
3853
|
+
const { column: l } = e, a = String(l.id), { toggleMenuOpen: b } = ws(), { updateGroupBy: m, groupBy: C, sorting: w } = dt(), { canGroupThisColumn: T, groupLabel: I, groupBySelectedColumn: r, targetGroupById: u } = Ui(a);
|
|
3849
3854
|
if (s)
|
|
3850
3855
|
return null;
|
|
3851
|
-
const f = (
|
|
3852
|
-
b(
|
|
3853
|
-
}, v =
|
|
3856
|
+
const f = (c = !0) => {
|
|
3857
|
+
b(c && h || !1);
|
|
3858
|
+
}, v = l.getIsPinned(), S = l.getIsVisible(), O = l.getIsSorted(), R = !!O && w.length > 1, y = [];
|
|
3854
3859
|
if (n) {
|
|
3855
|
-
const
|
|
3860
|
+
const c = v === "left";
|
|
3856
3861
|
y.push({
|
|
3857
3862
|
id: "pin",
|
|
3858
|
-
label:
|
|
3863
|
+
label: c ? "Unpin column" : "Pin column",
|
|
3859
3864
|
icon: "push_pin",
|
|
3860
|
-
selected:
|
|
3865
|
+
selected: c,
|
|
3861
3866
|
onClick: () => {
|
|
3862
|
-
|
|
3867
|
+
c ? l.pin(!1) : l.pin("left"), f(!1);
|
|
3863
3868
|
}
|
|
3864
3869
|
});
|
|
3865
3870
|
}
|
|
@@ -3873,7 +3878,7 @@ const Sl = ({
|
|
|
3873
3878
|
className: "sort-asc-icon",
|
|
3874
3879
|
selected: O === "asc",
|
|
3875
3880
|
onClick: () => {
|
|
3876
|
-
|
|
3881
|
+
l.toggleSorting(!1, R), f(!1);
|
|
3877
3882
|
}
|
|
3878
3883
|
}), y.push({
|
|
3879
3884
|
id: "sort-desc",
|
|
@@ -3882,26 +3887,26 @@ const Sl = ({
|
|
|
3882
3887
|
className: "sort-desc-icon",
|
|
3883
3888
|
selected: O === "desc",
|
|
3884
3889
|
onClick: () => {
|
|
3885
|
-
|
|
3890
|
+
l.toggleSorting(!0, R), f(!1);
|
|
3886
3891
|
}
|
|
3887
3892
|
}), !O && w.length > 0 && w.length < En && y.push({
|
|
3888
3893
|
id: "sort-add",
|
|
3889
3894
|
label: "Add to sort",
|
|
3890
3895
|
icon: "add",
|
|
3891
3896
|
onClick: () => {
|
|
3892
|
-
|
|
3897
|
+
l.toggleSorting(!1, !0), f(!1);
|
|
3893
3898
|
}
|
|
3894
3899
|
})), o && t && y.push({
|
|
3895
3900
|
id: "divider",
|
|
3896
3901
|
type: "divider"
|
|
3897
3902
|
}), T && a !== "name" && a !== "thumbnail") {
|
|
3898
|
-
const
|
|
3903
|
+
const c = C?.id === u;
|
|
3899
3904
|
y.push({
|
|
3900
3905
|
id: "group-by",
|
|
3901
|
-
label:
|
|
3906
|
+
label: c ? "Ungroup" : `Group by ${I}`,
|
|
3902
3907
|
icon: "splitscreen",
|
|
3903
3908
|
onClick: () => {
|
|
3904
|
-
|
|
3909
|
+
c ? m(void 0) : r(), f(!1);
|
|
3905
3910
|
}
|
|
3906
3911
|
});
|
|
3907
3912
|
}
|
|
@@ -3910,34 +3915,34 @@ const Sl = ({
|
|
|
3910
3915
|
label: S ? "Hide column" : "Show column",
|
|
3911
3916
|
icon: S ? "visibility_off" : "visibility",
|
|
3912
3917
|
onClick: () => {
|
|
3913
|
-
|
|
3918
|
+
l.toggleVisibility(), f(!1);
|
|
3914
3919
|
}
|
|
3915
3920
|
}), i?.length) {
|
|
3916
3921
|
y.length && y.push({ id: "divider", type: "divider" });
|
|
3917
|
-
for (const
|
|
3922
|
+
for (const c of i)
|
|
3918
3923
|
y.push({
|
|
3919
|
-
...
|
|
3920
|
-
onClick:
|
|
3921
|
-
|
|
3924
|
+
...c,
|
|
3925
|
+
onClick: c.onClick ? () => {
|
|
3926
|
+
c.onClick?.(), f(!1);
|
|
3922
3927
|
} : void 0
|
|
3923
3928
|
});
|
|
3924
3929
|
}
|
|
3925
3930
|
return y.length === 0 ? null : /* @__PURE__ */ U(
|
|
3926
|
-
|
|
3931
|
+
kr,
|
|
3927
3932
|
{
|
|
3928
3933
|
className: d,
|
|
3929
3934
|
menuItems: y,
|
|
3930
3935
|
menuId: h || `column-menu-${e.id}`
|
|
3931
3936
|
}
|
|
3932
3937
|
);
|
|
3933
|
-
}, os = 60, Zt = 150, rs = 50, is = [je, pe],
|
|
3938
|
+
}, os = 60, Zt = 150, rs = 50, is = [je, pe], ec = ({ children: e }) => {
|
|
3934
3939
|
const { columnOrder: t, updateColumnOrder: n, columnPinning: o, columnSizing: s } = dt(), {
|
|
3935
3940
|
restrictToSection: d,
|
|
3936
3941
|
setDragPinnedState: h,
|
|
3937
3942
|
clearDragPinnedState: p,
|
|
3938
3943
|
activePinnedState: i,
|
|
3939
|
-
setCachedBoundary:
|
|
3940
|
-
} =
|
|
3944
|
+
setCachedBoundary: l
|
|
3945
|
+
} = xr({ columnPinning: o, columnSizing: s }), a = He({
|
|
3941
3946
|
cursorX: 0,
|
|
3942
3947
|
container: null,
|
|
3943
3948
|
boundaryX: 0,
|
|
@@ -3946,24 +3951,24 @@ const Sl = ({
|
|
|
3946
3951
|
isScrolling: !1,
|
|
3947
3952
|
isColumnDrag: !1,
|
|
3948
3953
|
isPinnedDrag: null
|
|
3949
|
-
}), b =
|
|
3950
|
-
fn(
|
|
3951
|
-
fn(
|
|
3952
|
-
fn(
|
|
3954
|
+
}), b = Rr(
|
|
3955
|
+
fn(Ar, { activationConstraint: { distance: 5 } }),
|
|
3956
|
+
fn(Pr, { activationConstraint: { delay: 100, tolerance: 5 } }),
|
|
3957
|
+
fn(Dr, {})
|
|
3953
3958
|
), m = H(() => [d], [d]), C = o.left || [], w = q(() => {
|
|
3954
|
-
const
|
|
3955
|
-
if (!
|
|
3956
|
-
const E =
|
|
3959
|
+
const c = a.current.container;
|
|
3960
|
+
if (!c) return 0;
|
|
3961
|
+
const E = c.querySelector("th.last-pinned-left");
|
|
3957
3962
|
if (E) return E.getBoundingClientRect().right;
|
|
3958
3963
|
const k = C.reduce((F, V) => F + (s[V] || 150), 24);
|
|
3959
|
-
return
|
|
3964
|
+
return c.getBoundingClientRect().left + k;
|
|
3960
3965
|
}, [C, s]), T = q(() => t.findIndex(
|
|
3961
|
-
(
|
|
3966
|
+
(c) => !C.includes(c) && !is.includes(c)
|
|
3962
3967
|
), [t, C]), I = q(
|
|
3963
|
-
(
|
|
3964
|
-
const { active: E, droppableContainers: k } =
|
|
3968
|
+
(c) => {
|
|
3969
|
+
const { active: E, droppableContainers: k } = c;
|
|
3965
3970
|
if (i.current === null || i.current)
|
|
3966
|
-
return Xn(
|
|
3971
|
+
return Xn(c);
|
|
3967
3972
|
if (a.current.cursorX <= a.current.boundaryX + rs) {
|
|
3968
3973
|
const F = t.find(
|
|
3969
3974
|
(V) => !C.includes(V) && !is.includes(V)
|
|
@@ -3973,36 +3978,36 @@ const Sl = ({
|
|
|
3973
3978
|
if (V) return [{ id: F, data: { droppableContainer: V } }];
|
|
3974
3979
|
}
|
|
3975
3980
|
}
|
|
3976
|
-
return Xn(
|
|
3981
|
+
return Xn(c);
|
|
3977
3982
|
},
|
|
3978
3983
|
[t, C]
|
|
3979
3984
|
), r = q(() => {
|
|
3980
3985
|
try {
|
|
3981
|
-
const
|
|
3982
|
-
if (!
|
|
3986
|
+
const c = a.current;
|
|
3987
|
+
if (!c.container || !c.isScrolling || !c.isColumnDrag)
|
|
3983
3988
|
return;
|
|
3984
|
-
const E =
|
|
3989
|
+
const E = c.boundaryX + 20;
|
|
3985
3990
|
let k = 0;
|
|
3986
|
-
if (
|
|
3987
|
-
const F = Math.min((E -
|
|
3991
|
+
if (c.isPinnedDrag === !1 && c.cursorX <= E) {
|
|
3992
|
+
const F = Math.min((E - c.cursorX) / Zt, 1);
|
|
3988
3993
|
k = -os * (0.3 + F * 0.7);
|
|
3989
|
-
} else if (
|
|
3994
|
+
} else if (c.cursorX >= c.containerRight - Zt) {
|
|
3990
3995
|
const F = Math.min(
|
|
3991
|
-
(
|
|
3996
|
+
(c.cursorX - (c.containerRight - Zt)) / Zt,
|
|
3992
3997
|
1
|
|
3993
3998
|
);
|
|
3994
3999
|
k = os * (0.3 + F * 0.7);
|
|
3995
4000
|
}
|
|
3996
|
-
k !== 0 && (
|
|
3997
|
-
} catch (
|
|
3998
|
-
console.error("[DND] scrollLoop error:",
|
|
4001
|
+
k !== 0 && (c.container.scrollLeft += k), c.scrollRAF = requestAnimationFrame(r);
|
|
4002
|
+
} catch (c) {
|
|
4003
|
+
console.error("[DND] scrollLoop error:", c), f();
|
|
3999
4004
|
}
|
|
4000
4005
|
}, []), u = q(() => {
|
|
4001
4006
|
a.current.isScrolling || (a.current.isScrolling = !0, a.current.scrollRAF = requestAnimationFrame(r));
|
|
4002
4007
|
}, [r]), f = () => {
|
|
4003
4008
|
a.current.isScrolling = !1, a.current.scrollRAF && (cancelAnimationFrame(a.current.scrollRAF), a.current.scrollRAF = null);
|
|
4004
|
-
}, v = q((
|
|
4005
|
-
a.current.cursorX =
|
|
4009
|
+
}, v = q((c) => {
|
|
4010
|
+
a.current.cursorX = c.clientX;
|
|
4006
4011
|
}, []), S = () => {
|
|
4007
4012
|
f(), window.removeEventListener("mousemove", v), a.current = {
|
|
4008
4013
|
cursorX: 0,
|
|
@@ -4016,28 +4021,28 @@ const Sl = ({
|
|
|
4016
4021
|
};
|
|
4017
4022
|
};
|
|
4018
4023
|
return /* @__PURE__ */ U(
|
|
4019
|
-
|
|
4024
|
+
Lr,
|
|
4020
4025
|
{
|
|
4021
4026
|
sensors: b,
|
|
4022
4027
|
collisionDetection: I,
|
|
4023
4028
|
modifiers: m,
|
|
4024
|
-
onDragStart: (
|
|
4025
|
-
if (
|
|
4026
|
-
const E = document.querySelector("[data-column-dnd-container]"), k = E?.getBoundingClientRect(), F = C.includes(
|
|
4027
|
-
a.current.container = E, a.current.containerRight = k?.right ?? 0, a.current.boundaryX = w(), a.current.isColumnDrag = !0, a.current.isPinnedDrag = F, h(
|
|
4029
|
+
onDragStart: (c) => {
|
|
4030
|
+
if (c.active.data.current?.type !== "column") return;
|
|
4031
|
+
const E = document.querySelector("[data-column-dnd-container]"), k = E?.getBoundingClientRect(), F = C.includes(c.active.id);
|
|
4032
|
+
a.current.container = E, a.current.containerRight = k?.right ?? 0, a.current.boundaryX = w(), a.current.isColumnDrag = !0, a.current.isPinnedDrag = F, h(c.active.id), l(a.current.boundaryX), window.addEventListener("mousemove", v), u();
|
|
4028
4033
|
},
|
|
4029
|
-
onDragEnd: (
|
|
4034
|
+
onDragEnd: (c) => {
|
|
4030
4035
|
p();
|
|
4031
|
-
const { active: E, over: k } =
|
|
4036
|
+
const { active: E, over: k } = c;
|
|
4032
4037
|
if (!E || !a.current.isColumnDrag) {
|
|
4033
4038
|
S();
|
|
4034
4039
|
return;
|
|
4035
4040
|
}
|
|
4036
4041
|
const F = E.id, V = C.includes(F);
|
|
4037
|
-
if ((!k || E.id === k.id) && !V &&
|
|
4038
|
-
if (
|
|
4039
|
-
const D = T(),
|
|
4040
|
-
D !== -1 &&
|
|
4042
|
+
if ((!k || E.id === k.id) && !V && c.active.rect.current.translated) {
|
|
4043
|
+
if (c.active.rect.current.translated.left <= a.current.boundaryX + rs) {
|
|
4044
|
+
const D = T(), N = t.indexOf(F);
|
|
4045
|
+
D !== -1 && N !== -1 && N !== D && n(Yn(t, N, D));
|
|
4041
4046
|
}
|
|
4042
4047
|
S();
|
|
4043
4048
|
return;
|
|
@@ -4055,7 +4060,7 @@ const Sl = ({
|
|
|
4055
4060
|
children: e
|
|
4056
4061
|
}
|
|
4057
4062
|
);
|
|
4058
|
-
},
|
|
4063
|
+
}, ea = (e, t) => {
|
|
4059
4064
|
const n = e.getFlatHeaders(), o = e.getState().columnSizingInfo;
|
|
4060
4065
|
return H(() => {
|
|
4061
4066
|
const d = {};
|
|
@@ -4065,7 +4070,7 @@ const Sl = ({
|
|
|
4065
4070
|
}
|
|
4066
4071
|
return d;
|
|
4067
4072
|
}, [o, t, n]);
|
|
4068
|
-
},
|
|
4073
|
+
}, ta = ({
|
|
4069
4074
|
visibleColumns: e,
|
|
4070
4075
|
tableContainerRef: t,
|
|
4071
4076
|
columnPinning: n,
|
|
@@ -4073,7 +4078,7 @@ const Sl = ({
|
|
|
4073
4078
|
columnOrder: s
|
|
4074
4079
|
}) => {
|
|
4075
4080
|
const d = H(() => e.filter((w) => w.getIsPinned() === "left").map((w) => w.getIndex()), [e, n]), [h, p] = Ge(null);
|
|
4076
|
-
|
|
4081
|
+
Or({
|
|
4077
4082
|
onDragStart(w) {
|
|
4078
4083
|
if (w.active.data?.current?.type === "column") {
|
|
4079
4084
|
const T = e.findIndex((I) => I.id === w.active.id);
|
|
@@ -4093,7 +4098,7 @@ const Sl = ({
|
|
|
4093
4098
|
for (let T = 0; T <= w; T++)
|
|
4094
4099
|
i.push(T);
|
|
4095
4100
|
}
|
|
4096
|
-
const
|
|
4101
|
+
const l = cs({
|
|
4097
4102
|
count: e.length,
|
|
4098
4103
|
estimateSize: (w) => e[w].getSize(),
|
|
4099
4104
|
//estimate width of each column for accurate scrollbar dragging
|
|
@@ -4115,18 +4120,18 @@ const Sl = ({
|
|
|
4115
4120
|
return Array.from(v).sort((S, O) => S - O);
|
|
4116
4121
|
}
|
|
4117
4122
|
}), a = H(
|
|
4118
|
-
() =>
|
|
4119
|
-
|
|
4123
|
+
() => ur(() => {
|
|
4124
|
+
l.measure();
|
|
4120
4125
|
}, 1e3),
|
|
4121
|
-
[
|
|
4126
|
+
[l]
|
|
4122
4127
|
);
|
|
4123
|
-
|
|
4128
|
+
Js(() => {
|
|
4124
4129
|
a();
|
|
4125
4130
|
}, [a, o, s]);
|
|
4126
|
-
const b =
|
|
4131
|
+
const b = l.getVirtualItems();
|
|
4127
4132
|
let m, C;
|
|
4128
|
-
if (
|
|
4129
|
-
const w =
|
|
4133
|
+
if (l && b.length) {
|
|
4134
|
+
const w = l.getTotalSize(), T = b.findIndex(
|
|
4130
4135
|
(r) => !i.includes(r.index)
|
|
4131
4136
|
);
|
|
4132
4137
|
if (T !== -1) {
|
|
@@ -4141,13 +4146,13 @@ const Sl = ({
|
|
|
4141
4146
|
C = Math.max(0, w - I);
|
|
4142
4147
|
}
|
|
4143
4148
|
return {
|
|
4144
|
-
columnVirtualizer:
|
|
4149
|
+
columnVirtualizer: l,
|
|
4145
4150
|
virtualPaddingLeft: m,
|
|
4146
4151
|
virtualPaddingRight: C
|
|
4147
4152
|
};
|
|
4148
4153
|
};
|
|
4149
|
-
function
|
|
4150
|
-
const { attribFields: e, getEntityById: t, onOpenPlayer: n, playerOpen: o } = Ke(), { canWriteLabelPermission: s, canWriteNamePermission: d } = Tn(), h = s || d, { focusedCellId: p, gridMap: i, selectCell:
|
|
4154
|
+
function na() {
|
|
4155
|
+
const { attribFields: e, getEntityById: t, onOpenPlayer: n, playerOpen: o } = Ke(), { canWriteLabelPermission: s, canWriteNamePermission: d } = Tn(), h = s || d, { focusedCellId: p, gridMap: i, selectCell: l, focusCell: a, clearSelection: b, setFocusedCellId: m } = et(), { setEditingCellId: C, editingCellId: w } = ut(), { setSelectedEntity: T } = fs(), I = q(
|
|
4151
4156
|
(u) => {
|
|
4152
4157
|
a(u), console.log(u), requestAnimationFrame(() => document.getElementById(u)?.closest("td")?.focus());
|
|
4153
4158
|
},
|
|
@@ -4161,9 +4166,9 @@ function ea() {
|
|
|
4161
4166
|
if (!O && (f.tagName === "INPUT" || f.tagName === "TEXTAREA" || f.isContentEditable || f.getAttribute("role") === "textbox" || f.tagName === "LI") || o && u.key !== "ArrowDown" && u.key !== "ArrowUp" || w || !p) return;
|
|
4162
4167
|
const R = de(p);
|
|
4163
4168
|
if (!R) return;
|
|
4164
|
-
const { rowId: y, colId:
|
|
4169
|
+
const { rowId: y, colId: c } = R, E = i.rowIdToIndex.get(y), k = i.colIdToIndex.get(c);
|
|
4165
4170
|
if (E === void 0 || k === void 0) return;
|
|
4166
|
-
const F =
|
|
4171
|
+
const F = c.startsWith("attrib_") && e.find((g) => g.name === c.replace("attrib_", ""))?.readOnly || f.closest("td")?.querySelector(`.${ko}`) !== null, V = (g) => {
|
|
4167
4172
|
if (n) {
|
|
4168
4173
|
const x = t(g);
|
|
4169
4174
|
if (x) {
|
|
@@ -4177,8 +4182,8 @@ function ea() {
|
|
|
4177
4182
|
if (u.preventDefault(), E > 0) {
|
|
4178
4183
|
const g = i.indexToRowId.get(E - 1);
|
|
4179
4184
|
if (g) {
|
|
4180
|
-
const x =
|
|
4181
|
-
|
|
4185
|
+
const x = Me(g, c);
|
|
4186
|
+
l(x, u.shiftKey, u.shiftKey), O ? a(x) : I(x), o && V(g);
|
|
4182
4187
|
}
|
|
4183
4188
|
}
|
|
4184
4189
|
break;
|
|
@@ -4187,8 +4192,8 @@ function ea() {
|
|
|
4187
4192
|
u.preventDefault();
|
|
4188
4193
|
const g = i.indexToRowId.get(E + 1);
|
|
4189
4194
|
if (g) {
|
|
4190
|
-
const x =
|
|
4191
|
-
|
|
4195
|
+
const x = Me(g, c);
|
|
4196
|
+
l(x, u.shiftKey, u.shiftKey), O ? a(x) : I(x), o && V(g);
|
|
4192
4197
|
}
|
|
4193
4198
|
break;
|
|
4194
4199
|
}
|
|
@@ -4196,8 +4201,8 @@ function ea() {
|
|
|
4196
4201
|
if (u.preventDefault(), k > 0) {
|
|
4197
4202
|
const g = i.indexToColId.get(k - 1);
|
|
4198
4203
|
if (g) {
|
|
4199
|
-
const x =
|
|
4200
|
-
|
|
4204
|
+
const x = Me(y, g);
|
|
4205
|
+
l(x, u.shiftKey, u.shiftKey), I(x);
|
|
4201
4206
|
}
|
|
4202
4207
|
}
|
|
4203
4208
|
break;
|
|
@@ -4206,20 +4211,20 @@ function ea() {
|
|
|
4206
4211
|
u.preventDefault();
|
|
4207
4212
|
const g = i.indexToColId.get(k + 1);
|
|
4208
4213
|
if (g) {
|
|
4209
|
-
const x =
|
|
4210
|
-
|
|
4214
|
+
const x = Me(y, g);
|
|
4215
|
+
l(x, u.shiftKey, u.shiftKey), I(x);
|
|
4211
4216
|
}
|
|
4212
4217
|
break;
|
|
4213
4218
|
}
|
|
4214
4219
|
case "Enter": {
|
|
4215
|
-
if (u.preventDefault(),
|
|
4220
|
+
if (u.preventDefault(), c === "name") {
|
|
4216
4221
|
const g = t(y), x = g && nn(g.entityType);
|
|
4217
4222
|
g && (g.entityType === "folder" || g.entityType === "task") && !x && T({
|
|
4218
4223
|
entityId: y,
|
|
4219
4224
|
entityType: g.entityType
|
|
4220
4225
|
});
|
|
4221
4226
|
} else if (!F) {
|
|
4222
|
-
const g =
|
|
4227
|
+
const g = c.startsWith("attrib_") ? document.getElementById(p)?.querySelector('input[type="checkbox"]') : null;
|
|
4223
4228
|
g && !g.disabled ? g.click() : C(p);
|
|
4224
4229
|
}
|
|
4225
4230
|
break;
|
|
@@ -4232,19 +4237,19 @@ function ea() {
|
|
|
4232
4237
|
u.preventDefault();
|
|
4233
4238
|
const g = u.shiftKey ? k - 1 : k + 1, x = i.indexToColId.get(g);
|
|
4234
4239
|
if (x) {
|
|
4235
|
-
const D =
|
|
4236
|
-
|
|
4240
|
+
const D = Me(y, x);
|
|
4241
|
+
l(D, !1, !1), I(D);
|
|
4237
4242
|
} else if (!u.shiftKey && E < i.rowIdToIndex.size - 1) {
|
|
4238
|
-
const D = i.indexToRowId.get(E + 1),
|
|
4239
|
-
if (D &&
|
|
4240
|
-
const z =
|
|
4241
|
-
|
|
4243
|
+
const D = i.indexToRowId.get(E + 1), N = i.indexToColId.get(0);
|
|
4244
|
+
if (D && N) {
|
|
4245
|
+
const z = Me(D, N);
|
|
4246
|
+
l(z, !1, !1), I(z);
|
|
4242
4247
|
}
|
|
4243
4248
|
} else if (u.shiftKey && E > 0) {
|
|
4244
|
-
const D = i.indexToRowId.get(E - 1),
|
|
4245
|
-
if (D &&
|
|
4246
|
-
const z =
|
|
4247
|
-
|
|
4249
|
+
const D = i.indexToRowId.get(E - 1), N = i.indexToColId.get(i.colIdToIndex.size - 1);
|
|
4250
|
+
if (D && N) {
|
|
4251
|
+
const z = Me(D, N);
|
|
4252
|
+
l(z, !1, !1), I(z);
|
|
4248
4253
|
}
|
|
4249
4254
|
}
|
|
4250
4255
|
break;
|
|
@@ -4256,10 +4261,10 @@ function ea() {
|
|
|
4256
4261
|
case "r": {
|
|
4257
4262
|
if (u.ctrlKey || u.metaKey)
|
|
4258
4263
|
return;
|
|
4259
|
-
if (u.preventDefault(),
|
|
4264
|
+
if (u.preventDefault(), c === "name" && h) {
|
|
4260
4265
|
const g = t(y);
|
|
4261
4266
|
if (g && (g.entityType === "folder" || g.entityType === "task")) {
|
|
4262
|
-
const x =
|
|
4267
|
+
const x = Me(y, "name");
|
|
4263
4268
|
C(x);
|
|
4264
4269
|
}
|
|
4265
4270
|
}
|
|
@@ -4270,7 +4275,7 @@ function ea() {
|
|
|
4270
4275
|
[
|
|
4271
4276
|
p,
|
|
4272
4277
|
i,
|
|
4273
|
-
|
|
4278
|
+
l,
|
|
4274
4279
|
a,
|
|
4275
4280
|
I,
|
|
4276
4281
|
b,
|
|
@@ -4288,7 +4293,7 @@ function ea() {
|
|
|
4288
4293
|
r,
|
|
4289
4294
|
p,
|
|
4290
4295
|
i,
|
|
4291
|
-
|
|
4296
|
+
l,
|
|
4292
4297
|
I,
|
|
4293
4298
|
b,
|
|
4294
4299
|
C,
|
|
@@ -4299,18 +4304,18 @@ function ea() {
|
|
|
4299
4304
|
handleKeyDown: r,
|
|
4300
4305
|
focusedCellId: p,
|
|
4301
4306
|
gridMap: i,
|
|
4302
|
-
selectCell:
|
|
4307
|
+
selectCell: l,
|
|
4303
4308
|
focusCell: a,
|
|
4304
4309
|
clearSelection: b,
|
|
4305
4310
|
setEditingCellId: C,
|
|
4306
4311
|
editingCellId: w
|
|
4307
4312
|
};
|
|
4308
4313
|
}
|
|
4309
|
-
const
|
|
4310
|
-
const { rowHeight: e =
|
|
4314
|
+
const sa = 24, oa = () => {
|
|
4315
|
+
const { rowHeight: e = sa } = dt();
|
|
4311
4316
|
return { getRowHeight: (n) => e, thumbnailRowHeight: e, defaultRowHeight: e };
|
|
4312
|
-
}, as = ({ error: e }) => /* @__PURE__ */ U("div", { className: "readonly", "data-tooltip": e.message, style: { justifyContent: "center" }, children: /* @__PURE__ */ U(Ft, { icon: "error", style: { color: "var(--md-sys-color-error)" } }) }),
|
|
4313
|
-
const { projectName: s } = Ue(), { primary: d, group: h, metaType: p, isLoading: i } = o.original,
|
|
4317
|
+
}, as = ({ error: e }) => /* @__PURE__ */ U("div", { className: "readonly", "data-tooltip": e.message, style: { justifyContent: "center" }, children: /* @__PURE__ */ U(Ft, { icon: "error", style: { color: "var(--md-sys-color-error)" } }) }), ra = ({ contribution: e, page: t, columnId: n, row: o }) => {
|
|
4318
|
+
const { projectName: s } = Ue(), { primary: d, group: h, metaType: p, isLoading: i } = o.original, l = !h && !p && !i && (!e.entityTypes?.length || e.entityTypes.includes(d.entityType)), a = hi(n, d.id), b = a?.value, m = !!e.fetchValues && (!a || a.status === "loading" && !("value" in a)), C = H(
|
|
4314
4319
|
() => ({
|
|
4315
4320
|
projectName: s,
|
|
4316
4321
|
page: t,
|
|
@@ -4328,11 +4333,11 @@ const ta = 24, na = () => {
|
|
|
4328
4333
|
return /* @__PURE__ */ U(
|
|
4329
4334
|
Sn,
|
|
4330
4335
|
{
|
|
4331
|
-
id:
|
|
4336
|
+
id: Me(o.id, n),
|
|
4332
4337
|
className: i ? "readonly loading" : "readonly",
|
|
4333
4338
|
tabIndex: 0,
|
|
4334
|
-
children:
|
|
4335
|
-
|
|
4339
|
+
children: l && a?.status === "error" && a.error ? /* @__PURE__ */ U(as, { error: a.error }) : l && m ? /* @__PURE__ */ U("div", { className: "readonly loading" }) : l && /* @__PURE__ */ U(
|
|
4340
|
+
vr,
|
|
4336
4341
|
{
|
|
4337
4342
|
contribution: e,
|
|
4338
4343
|
piece: "cell",
|
|
@@ -4343,12 +4348,12 @@ const ta = 24, na = () => {
|
|
|
4343
4348
|
)
|
|
4344
4349
|
}
|
|
4345
4350
|
);
|
|
4346
|
-
},
|
|
4351
|
+
}, ia = 150, yn = 100, aa = ({
|
|
4347
4352
|
meta: e,
|
|
4348
4353
|
columnId: t,
|
|
4349
4354
|
entities: n
|
|
4350
4355
|
}) => {
|
|
4351
|
-
const { projectName: o } = Ue(), { contribution: s, page: d } = e, { value: h } =
|
|
4356
|
+
const { projectName: o } = Ue(), { contribution: s, page: d } = e, { value: h } = Xo(s.fetchValues), p = `${o}:${d}`, i = He({
|
|
4352
4357
|
pending: /* @__PURE__ */ new Map(),
|
|
4353
4358
|
onScreen: [],
|
|
4354
4359
|
timer: void 0,
|
|
@@ -4356,11 +4361,11 @@ const ta = 24, na = () => {
|
|
|
4356
4361
|
});
|
|
4357
4362
|
$e(() => {
|
|
4358
4363
|
const T = i.current;
|
|
4359
|
-
return T.controller = new AbortController(),
|
|
4364
|
+
return T.controller = new AbortController(), gi(t), () => {
|
|
4360
4365
|
T.controller.abort(), clearTimeout(T.timer), T.pending.clear();
|
|
4361
4366
|
};
|
|
4362
4367
|
}, [t, p]);
|
|
4363
|
-
const
|
|
4368
|
+
const l = q(() => {
|
|
4364
4369
|
const T = i.current;
|
|
4365
4370
|
if (clearTimeout(T.timer), T.timer = void 0, !h) return;
|
|
4366
4371
|
const I = new Set(T.onScreen.map((f) => f.id)), r = [...T.pending.values()].filter((f) => I.has(f.id));
|
|
@@ -4368,41 +4373,41 @@ const ta = 24, na = () => {
|
|
|
4368
4373
|
const { signal: u } = T.controller;
|
|
4369
4374
|
for (let f = 0; f < r.length; f += yn) {
|
|
4370
4375
|
const v = r.slice(f, f + yn), S = {};
|
|
4371
|
-
v.forEach(({ id: y, version:
|
|
4376
|
+
v.forEach(({ id: y, version: c }) => {
|
|
4372
4377
|
const E = _t(t, y);
|
|
4373
4378
|
S[y] = {
|
|
4374
4379
|
status: "loading",
|
|
4375
|
-
version:
|
|
4380
|
+
version: c,
|
|
4376
4381
|
...E && "value" in E ? { value: E.value } : {}
|
|
4377
4382
|
};
|
|
4378
4383
|
}), ts(t, S);
|
|
4379
4384
|
const O = (y) => {
|
|
4380
4385
|
if (u.aborted) return;
|
|
4381
|
-
const
|
|
4386
|
+
const c = {};
|
|
4382
4387
|
v.forEach(({ id: E, version: k }) => {
|
|
4383
|
-
_t(t, E)?.version === k && (
|
|
4384
|
-
}), ts(t,
|
|
4388
|
+
_t(t, E)?.version === k && (c[E] = { ...y(E), version: k });
|
|
4389
|
+
}), ts(t, c);
|
|
4385
4390
|
}, R = v.map(
|
|
4386
|
-
({ id: y, entityType:
|
|
4391
|
+
({ id: y, entityType: c, projectName: E, name: k, label: F }) => ({
|
|
4387
4392
|
id: y,
|
|
4388
|
-
entityType:
|
|
4393
|
+
entityType: c,
|
|
4389
4394
|
projectName: E,
|
|
4390
4395
|
name: k,
|
|
4391
4396
|
label: F
|
|
4392
4397
|
})
|
|
4393
4398
|
);
|
|
4394
|
-
Promise.resolve().then(() => h({ projectName: o, page: d, entities: R, signal: u })).then((y) => O((
|
|
4399
|
+
Promise.resolve().then(() => h({ projectName: o, page: d, entities: R, signal: u })).then((y) => O((c) => ({ status: "loaded", value: y?.[c] }))).catch((y) => {
|
|
4395
4400
|
if (u.aborted) return;
|
|
4396
|
-
const
|
|
4397
|
-
|
|
4401
|
+
const c = y instanceof Error ? y : new Error(String(y));
|
|
4402
|
+
Yo(s, c), O(() => ({ status: "error", error: c }));
|
|
4398
4403
|
});
|
|
4399
4404
|
}
|
|
4400
4405
|
}, [h, t, s, o, d]), a = q(
|
|
4401
4406
|
(T) => {
|
|
4402
4407
|
const I = i.current;
|
|
4403
|
-
T.forEach((r) => I.pending.set(r.id, r)), I.pending.size && (I.pending.size >= yn ?
|
|
4408
|
+
T.forEach((r) => I.pending.set(r.id, r)), I.pending.size && (I.pending.size >= yn ? l() : (clearTimeout(I.timer), I.timer = setTimeout(l, ia)));
|
|
4404
4409
|
},
|
|
4405
|
-
[
|
|
4410
|
+
[l]
|
|
4406
4411
|
);
|
|
4407
4412
|
$e(() => {
|
|
4408
4413
|
if (!h) return;
|
|
@@ -4415,15 +4420,15 @@ const ta = 24, na = () => {
|
|
|
4415
4420
|
);
|
|
4416
4421
|
}, [n, h, t, a]);
|
|
4417
4422
|
const b = q(() => {
|
|
4418
|
-
i.current.controller.abort(), i.current.controller = new AbortController(),
|
|
4423
|
+
i.current.controller.abort(), i.current.controller = new AbortController(), yi(t), a(i.current.onScreen);
|
|
4419
4424
|
}, [t, a]);
|
|
4420
4425
|
$e(
|
|
4421
|
-
() =>
|
|
4426
|
+
() => Jo((T) => {
|
|
4422
4427
|
T === s.id && b();
|
|
4423
4428
|
}),
|
|
4424
4429
|
[s.id, b]
|
|
4425
4430
|
);
|
|
4426
|
-
const m = s.providesTags, { data: C } =
|
|
4431
|
+
const m = s.providesTags, { data: C } = jo(
|
|
4427
4432
|
{ columnId: t, tags: m || [] },
|
|
4428
4433
|
{ skip: !h || !m?.length }
|
|
4429
4434
|
), w = He(C);
|
|
@@ -4431,7 +4436,7 @@ const ta = 24, na = () => {
|
|
|
4431
4436
|
const T = w.current;
|
|
4432
4437
|
w.current = C, T !== void 0 && C !== void 0 && C !== T && b();
|
|
4433
4438
|
}, [C, b]), null;
|
|
4434
|
-
},
|
|
4439
|
+
}, la = ({
|
|
4435
4440
|
columns: e,
|
|
4436
4441
|
entities: t,
|
|
4437
4442
|
children: n
|
|
@@ -4453,16 +4458,16 @@ const ta = 24, na = () => {
|
|
|
4453
4458
|
[d, o]
|
|
4454
4459
|
);
|
|
4455
4460
|
return /* @__PURE__ */ Be(hn, { children: [
|
|
4456
|
-
s.map(({ columnId: p, meta: i }) => /* @__PURE__ */ U(
|
|
4461
|
+
s.map(({ columnId: p, meta: i }) => /* @__PURE__ */ U(aa, { meta: i, columnId: p, entities: h }, p)),
|
|
4457
4462
|
n
|
|
4458
4463
|
] });
|
|
4459
|
-
},
|
|
4460
|
-
const { projectName: n } = Ue(), { getEntityById: o } = Ke(), { focusedCellId: s, selectedCells: d } = et(), { editingCellId: h } = ut(), { hasShortcuts: p, handleShortcut: i, dialog:
|
|
4464
|
+
}, ca = (e) => e.tagName === "INPUT" || e.tagName === "TEXTAREA" || e.isContentEditable || e.getAttribute("role") === "textbox", da = ({ page: e, containerRef: t }) => {
|
|
4465
|
+
const { projectName: n } = Ue(), { getEntityById: o } = Ke(), { focusedCellId: s, selectedCells: d } = et(), { editingCellId: h } = ut(), { hasShortcuts: p, handleShortcut: i, dialog: l } = Wr(e);
|
|
4461
4466
|
return $e(() => {
|
|
4462
|
-
if (!p ||
|
|
4467
|
+
if (!p || l) return;
|
|
4463
4468
|
const a = (b) => {
|
|
4464
4469
|
const m = b.target;
|
|
4465
|
-
!m || !t.current?.contains(m) || !m.closest("tbody td") ||
|
|
4470
|
+
!m || !t.current?.contains(m) || !m.closest("tbody td") || ca(m) || h || i(b, () => {
|
|
4466
4471
|
const C = s ? de(s) : null;
|
|
4467
4472
|
if (!C || C.rowId.startsWith(Tt)) return;
|
|
4468
4473
|
const w = (S) => {
|
|
@@ -4499,21 +4504,21 @@ const ta = 24, na = () => {
|
|
|
4499
4504
|
}, [
|
|
4500
4505
|
t,
|
|
4501
4506
|
p,
|
|
4502
|
-
|
|
4507
|
+
l,
|
|
4503
4508
|
i,
|
|
4504
4509
|
h,
|
|
4505
4510
|
s,
|
|
4506
4511
|
d,
|
|
4507
4512
|
o,
|
|
4508
4513
|
n
|
|
4509
|
-
]),
|
|
4510
|
-
},
|
|
4514
|
+
]), l ? /* @__PURE__ */ U(jr, { contribution: l.contribution, context: l.context }) : null;
|
|
4515
|
+
}, ua = () => null, fa = (e, t) => t.some((n) => {
|
|
4511
4516
|
if (n.includes("*")) {
|
|
4512
4517
|
const s = "^" + n.replace(/[.*+?^${}()|[\]\\]/g, "\\$&").replace(/\\\*/g, ".*") + "$";
|
|
4513
4518
|
return new RegExp(s).test(e);
|
|
4514
4519
|
}
|
|
4515
4520
|
return e === n;
|
|
4516
|
-
}),
|
|
4521
|
+
}), tc = ({
|
|
4517
4522
|
scope: e,
|
|
4518
4523
|
sliceId: t,
|
|
4519
4524
|
onScroll: n,
|
|
@@ -4524,7 +4529,7 @@ const ta = 24, na = () => {
|
|
|
4524
4529
|
excludedColumns: h,
|
|
4525
4530
|
excludedSorting: p,
|
|
4526
4531
|
extraColumns: i,
|
|
4527
|
-
includeLinks:
|
|
4532
|
+
includeLinks: l,
|
|
4528
4533
|
includeParents: a,
|
|
4529
4534
|
parentColumns: b,
|
|
4530
4535
|
isLoading: m,
|
|
@@ -4541,7 +4546,7 @@ const ta = 24, na = () => {
|
|
|
4541
4546
|
groupFieldStats: O,
|
|
4542
4547
|
fieldStatsLoading: R,
|
|
4543
4548
|
fieldStatsError: y,
|
|
4544
|
-
mainCountLabels:
|
|
4549
|
+
mainCountLabels: c,
|
|
4545
4550
|
mainBreakdownFields: E,
|
|
4546
4551
|
onScrollBottomGroupBy: k,
|
|
4547
4552
|
// Destructure new prop for group-by load more
|
|
@@ -4551,7 +4556,7 @@ const ta = 24, na = () => {
|
|
|
4551
4556
|
onColumnVisibleChangeSubscribed: g,
|
|
4552
4557
|
onVisibleRowsChange: x,
|
|
4553
4558
|
scrollToRowId: D,
|
|
4554
|
-
onScrolledToRow:
|
|
4559
|
+
onScrolledToRow: N,
|
|
4555
4560
|
addonPage: z,
|
|
4556
4561
|
pt: B,
|
|
4557
4562
|
...X
|
|
@@ -4570,7 +4575,7 @@ const ta = 24, na = () => {
|
|
|
4570
4575
|
columnVisibilityOnChange: $,
|
|
4571
4576
|
columnOrderOnChange: A,
|
|
4572
4577
|
groupBy: K,
|
|
4573
|
-
columnSummaries:
|
|
4578
|
+
columnSummaries: M,
|
|
4574
4579
|
updateColumnSummary: Y,
|
|
4575
4580
|
columnSummaryScopes: ee,
|
|
4576
4581
|
updateColumnSummaryScope: se,
|
|
@@ -4595,16 +4600,16 @@ const ta = 24, na = () => {
|
|
|
4595
4600
|
scopes: qe,
|
|
4596
4601
|
// or entityTypes
|
|
4597
4602
|
getEntityById: We,
|
|
4598
|
-
onResetView:
|
|
4603
|
+
onResetView: Nt,
|
|
4599
4604
|
overrideGroupBy: vt,
|
|
4600
|
-
loadingLinksEntityIds:
|
|
4605
|
+
loadingLinksEntityIds: Mt,
|
|
4601
4606
|
queryFilters: $t
|
|
4602
|
-
} = Ke(), Vt = !!K || !!vt, ln =
|
|
4607
|
+
} = Ke(), Vt = !!K || !!vt, ln = ji(_, $t), ft = Hi(Ki(qe)), tt = vt?.id ?? K?.id, it = Array.isArray(tt) ? tt[0] : tt, pt = xe || ["hierarchy", "folder", "product"].includes(it ?? "") || qe.includes("product"), { writableFields: zt } = Tn(), Bt = H(() => {
|
|
4603
4608
|
const Q = it?.startsWith("attrib.") ? it.slice(7) : void 0;
|
|
4604
4609
|
return Se.filter(
|
|
4605
4610
|
(ie) => ie.name === Q || en(P, `attrib_${ie.name}`, W)
|
|
4606
4611
|
).map((ie) => ie.name);
|
|
4607
|
-
}, [Se, P, W, it]), nt =
|
|
4612
|
+
}, [Se, P, W, it]), nt = Gr(Se, {
|
|
4608
4613
|
projectName: Ie,
|
|
4609
4614
|
request: Bt
|
|
4610
4615
|
}), at = m || J, {
|
|
@@ -4614,7 +4619,7 @@ const ta = 24, na = () => {
|
|
|
4614
4619
|
tags: Wt = [],
|
|
4615
4620
|
linkTypes: jt = []
|
|
4616
4621
|
} = Le || {}, Je = H(
|
|
4617
|
-
() =>
|
|
4622
|
+
() => ei({
|
|
4618
4623
|
users: De,
|
|
4619
4624
|
statuses: Ut,
|
|
4620
4625
|
folderTypes: lt,
|
|
@@ -4625,16 +4630,16 @@ const ta = 24, na = () => {
|
|
|
4625
4630
|
}),
|
|
4626
4631
|
[De, Ut, lt, Gt, qe, Wt]
|
|
4627
4632
|
), Z = He(null), ge = He(0), { registerGrid: oe } = et(), { loadingAttrib: fe, loadingRows: ce } = H(() => {
|
|
4628
|
-
const Q = Z.current?.querySelectorAll("tbody tr").length || 0, ie =
|
|
4633
|
+
const Q = Z.current?.querySelectorAll("tbody tr").length || 0, ie = Jr(), ke = Ot(
|
|
4629
4634
|
xe && Ce.length > 0 ? Math.min(Q, 50) : K ? Math.max(ge.current, 50) : 50
|
|
4630
4635
|
);
|
|
4631
4636
|
return { loadingAttrib: ie, loadingRows: ke };
|
|
4632
|
-
}, []), ye = !ue || at, { readOnlyColumns:
|
|
4633
|
-
() =>
|
|
4637
|
+
}, []), ye = !ue || at, { readOnlyColumns: Ne, readOnlyAttribs: mt } = H(
|
|
4638
|
+
() => ni(Se, zt, d),
|
|
4634
4639
|
[Se, zt, d]
|
|
4635
|
-
), { selectedCells: Ze } = et(), { updateEntities: Ht } = ut(),
|
|
4640
|
+
), { selectedCells: Ze } = et(), { updateEntities: Ht } = ut(), _s = q(
|
|
4636
4641
|
async (Q, ie) => {
|
|
4637
|
-
const { selection: ke = [], listChange: we } = ie || {}, { field: Pe, value: Qe, isAttrib: At } = Q, Vn = At ? `attrib_${Pe}` : ["folderType", "taskType", "productType"].includes(Pe) ? "subType" : Pe, zn = (ct) => ct === Vn,
|
|
4642
|
+
const { selection: ke = [], listChange: we } = ie || {}, { field: Pe, value: Qe, isAttrib: At } = Q, Vn = At ? `attrib_${Pe}` : ["folderType", "taskType", "productType"].includes(Pe) ? "subType" : Pe, zn = (ct) => ct === Vn, Xs = [...Ze].some((ct) => {
|
|
4638
4643
|
const { colId: st, rowId: Xe } = de(ct) || {};
|
|
4639
4644
|
return Xe === Q.rowId && zn(st);
|
|
4640
4645
|
}), Pt = [];
|
|
@@ -4642,7 +4647,7 @@ const ta = 24, na = () => {
|
|
|
4642
4647
|
for (const ct of we.cellIds) {
|
|
4643
4648
|
const { rowId: st } = de(ct) || {}, Xe = We(st || "");
|
|
4644
4649
|
if (!st || !Xe) continue;
|
|
4645
|
-
const bt =
|
|
4650
|
+
const bt = Ro(Xe, Vn), Bn = qo(bt, we);
|
|
4646
4651
|
wt(bt, Bn) || Pt.push({
|
|
4647
4652
|
field: Pe,
|
|
4648
4653
|
rowId: st,
|
|
@@ -4652,7 +4657,7 @@ const ta = 24, na = () => {
|
|
|
4652
4657
|
type: Xe.entityType
|
|
4653
4658
|
});
|
|
4654
4659
|
}
|
|
4655
|
-
else if (!ke?.length || !
|
|
4660
|
+
else if (!ke?.length || !Xs)
|
|
4656
4661
|
Pt.push({ ...Q, id: Q.id || Q.rowId });
|
|
4657
4662
|
else
|
|
4658
4663
|
for (const ct of Ze) {
|
|
@@ -4682,12 +4687,12 @@ const ta = 24, na = () => {
|
|
|
4682
4687
|
), kn = H(
|
|
4683
4688
|
() => ue ? nt : fe,
|
|
4684
4689
|
[nt, fe, ue]
|
|
4685
|
-
),
|
|
4686
|
-
const Q =
|
|
4690
|
+
), Fs = () => Oo(qe), Ns = a?.join(","), Rn = H(() => a, [Ns]), Ms = JSON.stringify([Je.status, Je.folderType, Je.taskType]), An = H(() => Je, [Ms]), gt = H(() => {
|
|
4691
|
+
const Q = Ao({
|
|
4687
4692
|
scopes: qe,
|
|
4688
4693
|
attribs: kn,
|
|
4689
4694
|
links: jt,
|
|
4690
|
-
includeLinks:
|
|
4695
|
+
includeLinks: l,
|
|
4691
4696
|
includeParents: Rn,
|
|
4692
4697
|
showHierarchy: xe,
|
|
4693
4698
|
isFlatFolderView: _e,
|
|
@@ -4696,7 +4701,7 @@ const ta = 24, na = () => {
|
|
|
4696
4701
|
excluded: h,
|
|
4697
4702
|
excludedSorting: p,
|
|
4698
4703
|
groupBy: K,
|
|
4699
|
-
nameLabel:
|
|
4704
|
+
nameLabel: Fs(),
|
|
4700
4705
|
parentColumns: b
|
|
4701
4706
|
});
|
|
4702
4707
|
return I && w ? [
|
|
@@ -4725,7 +4730,7 @@ const ta = 24, na = () => {
|
|
|
4725
4730
|
C,
|
|
4726
4731
|
An,
|
|
4727
4732
|
jt,
|
|
4728
|
-
|
|
4733
|
+
l,
|
|
4729
4734
|
Rn,
|
|
4730
4735
|
b,
|
|
4731
4736
|
i,
|
|
@@ -4753,19 +4758,19 @@ const ta = 24, na = () => {
|
|
|
4753
4758
|
const Q = gt.map((ie) => ie.id).filter((ie) => ie && !yt.has(ie));
|
|
4754
4759
|
be(Q);
|
|
4755
4760
|
}, [gt, be, yt]);
|
|
4756
|
-
const
|
|
4761
|
+
const $s = H(() => {
|
|
4757
4762
|
const Q = { ...P };
|
|
4758
4763
|
yt.forEach((ke) => Q[ke] = !0);
|
|
4759
4764
|
const ie = {};
|
|
4760
4765
|
return gt.forEach((ke) => {
|
|
4761
4766
|
ke.id && (ie[ke.id] = ke.visible);
|
|
4762
|
-
}),
|
|
4767
|
+
}), lr(
|
|
4763
4768
|
Q,
|
|
4764
4769
|
gt.map((ke) => ke.id).filter(Boolean),
|
|
4765
4770
|
W,
|
|
4766
4771
|
ie
|
|
4767
4772
|
);
|
|
4768
|
-
}, [P, W, gt, yt]), Ve =
|
|
4773
|
+
}, [P, W, gt, yt]), Ve = eo({
|
|
4769
4774
|
data: ye ? ce : Ce,
|
|
4770
4775
|
columns: gt,
|
|
4771
4776
|
defaultColumn: {
|
|
@@ -4779,15 +4784,15 @@ const ta = 24, na = () => {
|
|
|
4779
4784
|
//disable sub row selection
|
|
4780
4785
|
getSubRows: (Q) => Q.subRows,
|
|
4781
4786
|
getRowCanExpand: () => !!C || xe || _e || Vt,
|
|
4782
|
-
getCoreRowModel:
|
|
4783
|
-
getFilteredRowModel:
|
|
4784
|
-
getExpandedRowModel:
|
|
4787
|
+
getCoreRowModel: ro(),
|
|
4788
|
+
getFilteredRowModel: oo(),
|
|
4789
|
+
getExpandedRowModel: so(),
|
|
4785
4790
|
filterFromLeafRows: !0,
|
|
4786
4791
|
// EXPANDABLE
|
|
4787
4792
|
onExpandedChange: Oe,
|
|
4788
4793
|
// SORTING
|
|
4789
4794
|
enableSorting: w,
|
|
4790
|
-
getSortedRowModel:
|
|
4795
|
+
getSortedRowModel: no(),
|
|
4791
4796
|
sortDescFirst: !1,
|
|
4792
4797
|
maxMultiSortColCount: En,
|
|
4793
4798
|
manualSorting: !T,
|
|
@@ -4798,7 +4803,7 @@ const ta = 24, na = () => {
|
|
|
4798
4803
|
onColumnVisibilityChange: $,
|
|
4799
4804
|
onColumnOrderChange: A,
|
|
4800
4805
|
// @ts-ignore
|
|
4801
|
-
filterFns:
|
|
4806
|
+
filterFns: to,
|
|
4802
4807
|
state: {
|
|
4803
4808
|
expanded: me,
|
|
4804
4809
|
sorting: he,
|
|
@@ -4814,19 +4819,19 @@ const ta = 24, na = () => {
|
|
|
4814
4819
|
};
|
|
4815
4820
|
})(),
|
|
4816
4821
|
columnSizing: te,
|
|
4817
|
-
columnVisibility:
|
|
4822
|
+
columnVisibility: $s,
|
|
4818
4823
|
columnOrder: Pn
|
|
4819
4824
|
},
|
|
4820
4825
|
meta: {
|
|
4821
4826
|
projectName: Ie,
|
|
4822
4827
|
options: Je,
|
|
4823
|
-
readOnly:
|
|
4824
|
-
updateEntities:
|
|
4828
|
+
readOnly: Ne,
|
|
4829
|
+
updateEntities: _s,
|
|
4825
4830
|
toggleExpandAll: Ee,
|
|
4826
4831
|
loadMoreRows: rt,
|
|
4827
4832
|
selection: Array.from(Ze),
|
|
4828
4833
|
columnsConfig: f,
|
|
4829
|
-
loadingLinksEntityIds:
|
|
4834
|
+
loadingLinksEntityIds: Mt
|
|
4830
4835
|
}
|
|
4831
4836
|
}), { rows: ht } = Ve.getRowModel();
|
|
4832
4837
|
$e(() => {
|
|
@@ -4840,7 +4845,7 @@ const ta = 24, na = () => {
|
|
|
4840
4845
|
});
|
|
4841
4846
|
oe(Q, ke);
|
|
4842
4847
|
}, [ht, Ve.getVisibleLeafColumns(), L, pe, oe]);
|
|
4843
|
-
const Kt = Ve.getVisibleLeafColumns(), { columnVirtualizer: xt, virtualPaddingLeft: kt, virtualPaddingRight: Rt } =
|
|
4848
|
+
const Kt = Ve.getVisibleLeafColumns(), { columnVirtualizer: xt, virtualPaddingLeft: kt, virtualPaddingRight: Rt } = ta({
|
|
4844
4849
|
visibleColumns: Kt,
|
|
4845
4850
|
tableContainerRef: Z,
|
|
4846
4851
|
columnPinning: L,
|
|
@@ -4851,18 +4856,18 @@ const ta = 24, na = () => {
|
|
|
4851
4856
|
if (!V || !g?.length) return;
|
|
4852
4857
|
const Q = new Set(Ln.map((Pe) => Kt[Pe.index]?.id)), ie = {};
|
|
4853
4858
|
let ke = !1;
|
|
4854
|
-
Ve.getAllLeafColumns().filter((Pe) =>
|
|
4859
|
+
Ve.getAllLeafColumns().filter((Pe) => fa(Pe.id, g)).forEach((Pe) => {
|
|
4855
4860
|
const Qe = Q.has(Pe.id);
|
|
4856
4861
|
Dn.current[Pe.id] !== Qe && (ie[Pe.id] = Qe, ke = !0, Dn.current[Pe.id] = Qe);
|
|
4857
4862
|
}), ke && V(ie);
|
|
4858
4863
|
}, [Ln, V, g, Kt, Ve]);
|
|
4859
|
-
const On =
|
|
4864
|
+
const On = ea(Ve, te), { powerLicense: _n } = hr(), [Vs, { isLoaded: Fn, isLoading: Nn }] = zr({
|
|
4860
4865
|
addon: "powerpack",
|
|
4861
4866
|
remote: "views",
|
|
4862
4867
|
module: "SummaryCellContent",
|
|
4863
|
-
fallback:
|
|
4868
|
+
fallback: ua,
|
|
4864
4869
|
skip: !v || !_n
|
|
4865
|
-
}),
|
|
4870
|
+
}), zs = v && _n && (Fn || Nn) && !!ht.length, Bs = Nn || !Fn, Us = H(() => {
|
|
4866
4871
|
const Q = /* @__PURE__ */ new Set(), ie = /* @__PURE__ */ new Set();
|
|
4867
4872
|
for (const ke of Ze) {
|
|
4868
4873
|
const { rowId: we, colId: Pe } = de(ke) || {};
|
|
@@ -4871,9 +4876,9 @@ const ta = 24, na = () => {
|
|
|
4871
4876
|
Qe && (Pe === pe ? ie.add(Qe) : Q.add(Qe));
|
|
4872
4877
|
}
|
|
4873
4878
|
return Q.size || ie.size;
|
|
4874
|
-
}, [Ze, We]), { getRowHeight:
|
|
4879
|
+
}, [Ze, We]), { getRowHeight: Gs, defaultRowHeight: Mn } = oa(), Ws = H(() => nt.reduce((Q, ie) => (ie.data?.enum?.length && (Q[ie.name] = ie.data?.enum), Q), {}), [nt]), js = H(() => Ce.map((Q) => Q.id), [Ce]), Hs = H(() => G.filter(
|
|
4875
4880
|
(Q) => Q !== je && Q !== pe
|
|
4876
|
-
), [G]),
|
|
4881
|
+
), [G]), Ks = H(() => !u || !I ? null : Ce.find((Q) => Q.id === u), [u, Ce, I]), qs = q(
|
|
4877
4882
|
(Q) => {
|
|
4878
4883
|
if (n?.(Q), o) {
|
|
4879
4884
|
const ie = Q.currentTarget;
|
|
@@ -4889,21 +4894,21 @@ const ta = 24, na = () => {
|
|
|
4889
4894
|
},
|
|
4890
4895
|
[n, o, k, xe, K, at]
|
|
4891
4896
|
), $n = /* @__PURE__ */ Be(
|
|
4892
|
-
|
|
4897
|
+
ki,
|
|
4893
4898
|
{
|
|
4894
4899
|
entitiesMap: ve,
|
|
4895
|
-
columnEnums: { ...Je, ...
|
|
4900
|
+
columnEnums: { ...Je, ...Ws },
|
|
4896
4901
|
columnReadOnly: mt,
|
|
4897
4902
|
visibleColumns: Kt,
|
|
4898
4903
|
children: [
|
|
4899
|
-
z && /* @__PURE__ */ U(
|
|
4900
|
-
/* @__PURE__ */ Be(
|
|
4904
|
+
z && /* @__PURE__ */ U(da, { page: z, containerRef: Z }),
|
|
4905
|
+
/* @__PURE__ */ Be(Po, { ...X, children: [
|
|
4901
4906
|
/* @__PURE__ */ U(
|
|
4902
|
-
|
|
4907
|
+
Do,
|
|
4903
4908
|
{
|
|
4904
4909
|
ref: Z,
|
|
4905
4910
|
style: { height: "100%", padding: 0 },
|
|
4906
|
-
onScroll:
|
|
4911
|
+
onScroll: qs,
|
|
4907
4912
|
...B?.container,
|
|
4908
4913
|
"data-column-dnd-container": !0,
|
|
4909
4914
|
className: Ye(
|
|
@@ -4930,21 +4935,21 @@ const ta = 24, na = () => {
|
|
|
4930
4935
|
},
|
|
4931
4936
|
children: [
|
|
4932
4937
|
/* @__PURE__ */ U(
|
|
4933
|
-
|
|
4938
|
+
pa,
|
|
4934
4939
|
{
|
|
4935
4940
|
columnVirtualizer: xt,
|
|
4936
4941
|
table: Ve,
|
|
4937
4942
|
virtualPaddingLeft: kt,
|
|
4938
4943
|
virtualPaddingRight: Rt,
|
|
4939
4944
|
isLoading: at,
|
|
4940
|
-
readOnlyColumns:
|
|
4945
|
+
readOnlyColumns: Ne,
|
|
4941
4946
|
sortableRows: I,
|
|
4942
|
-
columnOrderIds:
|
|
4947
|
+
columnOrderIds: Hs,
|
|
4943
4948
|
...B?.head
|
|
4944
4949
|
}
|
|
4945
4950
|
),
|
|
4946
4951
|
/* @__PURE__ */ U(
|
|
4947
|
-
|
|
4952
|
+
ya,
|
|
4948
4953
|
{
|
|
4949
4954
|
columnVirtualizer: xt,
|
|
4950
4955
|
table: Ve,
|
|
@@ -4954,49 +4959,49 @@ const ta = 24, na = () => {
|
|
|
4954
4959
|
showHierarchy: xe,
|
|
4955
4960
|
attribs: nt,
|
|
4956
4961
|
onOpenNew: s,
|
|
4957
|
-
rowOrderIds:
|
|
4962
|
+
rowOrderIds: js,
|
|
4958
4963
|
sortableRows: I,
|
|
4959
4964
|
error: _,
|
|
4960
4965
|
isFilterError: ln,
|
|
4961
4966
|
filterErrorMessage: ft,
|
|
4962
4967
|
isLoading: at,
|
|
4963
4968
|
isGrouping: Vt,
|
|
4964
|
-
getRowHeight:
|
|
4965
|
-
defaultRowHeight:
|
|
4966
|
-
onResetView:
|
|
4969
|
+
getRowHeight: Gs,
|
|
4970
|
+
defaultRowHeight: Mn,
|
|
4971
|
+
onResetView: Nt,
|
|
4967
4972
|
contextMenuItems: F,
|
|
4968
4973
|
onVisibleRowsChange: x,
|
|
4969
4974
|
scrollToRowId: D,
|
|
4970
|
-
onScrolledToRow:
|
|
4975
|
+
onScrolledToRow: N
|
|
4971
4976
|
}
|
|
4972
4977
|
),
|
|
4973
|
-
|
|
4974
|
-
|
|
4978
|
+
zs && !_ && /* @__PURE__ */ U(
|
|
4979
|
+
Ho,
|
|
4975
4980
|
{
|
|
4976
4981
|
columnVirtualizer: xt,
|
|
4977
4982
|
table: Ve,
|
|
4978
4983
|
virtualPaddingLeft: kt,
|
|
4979
4984
|
virtualPaddingRight: Rt,
|
|
4980
|
-
isLoading:
|
|
4985
|
+
isLoading: Bs,
|
|
4981
4986
|
statsLoading: !!R,
|
|
4982
4987
|
error: y,
|
|
4983
4988
|
renderCellContent: (Q) => /* @__PURE__ */ U(
|
|
4984
|
-
|
|
4989
|
+
Vs,
|
|
4985
4990
|
{
|
|
4986
4991
|
columnId: Q,
|
|
4987
4992
|
attribs: nt,
|
|
4988
4993
|
fieldStats: S,
|
|
4989
4994
|
groupFieldStats: O,
|
|
4990
|
-
calc:
|
|
4995
|
+
calc: M[Q],
|
|
4991
4996
|
onCalcChange: (ie) => Y(Q, ie),
|
|
4992
4997
|
format: ne[Q],
|
|
4993
4998
|
onFormatChange: (ie) => Te(Q, ie),
|
|
4994
4999
|
scope: ee[Q],
|
|
4995
5000
|
onScopeChange: (ie) => se(Q, ie),
|
|
4996
|
-
mainCountLabels:
|
|
5001
|
+
mainCountLabels: c,
|
|
4997
5002
|
fieldOptions: Je,
|
|
4998
5003
|
parentScopeApplicable: pt,
|
|
4999
|
-
selectedCount:
|
|
5004
|
+
selectedCount: Us,
|
|
5000
5005
|
mainBreakdownFields: E
|
|
5001
5006
|
}
|
|
5002
5007
|
)
|
|
@@ -5007,12 +5012,12 @@ const ta = 24, na = () => {
|
|
|
5007
5012
|
)
|
|
5008
5013
|
}
|
|
5009
5014
|
),
|
|
5010
|
-
j && /* @__PURE__ */ U(
|
|
5015
|
+
j && /* @__PURE__ */ U(Lo, { children: /* @__PURE__ */ U($r, { variant: "warning", message: j, action: le }) })
|
|
5011
5016
|
] })
|
|
5012
5017
|
]
|
|
5013
5018
|
}
|
|
5014
|
-
),
|
|
5015
|
-
/* @__PURE__ */ U(Ts, { dropAnimation: null, children:
|
|
5019
|
+
), Qs = I && u && sn(
|
|
5020
|
+
/* @__PURE__ */ U(Ts, { dropAnimation: null, children: Ks ? (() => {
|
|
5016
5021
|
const Q = Ve.getRowModel().rows.find((ke) => ke.id === u);
|
|
5017
5022
|
if (!Q) return null;
|
|
5018
5023
|
const ie = Ve.getTotalSize();
|
|
@@ -5036,7 +5041,7 @@ const ta = 24, na = () => {
|
|
|
5036
5041
|
width: rn(we.column.id),
|
|
5037
5042
|
display: "flex",
|
|
5038
5043
|
alignItems: "center",
|
|
5039
|
-
height:
|
|
5044
|
+
height: Mn
|
|
5040
5045
|
};
|
|
5041
5046
|
return we.column.id === je ? /* @__PURE__ */ Be(
|
|
5042
5047
|
vn,
|
|
@@ -5050,10 +5055,10 @@ const ta = 24, na = () => {
|
|
|
5050
5055
|
},
|
|
5051
5056
|
`overlay-drag-${we.id}`
|
|
5052
5057
|
) : /* @__PURE__ */ U(
|
|
5053
|
-
|
|
5058
|
+
Os,
|
|
5054
5059
|
{
|
|
5055
5060
|
cell: we,
|
|
5056
|
-
cellId: `overlay-${
|
|
5061
|
+
cellId: `overlay-${Me(Q.id, we.column.id)}`,
|
|
5057
5062
|
rowId: Q.id,
|
|
5058
5063
|
showHierarchy: xe
|
|
5059
5064
|
},
|
|
@@ -5069,7 +5074,7 @@ const ta = 24, na = () => {
|
|
|
5069
5074
|
);
|
|
5070
5075
|
return I ? /* @__PURE__ */ Be(hn, { children: [
|
|
5071
5076
|
$n,
|
|
5072
|
-
|
|
5077
|
+
Qs,
|
|
5073
5078
|
/* @__PURE__ */ U(ls, { table: Ve }),
|
|
5074
5079
|
/* @__PURE__ */ U(Qn, {})
|
|
5075
5080
|
] }) : /* @__PURE__ */ Be(hn, { children: [
|
|
@@ -5078,7 +5083,7 @@ const ta = 24, na = () => {
|
|
|
5078
5083
|
/* @__PURE__ */ U(Qn, {})
|
|
5079
5084
|
] });
|
|
5080
5085
|
}, ls = ({ table: e }) => {
|
|
5081
|
-
const { active: t } =
|
|
5086
|
+
const { active: t } = _r(), o = t?.data?.current?.type === "column" ? t?.id : null, s = H(() => o && e.getHeaderGroups()[0]?.headers.find((d) => d.id === o) || null, [o, e]);
|
|
5082
5087
|
return !o || !s ? null : sn(
|
|
5083
5088
|
/* @__PURE__ */ U(Ts, { dropAnimation: null, children: /* @__PURE__ */ U(
|
|
5084
5089
|
ys,
|
|
@@ -5099,7 +5104,7 @@ const ta = 24, na = () => {
|
|
|
5099
5104
|
) }),
|
|
5100
5105
|
document.body
|
|
5101
5106
|
);
|
|
5102
|
-
},
|
|
5107
|
+
}, pa = ({
|
|
5103
5108
|
columnVirtualizer: e,
|
|
5104
5109
|
table: t,
|
|
5105
5110
|
virtualPaddingLeft: n,
|
|
@@ -5109,11 +5114,11 @@ const ta = 24, na = () => {
|
|
|
5109
5114
|
sortableRows: h,
|
|
5110
5115
|
columnOrderIds: p,
|
|
5111
5116
|
...i
|
|
5112
|
-
}) => /* @__PURE__ */ U(
|
|
5113
|
-
|
|
5117
|
+
}) => /* @__PURE__ */ U(_o, { ...i, children: t.getHeaderGroups().map((l) => /* @__PURE__ */ U(
|
|
5118
|
+
ma,
|
|
5114
5119
|
{
|
|
5115
5120
|
columnVirtualizer: e,
|
|
5116
|
-
headerGroup:
|
|
5121
|
+
headerGroup: l,
|
|
5117
5122
|
virtualPaddingLeft: n,
|
|
5118
5123
|
virtualPaddingRight: o,
|
|
5119
5124
|
isLoading: s,
|
|
@@ -5121,8 +5126,8 @@ const ta = 24, na = () => {
|
|
|
5121
5126
|
sortableRows: h,
|
|
5122
5127
|
columnOrderIds: p
|
|
5123
5128
|
},
|
|
5124
|
-
|
|
5125
|
-
)) }),
|
|
5129
|
+
l.id
|
|
5130
|
+
)) }), ma = ({
|
|
5126
5131
|
columnVirtualizer: e,
|
|
5127
5132
|
headerGroup: t,
|
|
5128
5133
|
virtualPaddingLeft: n,
|
|
@@ -5133,15 +5138,15 @@ const ta = 24, na = () => {
|
|
|
5133
5138
|
columnOrderIds: p
|
|
5134
5139
|
}) => {
|
|
5135
5140
|
const i = e.getVirtualItems();
|
|
5136
|
-
return /* @__PURE__ */ Be(
|
|
5141
|
+
return /* @__PURE__ */ Be(Bo, { style: { display: "flex" }, children: [
|
|
5137
5142
|
n ? (
|
|
5138
5143
|
//fake empty column to the left for virtualization scroll padding
|
|
5139
5144
|
/* @__PURE__ */ U("th", { style: { display: "flex", width: n } })
|
|
5140
5145
|
) : null,
|
|
5141
|
-
/* @__PURE__ */ U(Ss, { items: p, strategy:
|
|
5142
|
-
const a = t.headers[
|
|
5146
|
+
/* @__PURE__ */ U(Ss, { items: p, strategy: Nr, children: i.map((l) => {
|
|
5147
|
+
const a = t.headers[l.index], b = a.id !== je && a.id !== pe;
|
|
5143
5148
|
return /* @__PURE__ */ U(
|
|
5144
|
-
|
|
5149
|
+
ga,
|
|
5145
5150
|
{
|
|
5146
5151
|
header: a,
|
|
5147
5152
|
isLoading: s,
|
|
@@ -5162,7 +5167,7 @@ const ta = 24, na = () => {
|
|
|
5162
5167
|
/* @__PURE__ */ U("th", { style: { display: "flex", width: o } })
|
|
5163
5168
|
) : null
|
|
5164
5169
|
] }, t.id);
|
|
5165
|
-
},
|
|
5170
|
+
}, ga = ({
|
|
5166
5171
|
header: e,
|
|
5167
5172
|
isLoading: t,
|
|
5168
5173
|
canFilter: n,
|
|
@@ -5172,24 +5177,24 @@ const ta = 24, na = () => {
|
|
|
5172
5177
|
canResize: h,
|
|
5173
5178
|
isReadOnly: p,
|
|
5174
5179
|
sortableRows: i,
|
|
5175
|
-
isDraggable:
|
|
5180
|
+
isDraggable: l = !0
|
|
5176
5181
|
}) => {
|
|
5177
5182
|
const { column: a } = e, b = ms(
|
|
5178
5183
|
e.getContext().table.options.meta?.columnsConfig,
|
|
5179
5184
|
a.id
|
|
5180
|
-
), m = b?.headerIcon, C = b?.menuItems, w = a.getIsSorted(), T = `column-header-menu-${a.id}`, { menuOpen: I } =
|
|
5181
|
-
const
|
|
5185
|
+
), m = b?.headerIcon, C = b?.menuItems, w = a.getIsSorted(), T = `column-header-menu-${a.id}`, { menuOpen: I } = ws(), r = I === T, { columnPinning: u, sorting: f, updateSorting: v } = dt(), S = (D) => {
|
|
5186
|
+
const N = f?.find((B) => B.id === a.id);
|
|
5182
5187
|
if (D.shiftKey && f?.length) {
|
|
5183
|
-
const B =
|
|
5188
|
+
const B = N ? N.desc ? f.filter((X) => X.id !== a.id) : f.map((X) => X.id === a.id ? { ...X, desc: !0 } : X) : [...f, { id: a.id, desc: !1 }];
|
|
5184
5189
|
B.length <= En && v(B);
|
|
5185
5190
|
return;
|
|
5186
5191
|
}
|
|
5187
|
-
const z =
|
|
5192
|
+
const z = N ? N.desc ? [] : [{ id: a.id, desc: !0 }] : [{ id: a.id, desc: !1 }];
|
|
5188
5193
|
v(z);
|
|
5189
|
-
}, O = (f?.length ?? 0) > 1 ? a.getSortIndex() : -1, R = u.left?.includes(a.id) || !1, { attributes: y, listeners:
|
|
5194
|
+
}, O = (f?.length ?? 0) > 1 ? a.getSortIndex() : -1, R = u.left?.includes(a.id) || !1, { attributes: y, listeners: c, setNodeRef: E, transform: k, transition: F, isDragging: V } = vs({
|
|
5190
5195
|
id: a.id,
|
|
5191
5196
|
data: { type: "column", isPinned: R },
|
|
5192
|
-
disabled: !
|
|
5197
|
+
disabled: !l
|
|
5193
5198
|
}), g = () => V ? {
|
|
5194
5199
|
transform: Es.Translate.toString(k),
|
|
5195
5200
|
transition: F,
|
|
@@ -5209,7 +5214,7 @@ const ta = 24, na = () => {
|
|
|
5209
5214
|
"last-pinned-left": a.getIsPinned() === "left" && a.getIsLastColumn("left"),
|
|
5210
5215
|
resizing: a.getIsResizing(),
|
|
5211
5216
|
dragging: V,
|
|
5212
|
-
draggable:
|
|
5217
|
+
draggable: l
|
|
5213
5218
|
}),
|
|
5214
5219
|
style: {
|
|
5215
5220
|
...an(a),
|
|
@@ -5221,14 +5226,14 @@ const ta = 24, na = () => {
|
|
|
5221
5226
|
Sn,
|
|
5222
5227
|
{
|
|
5223
5228
|
className: Ye("bold", "header"),
|
|
5224
|
-
...
|
|
5229
|
+
...l ? { ...y, ...c } : {},
|
|
5225
5230
|
children: [
|
|
5226
5231
|
Cn(a.columnDef.header, e.getContext()),
|
|
5227
5232
|
m && /* @__PURE__ */ U(Ft, { icon: m.icon, "data-tooltip": m.tooltip }),
|
|
5228
5233
|
p && /* @__PURE__ */ U(Ft, { icon: "lock", "data-tooltip": "You only have permission to read this column." }),
|
|
5229
|
-
/* @__PURE__ */ Be(
|
|
5234
|
+
/* @__PURE__ */ Be(Uo, { className: "actions", $isOpen: r, ...x, children: [
|
|
5230
5235
|
(o || d || s || !!C?.length) && /* @__PURE__ */ U(
|
|
5231
|
-
|
|
5236
|
+
Zi,
|
|
5232
5237
|
{
|
|
5233
5238
|
className: "header-menu",
|
|
5234
5239
|
header: e,
|
|
@@ -5253,7 +5258,7 @@ const ta = 24, na = () => {
|
|
|
5253
5258
|
selected: !!a.getIsSorted()
|
|
5254
5259
|
}
|
|
5255
5260
|
),
|
|
5256
|
-
s && O > -1 && /* @__PURE__ */ U(
|
|
5261
|
+
s && O > -1 && /* @__PURE__ */ U(Go, { className: "sort-index", children: O + 1 }),
|
|
5257
5262
|
a.getIsPinned() && a.id !== pe && a.id !== je && /* @__PURE__ */ U(
|
|
5258
5263
|
Hn,
|
|
5259
5264
|
{
|
|
@@ -5265,7 +5270,7 @@ const ta = 24, na = () => {
|
|
|
5265
5270
|
)
|
|
5266
5271
|
] }),
|
|
5267
5272
|
h && /* @__PURE__ */ U(
|
|
5268
|
-
|
|
5273
|
+
Wo,
|
|
5269
5274
|
{
|
|
5270
5275
|
onDoubleClick: () => a.resetSize(),
|
|
5271
5276
|
onMouseDown: (D) => {
|
|
@@ -5286,7 +5291,7 @@ const ta = 24, na = () => {
|
|
|
5286
5291
|
},
|
|
5287
5292
|
e.id
|
|
5288
5293
|
);
|
|
5289
|
-
},
|
|
5294
|
+
}, ya = ({
|
|
5290
5295
|
columnVirtualizer: e,
|
|
5291
5296
|
table: t,
|
|
5292
5297
|
tableContainerRef: n,
|
|
@@ -5296,7 +5301,7 @@ const ta = 24, na = () => {
|
|
|
5296
5301
|
attribs: h,
|
|
5297
5302
|
onOpenNew: p,
|
|
5298
5303
|
rowOrderIds: i,
|
|
5299
|
-
sortableRows:
|
|
5304
|
+
sortableRows: l,
|
|
5300
5305
|
error: a,
|
|
5301
5306
|
isFilterError: b,
|
|
5302
5307
|
filterErrorMessage: m,
|
|
@@ -5313,15 +5318,15 @@ const ta = 24, na = () => {
|
|
|
5313
5318
|
const O = H(() => t.getAllColumns().map((G) => {
|
|
5314
5319
|
const te = G.id, be = G.columnDef.header;
|
|
5315
5320
|
return typeof be == "string" || typeof be == "number" ? { label: be, id: te } : null;
|
|
5316
|
-
}).filter(Boolean), [t.getAllColumns()]), y =
|
|
5321
|
+
}).filter(Boolean), [t.getAllColumns()]), y = Di({
|
|
5317
5322
|
attribs: h,
|
|
5318
5323
|
onOpenNew: p,
|
|
5319
5324
|
headerLabels: O,
|
|
5320
5325
|
contextMenuItems: u
|
|
5321
|
-
}).handleTableBodyContextMenu, { rows:
|
|
5322
|
-
count:
|
|
5326
|
+
}).handleTableBodyContextMenu, { rows: c } = t.getRowModel(), E = cs({
|
|
5327
|
+
count: c.length,
|
|
5323
5328
|
estimateSize: (P) => {
|
|
5324
|
-
const L =
|
|
5329
|
+
const L = c[P];
|
|
5325
5330
|
return L ? T(L.original) : I;
|
|
5326
5331
|
},
|
|
5327
5332
|
getScrollElement: () => n.current,
|
|
@@ -5331,31 +5336,31 @@ const ta = 24, na = () => {
|
|
|
5331
5336
|
}), k = E.getVirtualItems(), F = He("");
|
|
5332
5337
|
$e(() => {
|
|
5333
5338
|
if (!f) return;
|
|
5334
|
-
const P = k.map((te) =>
|
|
5339
|
+
const P = k.map((te) => c[te.index] && us(c[te.index].id)).filter(Boolean), L = Array.from(new Set(P)), G = L.join(",");
|
|
5335
5340
|
G !== F.current && (F.current = G, f(L));
|
|
5336
|
-
}, [k,
|
|
5341
|
+
}, [k, c, f]);
|
|
5337
5342
|
const { projectName: V } = Ue(), g = t.getVisibleLeafColumns(), x = k.flatMap((P) => {
|
|
5338
|
-
const L =
|
|
5343
|
+
const L = c[P.index]?.original;
|
|
5339
5344
|
return L && !L.group && !L.metaType && !L.isLoading ? [L.primary] : [];
|
|
5340
5345
|
}), D = g.some(
|
|
5341
5346
|
(P) => ds.includes(P.id)
|
|
5342
5347
|
);
|
|
5343
|
-
|
|
5348
|
+
Fo({
|
|
5344
5349
|
projectName: V,
|
|
5345
5350
|
enabled: D,
|
|
5346
5351
|
entities: D ? x : []
|
|
5347
5352
|
}), $e(() => {
|
|
5348
5353
|
if (!v) return;
|
|
5349
|
-
const P =
|
|
5354
|
+
const P = c.findIndex((L) => L.id === v);
|
|
5350
5355
|
P !== -1 && (E.scrollToIndex(P, { align: "center" }), S?.(v));
|
|
5351
|
-
}, [v,
|
|
5352
|
-
const
|
|
5356
|
+
}, [v, c, E, S]);
|
|
5357
|
+
const N = q(
|
|
5353
5358
|
(P) => {
|
|
5354
5359
|
P && E.measureElement(P);
|
|
5355
5360
|
},
|
|
5356
5361
|
[E]
|
|
5357
5362
|
);
|
|
5358
|
-
|
|
5363
|
+
na();
|
|
5359
5364
|
const z = H(() => {
|
|
5360
5365
|
const P = [], L = [];
|
|
5361
5366
|
for (let G = 0; G < g.length - 1; G++) {
|
|
@@ -5373,11 +5378,11 @@ const ta = 24, na = () => {
|
|
|
5373
5378
|
},
|
|
5374
5379
|
onContextMenu: y,
|
|
5375
5380
|
children: [
|
|
5376
|
-
/* @__PURE__ */ U(
|
|
5381
|
+
/* @__PURE__ */ U(No, { "aria-hidden": !0, children: z.map((P, L) => /* @__PURE__ */ U("div", { style: { left: P } }, L)) }),
|
|
5377
5382
|
k.map((P) => {
|
|
5378
|
-
const L =
|
|
5383
|
+
const L = c[P.index];
|
|
5379
5384
|
return L ? /* @__PURE__ */ U(
|
|
5380
|
-
|
|
5385
|
+
ha,
|
|
5381
5386
|
{
|
|
5382
5387
|
row: L,
|
|
5383
5388
|
showHierarchy: o,
|
|
@@ -5385,10 +5390,10 @@ const ta = 24, na = () => {
|
|
|
5385
5390
|
virtualColumns: e.getVirtualItems(),
|
|
5386
5391
|
paddingLeft: s,
|
|
5387
5392
|
paddingRight: d,
|
|
5388
|
-
rowRef:
|
|
5393
|
+
rowRef: N,
|
|
5389
5394
|
dataIndex: P.index,
|
|
5390
5395
|
offsetTop: P.start,
|
|
5391
|
-
sortableRows:
|
|
5396
|
+
sortableRows: l,
|
|
5392
5397
|
isGrouping: w,
|
|
5393
5398
|
rowHeight: T(L.original)
|
|
5394
5399
|
},
|
|
@@ -5410,7 +5415,7 @@ const ta = 24, na = () => {
|
|
|
5410
5415
|
onClick: r
|
|
5411
5416
|
}
|
|
5412
5417
|
),
|
|
5413
|
-
/* @__PURE__ */ U(
|
|
5418
|
+
/* @__PURE__ */ U(Vr, { errorMessage: hs(a) })
|
|
5414
5419
|
] }) : /* @__PURE__ */ U(pn, { message: "No items found", error: a, children: r && /* @__PURE__ */ U(
|
|
5415
5420
|
un,
|
|
5416
5421
|
{
|
|
@@ -5422,14 +5427,14 @@ const ta = 24, na = () => {
|
|
|
5422
5427
|
) }) }),
|
|
5423
5428
|
n.current
|
|
5424
5429
|
);
|
|
5425
|
-
if (!
|
|
5430
|
+
if (!c.length && !C)
|
|
5426
5431
|
return n.current && sn(
|
|
5427
5432
|
/* @__PURE__ */ U(Wn, { children: /* @__PURE__ */ U(pn, { message: "No items found", children: r && /* @__PURE__ */ U(un, { variant: "filled", label: "Reset filters", icon: "replay", onClick: r }) }) }),
|
|
5428
5433
|
n.current
|
|
5429
5434
|
);
|
|
5430
|
-
const X = /* @__PURE__ */ U(
|
|
5431
|
-
return
|
|
5432
|
-
},
|
|
5435
|
+
const X = /* @__PURE__ */ U(la, { columns: g, entities: x, children: B });
|
|
5436
|
+
return l ? /* @__PURE__ */ U(Ss, { items: i, strategy: Fr, children: X }) : X;
|
|
5437
|
+
}, ha = ({
|
|
5433
5438
|
row: e,
|
|
5434
5439
|
showHierarchy: t,
|
|
5435
5440
|
visibleCells: n,
|
|
@@ -5439,11 +5444,11 @@ const ta = 24, na = () => {
|
|
|
5439
5444
|
rowRef: h,
|
|
5440
5445
|
dataIndex: p,
|
|
5441
5446
|
offsetTop: i,
|
|
5442
|
-
sortableRows:
|
|
5447
|
+
sortableRows: l,
|
|
5443
5448
|
isGrouping: a = !1,
|
|
5444
5449
|
rowHeight: b
|
|
5445
5450
|
}) => {
|
|
5446
|
-
const m =
|
|
5451
|
+
const m = l ? vs({ id: e.id }) : null, C = He(null), w = q(
|
|
5447
5452
|
(I) => {
|
|
5448
5453
|
C.current = I, m && m.setNodeRef(I), m && m.isDragging || h(I);
|
|
5449
5454
|
},
|
|
@@ -5484,7 +5489,7 @@ const ta = 24, na = () => {
|
|
|
5484
5489
|
o.map((I) => {
|
|
5485
5490
|
const r = n[I.index];
|
|
5486
5491
|
if (!r) return null;
|
|
5487
|
-
const u =
|
|
5492
|
+
const u = Me(e.id, r.column.id);
|
|
5488
5493
|
return r.column.id === je ? /* @__PURE__ */ U(
|
|
5489
5494
|
vn,
|
|
5490
5495
|
{
|
|
@@ -5508,7 +5513,7 @@ const ta = 24, na = () => {
|
|
|
5508
5513
|
f.preventDefault(), f.stopPropagation();
|
|
5509
5514
|
},
|
|
5510
5515
|
children: /* @__PURE__ */ U(
|
|
5511
|
-
|
|
5516
|
+
Ji,
|
|
5512
5517
|
{
|
|
5513
5518
|
attributes: m?.attributes,
|
|
5514
5519
|
listeners: m?.listeners
|
|
@@ -5517,13 +5522,13 @@ const ta = 24, na = () => {
|
|
|
5517
5522
|
},
|
|
5518
5523
|
r.id
|
|
5519
5524
|
) : /* @__PURE__ */ U(
|
|
5520
|
-
|
|
5525
|
+
Os,
|
|
5521
5526
|
{
|
|
5522
5527
|
cell: r,
|
|
5523
5528
|
cellId: u,
|
|
5524
5529
|
rowId: e.id,
|
|
5525
5530
|
showHierarchy: t,
|
|
5526
|
-
sortableRows:
|
|
5531
|
+
sortableRows: l,
|
|
5527
5532
|
rowHeight: b
|
|
5528
5533
|
},
|
|
5529
5534
|
r.id
|
|
@@ -5536,7 +5541,7 @@ const ta = 24, na = () => {
|
|
|
5536
5541
|
]
|
|
5537
5542
|
}
|
|
5538
5543
|
);
|
|
5539
|
-
},
|
|
5544
|
+
}, Os = ({
|
|
5540
5545
|
cell: e,
|
|
5541
5546
|
rowId: t,
|
|
5542
5547
|
cellId: n,
|
|
@@ -5546,7 +5551,7 @@ const ta = 24, na = () => {
|
|
|
5546
5551
|
rowHeight: h,
|
|
5547
5552
|
...p
|
|
5548
5553
|
}) => {
|
|
5549
|
-
const { getEntityById: i, onOpenPlayer:
|
|
5554
|
+
const { getEntityById: i, onOpenPlayer: l } = Ke(), {
|
|
5550
5555
|
isCellSelected: a,
|
|
5551
5556
|
isCellFocused: b,
|
|
5552
5557
|
startSelection: m,
|
|
@@ -5560,7 +5565,7 @@ const ta = 24, na = () => {
|
|
|
5560
5565
|
setSelectedCells: v,
|
|
5561
5566
|
setAnchorCell: S,
|
|
5562
5567
|
setFocusedCellId: O
|
|
5563
|
-
} = et(), { isRowSelected: R } = Mo(), { isEditing: y, setEditingCellId:
|
|
5568
|
+
} = et(), { isRowSelected: R } = Mo(), { isEditing: y, setEditingCellId: c, editingCellId: E } = ut(), k = r(n), V = e.column.getIsPinned() === "left" && e.column.getIsLastColumn("left"), g = e.column.id === pe, x = !!e.row.original.group, D = f.size > 1, N = ms(
|
|
5564
5569
|
e.getContext().table.options.meta?.columnsConfig,
|
|
5565
5570
|
e.column.id
|
|
5566
5571
|
), z = e.row.original.cellMarks?.[e.column.id], B = !!e.row.original.readOnly, X = H(() => ({ mark: z, isRowReadOnly: B }), [z, B]);
|
|
@@ -5578,7 +5583,7 @@ const ta = 24, na = () => {
|
|
|
5578
5583
|
editing: y(n),
|
|
5579
5584
|
"last-pinned-left": V,
|
|
5580
5585
|
"selected-row": R(t),
|
|
5581
|
-
expandable: !x && !!e.row.originalSubRows &&
|
|
5586
|
+
expandable: !x && !!e.row.originalSubRows && zo(e.row.original.primary.entityType),
|
|
5582
5587
|
"multiple-selected": D
|
|
5583
5588
|
},
|
|
5584
5589
|
o,
|
|
@@ -5594,34 +5599,38 @@ const ta = 24, na = () => {
|
|
|
5594
5599
|
const L = P.target;
|
|
5595
5600
|
if (L.closest(".expander") || L.closest(".options") || !P.currentTarget.contains(L)) return;
|
|
5596
5601
|
if (P.currentTarget.focus(), P.detail === 2) {
|
|
5597
|
-
if (
|
|
5602
|
+
if (Vo(P) && e.column.id !== "comments" || nn(e.row.original.primary.entityType) || x || e.row.original.readOnly) {
|
|
5598
5603
|
P.preventDefault();
|
|
5599
5604
|
return;
|
|
5600
5605
|
}
|
|
5601
5606
|
if (["name", "comments"].includes(e.column.id) && !L.closest(".expander")) {
|
|
5602
|
-
e.column.id === "comments" &&
|
|
5603
|
-
const he =
|
|
5607
|
+
e.column.id === "comments" && br("overview", "feed");
|
|
5608
|
+
const he = Me(e.row.id, pe), re = P.metaKey || P.ctrlKey, ae = de(he);
|
|
5604
5609
|
v((Ae) => {
|
|
5605
5610
|
const W = re ? new Set(Ae) : /* @__PURE__ */ new Set();
|
|
5606
5611
|
return W.add(he), W.add(n), W;
|
|
5607
5612
|
}), ae && (S(ae), O(he));
|
|
5608
5613
|
} else if (e.column.id === "thumbnail") {
|
|
5609
|
-
if (
|
|
5614
|
+
if (l) {
|
|
5610
5615
|
const he = i(e.row.original.primary.id);
|
|
5611
5616
|
if (he) {
|
|
5612
|
-
const re = xn(he);
|
|
5613
|
-
|
|
5617
|
+
const re = xn(he), ae = wr(P);
|
|
5618
|
+
l(re, {
|
|
5619
|
+
quickView: !0,
|
|
5620
|
+
goToPosition: ae?.position,
|
|
5621
|
+
reviewableId: ae?.fileId
|
|
5622
|
+
});
|
|
5614
5623
|
}
|
|
5615
5624
|
}
|
|
5616
5625
|
} else
|
|
5617
|
-
|
|
5626
|
+
c(n);
|
|
5618
5627
|
P.preventDefault();
|
|
5619
5628
|
return;
|
|
5620
5629
|
}
|
|
5621
5630
|
if (x && e.column.id !== "name") return u();
|
|
5622
5631
|
const G = x || nn(e.row.original.primary.entityType) || !!e.row.original.readOnly;
|
|
5623
5632
|
if (L.closest("." + jn) && !G) {
|
|
5624
|
-
a(n) || (T(n, !1, !1), I(n)),
|
|
5633
|
+
a(n) || (T(n, !1, !1), I(n)), c(n);
|
|
5625
5634
|
return;
|
|
5626
5635
|
}
|
|
5627
5636
|
if (E && E !== n) {
|
|
@@ -5659,16 +5668,16 @@ const ta = 24, na = () => {
|
|
|
5659
5668
|
onKeyDown: () => {
|
|
5660
5669
|
},
|
|
5661
5670
|
children: [
|
|
5662
|
-
/* @__PURE__ */ U(
|
|
5663
|
-
|
|
5671
|
+
/* @__PURE__ */ U($o.Provider, { value: X, children: Cn(e.column.columnDef.cell, e.getContext()) }),
|
|
5672
|
+
N?.groupEdge && /* @__PURE__ */ U(gs, { className: N.groupEdge })
|
|
5664
5673
|
]
|
|
5665
5674
|
}
|
|
5666
5675
|
);
|
|
5667
|
-
},
|
|
5676
|
+
}, ba = 150, nc = (e) => {
|
|
5668
5677
|
const { contributions: t } = Cs("tableColumn"), n = H(
|
|
5669
|
-
() => t.filter((d) =>
|
|
5678
|
+
() => t.filter((d) => ks(d, e)),
|
|
5670
5679
|
[t, e]
|
|
5671
|
-
), o = n.some((d) => d.menu === void 0), { data: s } =
|
|
5680
|
+
), o = n.some((d) => d.menu === void 0), { data: s } = cr({}, { skip: !o });
|
|
5672
5681
|
return $e(() => {
|
|
5673
5682
|
n.forEach((d) => {
|
|
5674
5683
|
wn(d.cell), wn(d.fetchValues);
|
|
@@ -5680,18 +5689,18 @@ const ta = 24, na = () => {
|
|
|
5680
5689
|
column: {
|
|
5681
5690
|
id: i,
|
|
5682
5691
|
header: p.label,
|
|
5683
|
-
size: p.width ||
|
|
5692
|
+
size: p.width || ba,
|
|
5684
5693
|
enableSorting: !1,
|
|
5685
5694
|
enableResizing: !0,
|
|
5686
5695
|
enablePinning: !0,
|
|
5687
5696
|
// hidden until the user shows it in Customize, like most columns
|
|
5688
5697
|
enableHiding: !0,
|
|
5689
5698
|
meta: { addonColumn: { contribution: p, page: e } },
|
|
5690
|
-
cell: ({ row:
|
|
5699
|
+
cell: ({ row: l }) => Zs(ra, { contribution: p, page: e, columnId: i, row: l })
|
|
5691
5700
|
}
|
|
5692
5701
|
};
|
|
5693
5702
|
}), h = n.map((p) => {
|
|
5694
|
-
const { addon: i, menu:
|
|
5703
|
+
const { addon: i, menu: l } = p, a = l ?? (s?.addons.find((b) => b.name === i.name)?.title || i.name);
|
|
5695
5704
|
return {
|
|
5696
5705
|
value: es(p),
|
|
5697
5706
|
label: p.label,
|
|
@@ -5704,215 +5713,216 @@ const ta = 24, na = () => {
|
|
|
5704
5713
|
}, [n, e, s]);
|
|
5705
5714
|
};
|
|
5706
5715
|
export {
|
|
5707
|
-
|
|
5708
|
-
|
|
5709
|
-
|
|
5716
|
+
Cd as ALWAYS_VISIBLE_COLUMNS,
|
|
5717
|
+
la as AddonColumnDataScope,
|
|
5718
|
+
rc as BooleanWidget,
|
|
5710
5719
|
Dt as BorderPosition,
|
|
5711
|
-
|
|
5712
|
-
|
|
5713
|
-
|
|
5714
|
-
|
|
5715
|
-
|
|
5716
|
-
|
|
5717
|
-
|
|
5718
|
-
|
|
5719
|
-
|
|
5720
|
-
|
|
5721
|
-
|
|
5722
|
-
|
|
5723
|
-
|
|
5724
|
-
|
|
5725
|
-
|
|
5726
|
-
|
|
5727
|
-
|
|
5728
|
-
|
|
5720
|
+
vd as CELL_PADDING_Y,
|
|
5721
|
+
ic as COLUMN_ICONS,
|
|
5722
|
+
ac as COLUMN_LABELS,
|
|
5723
|
+
lc as COLUMN_MIN_SIZE,
|
|
5724
|
+
cc as COLUMN_SORT_CONFIG,
|
|
5725
|
+
xo as CellEditingContext,
|
|
5726
|
+
Zl as CellEditingProvider,
|
|
5727
|
+
dc as CellWidget,
|
|
5728
|
+
mo as ClipboardContext,
|
|
5729
|
+
ki as ClipboardProvider,
|
|
5730
|
+
uc as CollapsedWidget,
|
|
5731
|
+
ec as ColumnDndProvider,
|
|
5732
|
+
Zi as ColumnHeaderMenu,
|
|
5733
|
+
yo as ColumnSettingsContext,
|
|
5734
|
+
xl as ColumnSettingsProvider,
|
|
5735
|
+
ql as DEFAULT_MAIN_COUNT_LABELS,
|
|
5736
|
+
Wl as DEFAULT_ROW_SCOPE,
|
|
5737
|
+
zl as DEFAULT_SUMMARY_FORMAT,
|
|
5729
5738
|
je as DRAG_HANDLE_COLUMN_ID,
|
|
5730
|
-
|
|
5731
|
-
|
|
5732
|
-
|
|
5739
|
+
fc as DateWidget,
|
|
5740
|
+
ho as DetailsPanelEntityContext,
|
|
5741
|
+
kl as DetailsPanelEntityProvider,
|
|
5733
5742
|
jn as EDIT_TRIGGER_CLASS,
|
|
5734
|
-
|
|
5735
|
-
|
|
5736
|
-
|
|
5737
|
-
|
|
5738
|
-
|
|
5739
|
-
|
|
5740
|
-
|
|
5741
|
-
|
|
5742
|
-
|
|
5743
|
+
pc as ENTITY_COLUMN_IDS,
|
|
5744
|
+
mc as ENTITY_FIELD_SUPPORT,
|
|
5745
|
+
gc as ENTITY_WIDGET_CLASS,
|
|
5746
|
+
yc as EmptyWidget,
|
|
5747
|
+
hc as EntityNameWidget,
|
|
5748
|
+
bc as EntityWidget,
|
|
5749
|
+
Ic as EnumCellValue,
|
|
5750
|
+
wc as EnumWidget,
|
|
5751
|
+
Cc as ErrorWidget,
|
|
5743
5752
|
Tt as GROUP_BY_ID,
|
|
5744
|
-
|
|
5753
|
+
Tc as GroupHeaderWidget,
|
|
5745
5754
|
Hn as HeaderActionButton,
|
|
5746
|
-
|
|
5747
|
-
|
|
5748
|
-
|
|
5755
|
+
Sc as LEGACY_COLUMN_ID_ALIASES,
|
|
5756
|
+
Ed as LISTS_COLUMN_ID,
|
|
5757
|
+
vc as LIST_COLUMNS,
|
|
5749
5758
|
ds as LIST_COLUMN_IDS,
|
|
5750
|
-
|
|
5751
|
-
|
|
5752
|
-
|
|
5753
|
-
|
|
5754
|
-
|
|
5755
|
-
|
|
5756
|
-
|
|
5757
|
-
|
|
5758
|
-
|
|
5759
|
-
|
|
5760
|
-
|
|
5761
|
-
|
|
5762
|
-
|
|
5763
|
-
|
|
5764
|
-
|
|
5765
|
-
|
|
5766
|
-
|
|
5767
|
-
|
|
5768
|
-
|
|
5769
|
-
|
|
5759
|
+
Ec as LinksWidget,
|
|
5760
|
+
xc as ListsWidget,
|
|
5761
|
+
kc as MarkdownWidget,
|
|
5762
|
+
Rc as MetaWidget,
|
|
5763
|
+
Ac as NEXT_PAGE_ID,
|
|
5764
|
+
Ps as NO_MATCH_FOLDER_ID,
|
|
5765
|
+
bo as ProjectDataContext,
|
|
5766
|
+
Rl as ProjectDataProvider,
|
|
5767
|
+
uo as ProjectTableContext,
|
|
5768
|
+
El as ProjectTableProvider,
|
|
5769
|
+
Io as ProjectTableQueriesContext,
|
|
5770
|
+
Al as ProjectTableQueriesProvider,
|
|
5771
|
+
tc as ProjectTreeTable,
|
|
5772
|
+
ko as READ_ONLY,
|
|
5773
|
+
Pc as RESTRICTED_ENTITY_ICON,
|
|
5774
|
+
Dc as RESTRICTED_ENTITY_LABEL,
|
|
5775
|
+
Lc as RESTRICTED_ENTITY_NAME,
|
|
5776
|
+
Oc as RESTRICTED_ENTITY_TYPE,
|
|
5777
|
+
xd as REVIEW_SESSIONS_COLUMN_ID,
|
|
5778
|
+
_c as ROW_ID_SEPARATOR,
|
|
5770
5779
|
pe as ROW_SELECTION_COLUMN_ID,
|
|
5771
|
-
|
|
5772
|
-
|
|
5773
|
-
|
|
5774
|
-
|
|
5775
|
-
|
|
5776
|
-
|
|
5777
|
-
|
|
5778
|
-
|
|
5779
|
-
Mc as
|
|
5780
|
-
|
|
5781
|
-
|
|
5782
|
-
|
|
5783
|
-
|
|
5784
|
-
|
|
5780
|
+
Ji as RowDragHandleCellContent,
|
|
5781
|
+
Fc as RowSelectionHeader,
|
|
5782
|
+
xs as SYSTEM_READ_ONLY_COLUMNS,
|
|
5783
|
+
wo as SelectedRowsContext,
|
|
5784
|
+
Pl as SelectedRowsProvider,
|
|
5785
|
+
Nc as SelectionCell,
|
|
5786
|
+
Eo as SelectionCellsContext,
|
|
5787
|
+
Vl as SelectionCellsProvider,
|
|
5788
|
+
Mc as StyledBaseTextWidget,
|
|
5789
|
+
$c as SubtasksWidget,
|
|
5790
|
+
Pd as TABLE_CONTAINER_ATTR,
|
|
5791
|
+
$o as TableCellContext,
|
|
5792
|
+
Vc as TagsWidget,
|
|
5793
|
+
zc as TextWidget,
|
|
5794
|
+
Bc as ThumbnailWidget,
|
|
5785
5795
|
Gn as UNGROUPED_VALUE,
|
|
5786
|
-
|
|
5787
|
-
|
|
5788
|
-
|
|
5789
|
-
|
|
5790
|
-
|
|
5791
|
-
|
|
5792
|
-
|
|
5793
|
-
|
|
5794
|
-
|
|
5795
|
-
|
|
5796
|
-
|
|
5797
|
-
|
|
5798
|
-
|
|
5796
|
+
kd as WRAP_MIN_CELL_HEIGHT,
|
|
5797
|
+
Rd as WRAP_MIN_ROW_HEIGHT,
|
|
5798
|
+
Dd as allowedGroupByFields,
|
|
5799
|
+
ks as appliesToPage,
|
|
5800
|
+
lo as buildFolderTableRow,
|
|
5801
|
+
Uc as buildGroupId,
|
|
5802
|
+
Gc as buildProductTableRow,
|
|
5803
|
+
Vi as buildQueryFilters,
|
|
5804
|
+
Kl as buildRowScope,
|
|
5805
|
+
Gl as buildSummaryFormat,
|
|
5806
|
+
ao as buildTaskTableRow,
|
|
5807
|
+
Wc as buildVersionTableRow,
|
|
5808
|
+
si as builtInFieldMappings,
|
|
5799
5809
|
en as checkColumnVisibility,
|
|
5800
|
-
|
|
5810
|
+
Hr as clientFilterToQueryFilter,
|
|
5801
5811
|
ze as clipboardError,
|
|
5802
|
-
|
|
5803
|
-
|
|
5804
|
-
|
|
5805
|
-
|
|
5806
|
-
|
|
5807
|
-
|
|
5808
|
-
|
|
5809
|
-
|
|
5810
|
-
|
|
5811
|
-
|
|
5812
|
-
|
|
5812
|
+
pi as commentsToText,
|
|
5813
|
+
Nd as convertDateFilterToQueryFilter,
|
|
5814
|
+
Ql as createLocalStorageKey,
|
|
5815
|
+
Xl as createMetaRowId,
|
|
5816
|
+
Bd as createRelativeValue,
|
|
5817
|
+
Zr as determineLoadingTaskFolders,
|
|
5818
|
+
Td as ensureAtLeastOneVisibleColumn,
|
|
5819
|
+
Kr as expandRelativeDates,
|
|
5820
|
+
Bl as formatHasCount,
|
|
5821
|
+
Ul as formatHasPercent,
|
|
5822
|
+
Jr as generateDummyAttributes,
|
|
5813
5823
|
Ot as generateLoadingRows,
|
|
5814
5824
|
es as getAddonColumnId,
|
|
5815
|
-
|
|
5816
|
-
|
|
5817
|
-
|
|
5825
|
+
vo as getBorderClasses,
|
|
5826
|
+
jc as getCellBorders,
|
|
5827
|
+
Me as getCellId,
|
|
5818
5828
|
qt as getCellValue,
|
|
5819
|
-
|
|
5820
|
-
|
|
5821
|
-
|
|
5829
|
+
Hc as getColumnIcon,
|
|
5830
|
+
Kc as getColumnLabel,
|
|
5831
|
+
So as getColumnSortKey,
|
|
5822
5832
|
rn as getColumnWidth,
|
|
5823
5833
|
an as getCommonPinningStyles,
|
|
5824
|
-
|
|
5834
|
+
Ki as getEntitiesLabelFromScopes,
|
|
5825
5835
|
Ct as getEntityDataById,
|
|
5826
5836
|
xn as getEntityViewierIds,
|
|
5827
|
-
|
|
5828
|
-
|
|
5829
|
-
|
|
5830
|
-
|
|
5831
|
-
|
|
5832
|
-
|
|
5833
|
-
|
|
5834
|
-
|
|
5835
|
-
|
|
5836
|
-
|
|
5837
|
-
|
|
5838
|
-
|
|
5839
|
-
|
|
5840
|
-
|
|
5841
|
-
|
|
5837
|
+
Hi as getFilterErrorMessage,
|
|
5838
|
+
Li as getFolderIdsToQueryFromExpanded,
|
|
5839
|
+
qc as getLinkColumnId,
|
|
5840
|
+
fo as getLinkEntityIdsByColumnId,
|
|
5841
|
+
Qc as getLinkKey,
|
|
5842
|
+
Xc as getLinkLabel,
|
|
5843
|
+
Oo as getNameColumnLabel,
|
|
5844
|
+
ni as getReadOnlyLists,
|
|
5845
|
+
Yc as getScopedColumnId,
|
|
5846
|
+
Jc as getScopedEntity,
|
|
5847
|
+
Zc as getScopedHeader,
|
|
5848
|
+
ed as getScopedValue,
|
|
5849
|
+
td as getSortableColumnOptions,
|
|
5850
|
+
ei as getTableFieldOptions,
|
|
5851
|
+
$i as getTasksSortArgs,
|
|
5842
5852
|
gn as getTypeDefaultValue,
|
|
5843
|
-
|
|
5844
|
-
|
|
5853
|
+
nd as getValueIdType,
|
|
5854
|
+
Wi as hasActiveFilters,
|
|
5845
5855
|
Zn as isAddonColumnId,
|
|
5846
|
-
|
|
5847
|
-
|
|
5848
|
-
|
|
5856
|
+
Er as isAttribGroupable,
|
|
5857
|
+
sd as isColumnSortable,
|
|
5858
|
+
zo as isEntityExpandable,
|
|
5849
5859
|
nn as isEntityRestricted,
|
|
5850
|
-
|
|
5851
|
-
|
|
5860
|
+
od as isFieldSupported,
|
|
5861
|
+
ji as isFilterError,
|
|
5852
5862
|
bn as isGroupId,
|
|
5853
|
-
|
|
5854
|
-
|
|
5855
|
-
|
|
5856
|
-
|
|
5857
|
-
|
|
5858
|
-
|
|
5859
|
-
|
|
5860
|
-
|
|
5861
|
-
|
|
5863
|
+
rd as isLinkEditable,
|
|
5864
|
+
id as isListColumnEntityType,
|
|
5865
|
+
ad as isListsMembershipEntityType,
|
|
5866
|
+
Yl as isMetaRowId,
|
|
5867
|
+
Jl as isMetaRowType,
|
|
5868
|
+
ld as isMultiSelectAttribute,
|
|
5869
|
+
Ud as isRelativeDateValue,
|
|
5870
|
+
li as isSubtasksTSV,
|
|
5871
|
+
Vo as isTargetReadOnly,
|
|
5862
5872
|
Un as linksToTableData,
|
|
5863
|
-
|
|
5864
|
-
|
|
5865
|
-
|
|
5873
|
+
cd as normalizeColumnId,
|
|
5874
|
+
dd as normalizeColumnIdList,
|
|
5875
|
+
go as normalizeColumnsConfig,
|
|
5866
5876
|
de as parseCellId,
|
|
5867
5877
|
Jn as parseClipboardText,
|
|
5868
|
-
|
|
5869
|
-
|
|
5878
|
+
ud as parseGroupId,
|
|
5879
|
+
Ds as parseMetaRowId,
|
|
5870
5880
|
us as parseRowId,
|
|
5871
|
-
|
|
5872
|
-
|
|
5873
|
-
|
|
5874
|
-
|
|
5875
|
-
|
|
5876
|
-
|
|
5877
|
-
|
|
5878
|
-
|
|
5879
|
-
|
|
5880
|
-
|
|
5881
|
-
|
|
5882
|
-
|
|
5883
|
-
|
|
5884
|
-
|
|
5885
|
-
|
|
5881
|
+
fd as parseScopedColumnId,
|
|
5882
|
+
oi as processFieldValue,
|
|
5883
|
+
Md as queryFilterToClientFilter,
|
|
5884
|
+
lr as resolveColumnVisibility,
|
|
5885
|
+
Gd as resolveRelativeValue,
|
|
5886
|
+
Ls as sanitizeQueryFilter,
|
|
5887
|
+
ci as sanitizeSubtaskName,
|
|
5888
|
+
jl as scopeHasGroups,
|
|
5889
|
+
Hl as scopeHasRows,
|
|
5890
|
+
_l as scopeIdsToFolders,
|
|
5891
|
+
pd as sortEntityLinksByPath,
|
|
5892
|
+
vl as subtaskToTSV,
|
|
5893
|
+
ai as subtasksToTSV,
|
|
5894
|
+
$d as tryMergeDatetimeRange,
|
|
5895
|
+
Vd as tryMergeTextNullness,
|
|
5886
5896
|
mn as tsvToSubtasks,
|
|
5887
|
-
|
|
5888
|
-
|
|
5897
|
+
$l as useAddonEntityMenuItems,
|
|
5898
|
+
nc as useAddonTableColumns,
|
|
5889
5899
|
ut as useCellEditing,
|
|
5890
|
-
|
|
5891
|
-
|
|
5892
|
-
|
|
5893
|
-
|
|
5900
|
+
Bi as useCheckSelectedCellsVisible,
|
|
5901
|
+
To as useClipboard,
|
|
5902
|
+
xr as useColumnDragRestriction,
|
|
5903
|
+
Ui as useColumnGroupBy,
|
|
5894
5904
|
dt as useColumnSettingsContext,
|
|
5895
5905
|
fs as useDetailsPanelEntityContext,
|
|
5896
|
-
|
|
5897
|
-
|
|
5898
|
-
|
|
5899
|
-
|
|
5900
|
-
|
|
5901
|
-
|
|
5902
|
-
|
|
5903
|
-
|
|
5904
|
-
|
|
5905
|
-
|
|
5906
|
-
|
|
5907
|
-
|
|
5906
|
+
Ol as useEntitiesMap,
|
|
5907
|
+
md as useEntityListsMembership,
|
|
5908
|
+
Ml as useExpandedState,
|
|
5909
|
+
Fo as useFetchListsMembership,
|
|
5910
|
+
Dl as useFetchOverviewData,
|
|
5911
|
+
io as useGetEntityTypeData,
|
|
5912
|
+
Ld as useGetGroupedFields,
|
|
5913
|
+
_d as useGroupCounts,
|
|
5914
|
+
gd as useOptionalCellEditing,
|
|
5915
|
+
yd as useOptionalProjectTableContext,
|
|
5916
|
+
hd as useOptionalSelectedRowsContext,
|
|
5917
|
+
bd as useOptionalSelectionCellsContext,
|
|
5908
5918
|
Tn as useProjectDataContext,
|
|
5909
5919
|
Ke as useProjectTableContext,
|
|
5910
|
-
|
|
5911
|
-
|
|
5912
|
-
|
|
5913
|
-
|
|
5920
|
+
Co as useProjectTableQueriesContext,
|
|
5921
|
+
Ll as useQueryFilters,
|
|
5922
|
+
Nl as useScopedAttributeFields,
|
|
5923
|
+
Fl as useSelectedFolders,
|
|
5914
5924
|
Mo as useSelectedRowsContext,
|
|
5915
5925
|
et as useSelectionCellsContext,
|
|
5916
|
-
|
|
5917
|
-
|
|
5926
|
+
Id as useTableCellContext,
|
|
5927
|
+
ii as validateClipboardData
|
|
5918
5928
|
};
|