@ynput/ayon-frontend-shared 0.6.8 → 0.6.9
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 +2 -2
- package/dist/Feed.es.js +64 -58
- package/dist/ListTable.es.js +3 -3
- package/dist/NewEntity.es.js +2 -2
- package/dist/ProjectTreeTable.es.js +1314 -1314
- package/dist/chunks/ColumnDropIndicator.es.js +2 -2
- package/dist/chunks/Feed.es.js +783 -804
- package/dist/chunks/MetaWidget.es.js +814 -825
- package/dist/chunks/PlayableIcon.es.js +123 -84
- package/dist/chunks/ReviewablesSelector.es.js +2 -2
- package/dist/chunks/SimpleForm.es.js +10 -9
- package/dist/chunks/Slicer.es.js +2 -2
- package/dist/chunks/Watchers.es.js +2 -2
- package/dist/chunks/getBundleMode.es.js +33 -25
- package/dist/chunks/useDateRangeFilter.es.js +85 -59
- package/dist/chunks/viewUpdateHelper.es.js +30 -30
- package/dist/components.es.js +791 -753
- package/dist/context.es.js +83 -82
- package/dist/hooks.es.js +2 -2
- package/dist/index.es.js +2 -2
- package/dist/types/Feed.d.ts +54 -0
- package/dist/types/ProjectTreeTable.d.ts +5 -2
- package/dist/types/components.d.ts +512 -0
- package/dist/types/util.d.ts +4 -0
- package/dist/util.es.js +67 -65
- package/package.json +1 -1
package/dist/components.es.js
CHANGED
|
@@ -1,119 +1,119 @@
|
|
|
1
|
-
import { C as
|
|
2
|
-
import { m as
|
|
3
|
-
import { jsxs as
|
|
4
|
-
import { useState as
|
|
5
|
-
import { matchSorter as
|
|
6
|
-
import { InputText as it, Icon as le, Section as
|
|
7
|
-
import
|
|
8
|
-
import { B as
|
|
1
|
+
import { C as $e, S as ze, A as Ce, a as Ke, T as je, D as Xe, b as Qe, c as Je, d as Oe, e as Se, f as qe, g as Ze, h as et, M as tt, F as at, i as st, j as ot, k as nt, l as rt } from "./chunks/ReviewablesSelector.es.js";
|
|
2
|
+
import { m as cs, n as ds, o as ps, p as fs, q as ms, r as hs, s as gs, E as bs, t as ws, u as ys, v as vs, w as Es, x as ks, G as Cs, y as Os, L as Ss, P as Ts, z as Ds, R as Vs, B as Rs, H as Is, I as As, J as Fs, K as _s, N as Ps, O as xs, Q as Ns, U as Ls, V as Ms, W as Bs, X as Us, Y as Gs, Z as Ws } from "./chunks/ReviewablesSelector.es.js";
|
|
3
|
+
import { jsxs as Y, jsx as k } from "react/jsx-runtime";
|
|
4
|
+
import { useState as P, useRef as oe, useCallback as ee, useEffect as $, useMemo as me, useContext as lt } from "react";
|
|
5
|
+
import { matchSorter as Te } from "match-sorter";
|
|
6
|
+
import { InputText as it, Icon as le, Section as ut, SEARCH_FILTER_ID as ct } from "@ynput/ayon-react-components";
|
|
7
|
+
import ce from "clsx";
|
|
8
|
+
import { B as Hs, a as $s, S as zs } from "./chunks/SimpleForm.es.js";
|
|
9
9
|
import { d as dt, P as pt } from "./chunks/MetaWidget.es.js";
|
|
10
|
-
import { A as
|
|
10
|
+
import { A as js, i as Xs, D as Qs, E as Js, L as qs, j as Zs, k as eo, l as to, m as ao } from "./chunks/MetaWidget.es.js";
|
|
11
11
|
import { createPortal as ft } from "react-dom";
|
|
12
|
-
import { format as re, parseISO as
|
|
13
|
-
import { B as
|
|
14
|
-
import {
|
|
12
|
+
import { format as re, parseISO as Ne, isValid as Le } from "date-fns";
|
|
13
|
+
import { B as De, e as Me, g as we, h as ye } from "./chunks/PlayableIcon.es.js";
|
|
14
|
+
import { $ as oo, j as no, k as ro, l as lo, m as io, n as uo, o as co, q as po, A as fo, C as mo, a as ho, r as go, D as bo, s as wo, t as yo, F as vo, I as Eo, u as ko, v as Co, w as Oo, x as So, y as To, M as Do, z as Vo, E as Ro, N as Io, U as Ao, Y as Fo, G as _o, H as Po, J as xo, K as No, d as Lo, f as Mo, L as Bo, O as Uo, P as Go, Q as Wo, R as Yo, S as Ho, T as $o, V as zo, W as Ko, X as jo, p as Xo, Z as Qo } from "./chunks/PlayableIcon.es.js";
|
|
15
15
|
import { d as Be, x as mt, a as ht, e as gt } from "./chunks/DeleteEntitiesContextInstance.es.js";
|
|
16
|
-
import { f as
|
|
17
|
-
import { p as bt, a as
|
|
18
|
-
import { D as
|
|
19
|
-
import { D as
|
|
16
|
+
import { f as qo, D as Zo, R as en } from "./chunks/DeleteEntitiesContextInstance.es.js";
|
|
17
|
+
import { p as bt, a as Ve } from "./chunks/DeleteEntitiesConfirmDialog.es.js";
|
|
18
|
+
import { D as an, b as sn, c as on, d as nn, e as rn, s as ln } from "./chunks/DeleteEntitiesConfirmDialog.es.js";
|
|
19
|
+
import { D as cn } from "./chunks/DetailsDialog.es.js";
|
|
20
20
|
import { q as wt, r as yt, n as vt } from "./chunks/Watchers.es.js";
|
|
21
|
-
import { s as
|
|
22
|
-
import { E as
|
|
23
|
-
import { E as
|
|
24
|
-
import { I as
|
|
25
|
-
import { J as
|
|
26
|
-
import { E as
|
|
27
|
-
import { E as
|
|
28
|
-
import { bk as Re, bq as Et, bs as
|
|
29
|
-
import { bL as
|
|
21
|
+
import { s as pn, t as fn, v as mn, R as hn, c as gn, b as bn, w as wn, x as yn, W as vn, u as En } from "./chunks/Watchers.es.js";
|
|
22
|
+
import { E as Cn, P as On } from "./chunks/EmptyPlaceholder.es.js";
|
|
23
|
+
import { E as Tn, b as Dn, c as Vn, d as Rn, a as In, M as An, e as Fn } from "./chunks/Menu.es.js";
|
|
24
|
+
import { I as Pn } from "./chunks/InfoMessage.es.js";
|
|
25
|
+
import { J as Nn } from "./chunks/JsonViewer.es.js";
|
|
26
|
+
import { E as Mn, a as Bn, R as Un, g as Gn } from "./chunks/EntityPath.es.js";
|
|
27
|
+
import { E as Yn, a as Hn } from "./chunks/EntityTooltip.es.js";
|
|
28
|
+
import { bk as Re, bq as Et, bs as kt } from "./chunks/searchTerms.es.js";
|
|
29
|
+
import { bL as Ct, bQ as Ot, cv as St, aK as Tt, aP as Dt, bG as Vt, bn as Rt, dm as It, c8 as At, bO as Ft } from "./chunks/getUris.es.js";
|
|
30
30
|
export * from "primereact/confirmdialog";
|
|
31
31
|
import "@module-federation/enhanced/runtime";
|
|
32
32
|
import { toast as he } from "react-toastify";
|
|
33
|
-
import { isEmpty as
|
|
33
|
+
import { isEmpty as _t, upperFirst as de } from "lodash";
|
|
34
34
|
import "uuid";
|
|
35
|
-
import { a as
|
|
35
|
+
import { a as Pt } from "./chunks/afterStartup.es.js";
|
|
36
36
|
import "semver";
|
|
37
37
|
import "./chunks/ContextMenuContextInstance.es.js";
|
|
38
38
|
import "react-redux";
|
|
39
39
|
import { F as xt } from "./chunks/ColumnDropIndicator.styled.es.js";
|
|
40
|
-
import { C as
|
|
41
|
-
import { F as
|
|
40
|
+
import { C as Kn, S as jn, b as Xn, u as Qn } from "./chunks/ColumnDropIndicator.styled.es.js";
|
|
41
|
+
import { F as qn } from "./chunks/FilterErrorActions.es.js";
|
|
42
42
|
import "lexical";
|
|
43
43
|
import "@lexical/markdown";
|
|
44
|
-
import "@lexical/react/LexicalBlockWithAlignableContents";
|
|
45
|
-
import "@lexical/react/LexicalDecoratorBlockNode";
|
|
46
44
|
import "@lexical/code";
|
|
47
45
|
import "@lexical/list";
|
|
48
46
|
import "@lexical/rich-text";
|
|
49
47
|
import "@lexical/selection";
|
|
50
48
|
import "@lexical/utils";
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import {
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import { g as
|
|
49
|
+
import "@lexical/react/LexicalBlockWithAlignableContents";
|
|
50
|
+
import "@lexical/react/LexicalDecoratorBlockNode";
|
|
51
|
+
import { m as er, r as tr, a as ar, u as sr } from "./chunks/useDateRangeFilter.es.js";
|
|
52
|
+
import { T as nr } from "./chunks/TableSettingsFallback.es.js";
|
|
53
|
+
import { a as Nt, b as Lt } from "./chunks/viewUpdateHelper.es.js";
|
|
54
|
+
import { useSearchParams as Mt, useLocation as Bt, useNavigate as Ut, useParams as Gt } from "react-router-dom";
|
|
55
|
+
import { g as Wt, c as Yt, b as Ht, d as $t } from "./chunks/Slicer.es.js";
|
|
56
|
+
import { l as lr } from "./chunks/Slicer.es.js";
|
|
57
|
+
import { Splitter as zt, SplitterPanel as Ie } from "primereact/splitter";
|
|
58
|
+
import { g as se } from "./chunks/getEntityTypeIcon.es.js";
|
|
58
59
|
import { g as K } from "./chunks/iconUtils.es.js";
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import { T as In } from "./chunks/EntityPickerDialog.es.js";
|
|
60
|
+
import { C as ur, T as cr } from "./chunks/ThumbnailSimple.es.js";
|
|
61
|
+
import { S as pr } from "./chunks/SimpleFormDialog.es.js";
|
|
62
|
+
import { T as mr } from "./chunks/EntityPickerDialog.es.js";
|
|
63
63
|
import { e as Kt } from "./chunks/extractVersionFromFilename.es.js";
|
|
64
64
|
import { b as jt, c as Xt, v as Qt } from "./chunks/versionUploadHelpers.es.js";
|
|
65
65
|
import { p as Jt } from "./chunks/parseFilename.es.js";
|
|
66
66
|
import { V as qt } from "./chunks/VersionUploadContextInstance.es.js";
|
|
67
|
-
import { u as
|
|
68
|
-
import { C as
|
|
69
|
-
const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/,
|
|
67
|
+
import { u as gr, a as br } from "./chunks/VersionUploadContextInstance.es.js";
|
|
68
|
+
import { C as yr } from "./chunks/ColumnHeaderMenuUI.es.js";
|
|
69
|
+
const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xa = ({
|
|
70
70
|
shareOptions: t,
|
|
71
71
|
existingAccess: e,
|
|
72
72
|
owner: i,
|
|
73
|
-
placeholder:
|
|
73
|
+
placeholder: u = "Add people or access groups",
|
|
74
74
|
disabled: o = !1,
|
|
75
|
-
mode:
|
|
76
|
-
onSelectOption:
|
|
75
|
+
mode: a = "internal",
|
|
76
|
+
onSelectOption: s,
|
|
77
77
|
pt: h,
|
|
78
78
|
...l
|
|
79
79
|
}) => {
|
|
80
|
-
const [f, n] =
|
|
81
|
-
const v = (p) => p.value === "__everyone__" ? 0 : p.value.startsWith("__") ? 1 : p.value.startsWith("team:") ? 2 : p.value.startsWith("group:") ? 3 : p.value.startsWith("user:") ? 4 : 5,
|
|
82
|
-
return
|
|
83
|
-
}), g = (f ?
|
|
80
|
+
const [f, n] = P(""), [E, y] = P(!1), [T, m] = P(-1), A = oe(null), R = t.filter((D) => !e.includes(D.value)).toSorted((D, b) => {
|
|
81
|
+
const v = (p) => p.value === "__everyone__" ? 0 : p.value.startsWith("__") ? 1 : p.value.startsWith("team:") ? 2 : p.value.startsWith("group:") ? 3 : p.value.startsWith("user:") ? 4 : 5, S = v(D), r = v(b);
|
|
82
|
+
return S !== r ? S - r : D.label.localeCompare(b.label);
|
|
83
|
+
}), g = (f ? Te(R, f, {
|
|
84
84
|
keys: ["name", "label", "value"],
|
|
85
|
-
threshold:
|
|
86
|
-
}) : R).slice(0, Ae),
|
|
85
|
+
threshold: Te.rankings.CONTAINS
|
|
86
|
+
}) : R).slice(0, Ae), V = Zt.test(f) && !t.some((D) => D.name === f) && a === "external", I = () => {
|
|
87
87
|
y(!0), m(-1);
|
|
88
|
-
},
|
|
88
|
+
}, L = () => {
|
|
89
89
|
setTimeout(() => {
|
|
90
90
|
y(!1), m(-1);
|
|
91
91
|
}, 200);
|
|
92
|
-
},
|
|
93
|
-
n(
|
|
94
|
-
}, M = (
|
|
92
|
+
}, N = (D) => {
|
|
93
|
+
n(D.target.value), m(-1), y(!0);
|
|
94
|
+
}, M = (D) => {
|
|
95
95
|
if (!E || g.length === 0) {
|
|
96
|
-
|
|
96
|
+
D.key === "Enter" && g.length > 0 && (D.preventDefault(), H(g[0]));
|
|
97
97
|
return;
|
|
98
98
|
}
|
|
99
|
-
switch (
|
|
99
|
+
switch (D.key) {
|
|
100
100
|
case "ArrowDown":
|
|
101
|
-
|
|
101
|
+
D.preventDefault(), m((b) => b < g.length - 1 ? b + 1 : b);
|
|
102
102
|
break;
|
|
103
103
|
case "ArrowUp":
|
|
104
|
-
|
|
104
|
+
D.preventDefault(), m((b) => b > 0 ? b - 1 : -1);
|
|
105
105
|
break;
|
|
106
106
|
case "Enter":
|
|
107
|
-
|
|
107
|
+
D.preventDefault(), T >= 0 && T < g.length ? H(g[T]) : g.length > 0 && H(g[0]);
|
|
108
108
|
break;
|
|
109
109
|
case "Escape":
|
|
110
|
-
y(!1), m(-1), A.current?.blur(),
|
|
110
|
+
y(!1), m(-1), A.current?.blur(), D.stopPropagation();
|
|
111
111
|
break;
|
|
112
112
|
}
|
|
113
|
-
},
|
|
114
|
-
|
|
115
|
-
},
|
|
116
|
-
|
|
113
|
+
}, H = (D) => {
|
|
114
|
+
s(D, 10), n(""), y(!1), m(-1), A.current?.focus();
|
|
115
|
+
}, z = () => {
|
|
116
|
+
s(
|
|
117
117
|
{
|
|
118
118
|
name: f,
|
|
119
119
|
label: f,
|
|
@@ -123,48 +123,48 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
123
123
|
10
|
|
124
124
|
), n(""), y(!1), m(-1), A.current?.focus();
|
|
125
125
|
};
|
|
126
|
-
return /* @__PURE__ */
|
|
127
|
-
/* @__PURE__ */
|
|
126
|
+
return /* @__PURE__ */ Y($e, { ...l, children: [
|
|
127
|
+
/* @__PURE__ */ k(
|
|
128
128
|
it,
|
|
129
129
|
{
|
|
130
130
|
ref: A,
|
|
131
131
|
value: f,
|
|
132
|
-
placeholder:
|
|
132
|
+
placeholder: u,
|
|
133
133
|
disabled: o,
|
|
134
134
|
onFocus: I,
|
|
135
135
|
onClick: I,
|
|
136
|
-
onBlur:
|
|
137
|
-
onChange:
|
|
136
|
+
onBlur: L,
|
|
137
|
+
onChange: N,
|
|
138
138
|
onKeyDown: M,
|
|
139
139
|
style: { width: "100%" }
|
|
140
140
|
}
|
|
141
141
|
),
|
|
142
|
-
E && (g.length > 0 ||
|
|
143
|
-
|
|
142
|
+
E && (g.length > 0 || V) && /* @__PURE__ */ Y(
|
|
143
|
+
ze,
|
|
144
144
|
{
|
|
145
145
|
...h?.list,
|
|
146
|
-
className:
|
|
146
|
+
className: ce(h?.list?.className, { "no-owner": !i }),
|
|
147
147
|
children: [
|
|
148
|
-
g.map((
|
|
149
|
-
|
|
148
|
+
g.map((D, b) => /* @__PURE__ */ k(
|
|
149
|
+
Ce,
|
|
150
150
|
{
|
|
151
|
-
name:
|
|
152
|
-
label:
|
|
153
|
-
shareType:
|
|
151
|
+
name: D.name,
|
|
152
|
+
label: D.label,
|
|
153
|
+
shareType: D.shareType,
|
|
154
154
|
isOwner: !1,
|
|
155
155
|
isMe: !1,
|
|
156
156
|
"data-index": b,
|
|
157
|
-
className: b ===
|
|
157
|
+
className: b === T ? "highlighted" : "",
|
|
158
158
|
style: { cursor: "pointer" },
|
|
159
|
-
onClick: () =>
|
|
159
|
+
onClick: () => H(D),
|
|
160
160
|
onMouseEnter: () => m(b),
|
|
161
161
|
isCompact: !0,
|
|
162
162
|
isSearchResult: !0
|
|
163
163
|
},
|
|
164
|
-
|
|
164
|
+
D.value
|
|
165
165
|
)),
|
|
166
|
-
|
|
167
|
-
|
|
166
|
+
V && /* @__PURE__ */ k(
|
|
167
|
+
Ce,
|
|
168
168
|
{
|
|
169
169
|
name: f,
|
|
170
170
|
label: f,
|
|
@@ -172,20 +172,20 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
172
172
|
isOwner: !1,
|
|
173
173
|
isMe: !1,
|
|
174
174
|
"data-index": g.length,
|
|
175
|
-
className: g.length ===
|
|
175
|
+
className: g.length === T ? "highlighted" : "",
|
|
176
176
|
style: { cursor: "pointer" },
|
|
177
|
-
onClick:
|
|
177
|
+
onClick: z,
|
|
178
178
|
onMouseEnter: () => m(g.length),
|
|
179
179
|
isCompact: !0,
|
|
180
180
|
isSearchResult: !0
|
|
181
181
|
}
|
|
182
182
|
),
|
|
183
|
-
g.length === Ae && /* @__PURE__ */
|
|
183
|
+
g.length === Ae && /* @__PURE__ */ k("li", { className: "tip", children: "More than 500 results, please refine your search..." })
|
|
184
184
|
]
|
|
185
185
|
}
|
|
186
186
|
)
|
|
187
187
|
] });
|
|
188
|
-
},
|
|
188
|
+
}, Qa = {
|
|
189
189
|
0: "No access",
|
|
190
190
|
10: "Viewer",
|
|
191
191
|
20: "Editor",
|
|
@@ -193,130 +193,130 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
193
193
|
}, Fe = (t) => {
|
|
194
194
|
if (!t) return "";
|
|
195
195
|
try {
|
|
196
|
-
const e =
|
|
197
|
-
if (
|
|
196
|
+
const e = Ne(t);
|
|
197
|
+
if (Le(e))
|
|
198
198
|
return Me(e, "yyyy-MM-dd");
|
|
199
199
|
} catch {
|
|
200
200
|
return "";
|
|
201
201
|
}
|
|
202
202
|
return "";
|
|
203
|
-
},
|
|
203
|
+
}, _e = (t, e) => {
|
|
204
204
|
if (!t) return null;
|
|
205
205
|
try {
|
|
206
|
-
const i =
|
|
207
|
-
if (
|
|
206
|
+
const i = Ne(t);
|
|
207
|
+
if (Le(i))
|
|
208
208
|
return Me(i, e);
|
|
209
209
|
} catch {
|
|
210
210
|
return null;
|
|
211
211
|
}
|
|
212
212
|
return null;
|
|
213
|
-
},
|
|
213
|
+
}, ae = (t) => {
|
|
214
214
|
if (!t) return null;
|
|
215
215
|
try {
|
|
216
|
-
const [e, i,
|
|
217
|
-
if (e && i &&
|
|
218
|
-
return new Date(Date.UTC(e, i - 1,
|
|
216
|
+
const [e, i, u] = t.split("-").map(Number);
|
|
217
|
+
if (e && i && u)
|
|
218
|
+
return new Date(Date.UTC(e, i - 1, u)).toISOString();
|
|
219
219
|
} catch {
|
|
220
220
|
return null;
|
|
221
221
|
}
|
|
222
222
|
return null;
|
|
223
|
-
},
|
|
223
|
+
}, Ja = ({
|
|
224
224
|
value: t,
|
|
225
225
|
onChange: e,
|
|
226
226
|
emptyTrigger: i,
|
|
227
|
-
valueTrigger:
|
|
227
|
+
valueTrigger: u,
|
|
228
228
|
align: o = "left",
|
|
229
|
-
disabled:
|
|
230
|
-
className:
|
|
229
|
+
disabled: a = !1,
|
|
230
|
+
className: s,
|
|
231
231
|
displayFormat: h = "MMM d",
|
|
232
232
|
minDate: l,
|
|
233
233
|
maxDate: f,
|
|
234
234
|
pt: n
|
|
235
235
|
}) => {
|
|
236
|
-
const [E, y] =
|
|
237
|
-
const w =
|
|
236
|
+
const [E, y] = P(!1), [T, m] = P(""), [A, R] = P(""), g = oe(null), V = oe(null), I = oe(null), L = oe(null), N = t.startDate || t.endDate, M = ee(() => {
|
|
237
|
+
const w = ae(T), x = ae(A);
|
|
238
238
|
(w !== t.startDate || x !== t.endDate) && e({ startDate: w, endDate: x }), y(!1);
|
|
239
|
-
}, [
|
|
240
|
-
|
|
239
|
+
}, [T, A, t.startDate, t.endDate, e]);
|
|
240
|
+
$(() => {
|
|
241
241
|
E && (m(Fe(t.startDate)), R(Fe(t.endDate)), !t.startDate && !t.endDate && setTimeout(() => {
|
|
242
242
|
try {
|
|
243
243
|
I.current?.showPicker();
|
|
244
244
|
} catch {
|
|
245
245
|
}
|
|
246
246
|
}, 100));
|
|
247
|
-
}, [E, t.startDate, t.endDate]),
|
|
247
|
+
}, [E, t.startDate, t.endDate]), $(() => {
|
|
248
248
|
if (!E) return;
|
|
249
249
|
const w = (x) => {
|
|
250
250
|
const B = x.target;
|
|
251
|
-
g.current && !g.current.contains(B) &&
|
|
251
|
+
g.current && !g.current.contains(B) && V.current && !V.current.contains(B) && M();
|
|
252
252
|
};
|
|
253
253
|
return document.addEventListener("mousedown", w), () => document.removeEventListener("mousedown", w);
|
|
254
|
-
}, [E, M]),
|
|
254
|
+
}, [E, M]), $(() => {
|
|
255
255
|
if (!E) return;
|
|
256
256
|
const w = (x) => {
|
|
257
257
|
x.key === "Escape" && (x.stopPropagation(), M());
|
|
258
258
|
};
|
|
259
259
|
return document.addEventListener("keydown", w), () => document.removeEventListener("keydown", w);
|
|
260
260
|
}, [E, M]);
|
|
261
|
-
const
|
|
261
|
+
const H = (w) => {
|
|
262
262
|
const x = w.target.value;
|
|
263
263
|
m(x);
|
|
264
|
-
const B =
|
|
265
|
-
if (B &&
|
|
266
|
-
const j = new Date(B), te = new Date(
|
|
264
|
+
const B = ae(x), G = ae(A);
|
|
265
|
+
if (B && G) {
|
|
266
|
+
const j = new Date(B), te = new Date(G);
|
|
267
267
|
j > te && R(x);
|
|
268
268
|
}
|
|
269
269
|
B && setTimeout(() => {
|
|
270
270
|
try {
|
|
271
|
-
|
|
271
|
+
L.current?.showPicker();
|
|
272
272
|
} catch {
|
|
273
273
|
}
|
|
274
274
|
}, 100);
|
|
275
|
-
},
|
|
275
|
+
}, z = (w) => {
|
|
276
276
|
const x = w.target.value;
|
|
277
277
|
R(x);
|
|
278
|
-
const B =
|
|
279
|
-
let j =
|
|
280
|
-
if (B &&
|
|
281
|
-
const q = new Date(
|
|
278
|
+
const B = ae(x), G = ae(T);
|
|
279
|
+
let j = G, te = B;
|
|
280
|
+
if (B && G) {
|
|
281
|
+
const q = new Date(G);
|
|
282
282
|
new Date(B) < q && (m(x), j = B);
|
|
283
283
|
}
|
|
284
284
|
e({ startDate: j, endDate: te });
|
|
285
|
-
},
|
|
285
|
+
}, D = () => {
|
|
286
286
|
m(""), R(""), e({ startDate: null, endDate: null }), y(!1);
|
|
287
287
|
}, b = (w) => {
|
|
288
|
-
w.stopPropagation(),
|
|
289
|
-
}, v = E ?
|
|
288
|
+
w.stopPropagation(), a || (E ? M() : y(!0));
|
|
289
|
+
}, v = E ? ae(T) : t.startDate, S = E ? ae(A) : t.endDate, r = _e(v, h), p = _e(S, h), c = r && p ? `${r} - ${p}` : r || p || "", d = () => {
|
|
290
290
|
if (!g.current) return { top: 0, left: 0 };
|
|
291
291
|
const w = g.current.getBoundingClientRect();
|
|
292
292
|
return {
|
|
293
293
|
top: w.bottom + 4,
|
|
294
294
|
left: o === "left" ? w.left : w.right
|
|
295
295
|
};
|
|
296
|
-
},
|
|
297
|
-
return /* @__PURE__ */
|
|
296
|
+
}, C = () => N ? u ? u(t, c) : /* @__PURE__ */ k("span", { className: ce("date-value", n?.valueDisplay?.className), ...n?.valueDisplay, children: c }) : i || /* @__PURE__ */ k(Ze, { icon: "calendar_add_on" }), F = d();
|
|
297
|
+
return /* @__PURE__ */ Y(
|
|
298
298
|
Ke,
|
|
299
299
|
{
|
|
300
300
|
...n?.root,
|
|
301
|
-
className:
|
|
301
|
+
className: ce(De, s, n?.root?.className),
|
|
302
302
|
children: [
|
|
303
|
-
/* @__PURE__ */
|
|
303
|
+
/* @__PURE__ */ k(
|
|
304
304
|
je,
|
|
305
305
|
{
|
|
306
306
|
ref: g,
|
|
307
307
|
onClick: b,
|
|
308
|
-
disabled:
|
|
308
|
+
disabled: a,
|
|
309
309
|
type: "button",
|
|
310
310
|
...n?.trigger,
|
|
311
|
-
className:
|
|
312
|
-
children:
|
|
311
|
+
className: ce(N ? "has-value" : "empty", n?.trigger?.className),
|
|
312
|
+
children: C()
|
|
313
313
|
}
|
|
314
314
|
),
|
|
315
315
|
E && ft(
|
|
316
|
-
/* @__PURE__ */
|
|
316
|
+
/* @__PURE__ */ k(
|
|
317
317
|
Xe,
|
|
318
318
|
{
|
|
319
|
-
ref:
|
|
319
|
+
ref: V,
|
|
320
320
|
style: {
|
|
321
321
|
top: F.top,
|
|
322
322
|
left: o === "left" ? F.left : "auto",
|
|
@@ -325,9 +325,9 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
325
325
|
},
|
|
326
326
|
onMouseDown: (w) => w.stopPropagation(),
|
|
327
327
|
...n?.dropdown,
|
|
328
|
-
className:
|
|
329
|
-
children: /* @__PURE__ */
|
|
330
|
-
/* @__PURE__ */
|
|
328
|
+
className: ce(De, o, n?.dropdown?.className),
|
|
329
|
+
children: /* @__PURE__ */ Y(Qe, { className: n?.content?.className, ...n?.content, children: [
|
|
330
|
+
/* @__PURE__ */ k(
|
|
331
331
|
Je,
|
|
332
332
|
{
|
|
333
333
|
icon: "close",
|
|
@@ -336,20 +336,20 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
336
336
|
...n?.closeButton
|
|
337
337
|
}
|
|
338
338
|
),
|
|
339
|
-
/* @__PURE__ */
|
|
340
|
-
|
|
339
|
+
/* @__PURE__ */ Y(
|
|
340
|
+
Oe,
|
|
341
341
|
{
|
|
342
342
|
className: n?.startDate?.field?.className,
|
|
343
343
|
...n?.startDate?.field,
|
|
344
344
|
children: [
|
|
345
|
-
/* @__PURE__ */
|
|
346
|
-
/* @__PURE__ */
|
|
347
|
-
|
|
345
|
+
/* @__PURE__ */ k("label", { ...n?.startDate?.label, children: "Start date" }),
|
|
346
|
+
/* @__PURE__ */ k(
|
|
347
|
+
Se,
|
|
348
348
|
{
|
|
349
349
|
ref: I,
|
|
350
350
|
type: "date",
|
|
351
|
-
value:
|
|
352
|
-
onChange:
|
|
351
|
+
value: T,
|
|
352
|
+
onChange: H,
|
|
353
353
|
max: f ? re(f, "yyyy-MM-dd") : void 0,
|
|
354
354
|
min: l ? re(l, "yyyy-MM-dd") : void 0,
|
|
355
355
|
onClick: (w) => {
|
|
@@ -364,17 +364,17 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
364
364
|
]
|
|
365
365
|
}
|
|
366
366
|
),
|
|
367
|
-
/* @__PURE__ */
|
|
368
|
-
/* @__PURE__ */
|
|
369
|
-
/* @__PURE__ */
|
|
370
|
-
|
|
367
|
+
/* @__PURE__ */ Y(Oe, { className: n?.endDate?.field?.className, ...n?.endDate?.field, children: [
|
|
368
|
+
/* @__PURE__ */ k("label", { ...n?.endDate?.label, children: "End date" }),
|
|
369
|
+
/* @__PURE__ */ k(
|
|
370
|
+
Se,
|
|
371
371
|
{
|
|
372
|
-
ref:
|
|
372
|
+
ref: L,
|
|
373
373
|
type: "date",
|
|
374
374
|
value: A,
|
|
375
|
-
onChange:
|
|
375
|
+
onChange: z,
|
|
376
376
|
max: f ? re(f, "yyyy-MM-dd") : void 0,
|
|
377
|
-
min:
|
|
377
|
+
min: T || (l ? re(l, "yyyy-MM-dd") : void 0),
|
|
378
378
|
onClick: (w) => {
|
|
379
379
|
try {
|
|
380
380
|
w.currentTarget.showPicker();
|
|
@@ -385,7 +385,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
385
385
|
}
|
|
386
386
|
)
|
|
387
387
|
] }),
|
|
388
|
-
|
|
388
|
+
N && /* @__PURE__ */ k(qe, { onClick: D, variant: "text", ...n?.clearButton, children: "Clear dates" })
|
|
389
389
|
] })
|
|
390
390
|
}
|
|
391
391
|
),
|
|
@@ -398,84 +398,84 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
398
398
|
version: 1,
|
|
399
399
|
name: "review",
|
|
400
400
|
productType: "review"
|
|
401
|
-
},
|
|
401
|
+
}, qa = ({
|
|
402
402
|
children: t,
|
|
403
403
|
projectName: e,
|
|
404
404
|
onVersionCreated: i,
|
|
405
|
-
dispatch:
|
|
405
|
+
dispatch: u
|
|
406
406
|
}) => {
|
|
407
|
-
const [o,
|
|
407
|
+
const [o, a] = P(""), [s, h] = P(""), [l, f] = P(null), [n, E] = P(null), [y, T] = P(!1), [m, A] = P([]), [R, g] = P(ne), [V, I] = P(!1), [L, N] = P(""), [M, H] = P(null), [z, D] = P(null), [b, v] = P(void 0), [S, r] = P(void 0), p = oe(!1), c = oe(null), { data: d = [], isLoading: C } = Ct(
|
|
408
408
|
{ projectName: e, folderId: o },
|
|
409
|
-
{ skip: !o || !y || !!
|
|
409
|
+
{ skip: !o || !y || !!s }
|
|
410
410
|
), F = me(() => {
|
|
411
|
-
if (!(
|
|
412
|
-
return d.find((
|
|
413
|
-
}, [
|
|
411
|
+
if (!(s || !R.name || d.length === 0))
|
|
412
|
+
return d.find((O) => O.name === R.name);
|
|
413
|
+
}, [s, R.name, d]), w = s || F?.id || "", { currentData: x } = Ot(
|
|
414
414
|
{
|
|
415
415
|
projectName: e,
|
|
416
|
-
productId:
|
|
416
|
+
productId: s
|
|
417
417
|
},
|
|
418
|
-
{ skip: !
|
|
419
|
-
), { data: B } =
|
|
420
|
-
{ projectName: e, versionId:
|
|
421
|
-
{ skip: !
|
|
422
|
-
),
|
|
423
|
-
({ productId:
|
|
424
|
-
h(
|
|
425
|
-
...
|
|
418
|
+
{ skip: !s || !y || b != null }
|
|
419
|
+
), { data: B } = St(
|
|
420
|
+
{ projectName: e, versionId: S },
|
|
421
|
+
{ skip: !S || !y || l !== null }
|
|
422
|
+
), G = l ?? B?.taskId ?? "", j = !!(S && l === null && !B), te = ee(
|
|
423
|
+
({ productId: O, folderId: _, taskId: U, linkedTask: Z, latestVersionNumber: ie, latestVersionId: Ye }) => {
|
|
424
|
+
h(O || ""), a(_ || ""), f(U || null), E(Z || null), v(ie), r(Ye), g((He) => ({
|
|
425
|
+
...He,
|
|
426
426
|
...ie != null ? { version: ie + 1 } : {}
|
|
427
|
-
})),
|
|
427
|
+
})), T(!0);
|
|
428
428
|
},
|
|
429
429
|
[]
|
|
430
430
|
), q = ee(() => {
|
|
431
|
-
m.forEach((
|
|
432
|
-
|
|
433
|
-
}), A([]), g(ne),
|
|
434
|
-
}, [m]), [be] =
|
|
435
|
-
async (
|
|
431
|
+
m.forEach((O) => {
|
|
432
|
+
O.preview && URL.revokeObjectURL(O.preview);
|
|
433
|
+
}), A([]), g(ne), H(null), D(null), N(""), I(!1), T(!1), h(""), a(""), f(null), E(null), p.current = !1, v(void 0), r(void 0);
|
|
434
|
+
}, [m]), [be] = Tt(), [pe] = Dt(), X = ee(
|
|
435
|
+
async (O) => {
|
|
436
436
|
try {
|
|
437
437
|
if (w) {
|
|
438
|
-
const
|
|
438
|
+
const _ = await jt(pe, e, {
|
|
439
439
|
productId: w,
|
|
440
|
-
version:
|
|
441
|
-
taskId:
|
|
440
|
+
version: O.version,
|
|
441
|
+
taskId: G || void 0
|
|
442
442
|
});
|
|
443
|
-
return i(w,
|
|
443
|
+
return i(w, _.id), he.success("Created new version"), {
|
|
444
444
|
productId: w,
|
|
445
|
-
versionId:
|
|
445
|
+
versionId: _.id
|
|
446
446
|
};
|
|
447
447
|
} else {
|
|
448
|
-
const { product:
|
|
448
|
+
const { product: _, version: U } = await Xt(
|
|
449
449
|
be,
|
|
450
450
|
pe,
|
|
451
451
|
e,
|
|
452
452
|
{
|
|
453
453
|
folderId: o,
|
|
454
|
-
name:
|
|
455
|
-
productType:
|
|
456
|
-
productBaseType:
|
|
454
|
+
name: O.name,
|
|
455
|
+
productType: O.productType || "review",
|
|
456
|
+
productBaseType: O.productType || "review"
|
|
457
457
|
},
|
|
458
458
|
{
|
|
459
|
-
version:
|
|
460
|
-
taskId:
|
|
459
|
+
version: O.version,
|
|
460
|
+
taskId: G || void 0
|
|
461
461
|
}
|
|
462
462
|
);
|
|
463
|
-
return i(
|
|
464
|
-
productId:
|
|
463
|
+
return i(_.id, U.id), he.success("Created new version"), {
|
|
464
|
+
productId: _.id,
|
|
465
465
|
versionId: U.id
|
|
466
466
|
};
|
|
467
467
|
}
|
|
468
|
-
} catch (
|
|
469
|
-
throw console.error("Error uploading version:",
|
|
468
|
+
} catch (_) {
|
|
469
|
+
throw console.error("Error uploading version:", _), _.message || _;
|
|
470
470
|
}
|
|
471
471
|
},
|
|
472
|
-
[q, w, o,
|
|
472
|
+
[q, w, o, G, e]
|
|
473
473
|
), fe = ee(
|
|
474
|
-
(
|
|
474
|
+
(O) => {
|
|
475
475
|
if (w) return;
|
|
476
|
-
const
|
|
477
|
-
if (
|
|
478
|
-
const U = Jt(
|
|
476
|
+
const _ = O[0];
|
|
477
|
+
if (_) {
|
|
478
|
+
const U = Jt(_.name), Z = Kt(U);
|
|
479
479
|
Z && Z !== R.version && g((ie) => ({
|
|
480
480
|
...ie,
|
|
481
481
|
version: Z
|
|
@@ -483,73 +483,73 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
483
483
|
}
|
|
484
484
|
},
|
|
485
485
|
[w, R.version]
|
|
486
|
-
), Q = x?.version ?? b ?? F?.latestVersion?.version, J = ee((
|
|
486
|
+
), Q = x?.version ?? b ?? F?.latestVersion?.version, J = ee((O, _) => {
|
|
487
487
|
g((U) => ({
|
|
488
488
|
...U,
|
|
489
|
-
[
|
|
490
|
-
})),
|
|
489
|
+
[O]: _
|
|
490
|
+
})), N("");
|
|
491
491
|
}, []), Ee = ee(
|
|
492
|
-
async (
|
|
492
|
+
async (O) => {
|
|
493
493
|
try {
|
|
494
|
-
I(!0),
|
|
495
|
-
const
|
|
496
|
-
if (!
|
|
497
|
-
throw
|
|
498
|
-
const U = await X(
|
|
499
|
-
o && (
|
|
500
|
-
} catch (
|
|
501
|
-
|
|
494
|
+
I(!0), N("");
|
|
495
|
+
const _ = Qt(O, Q, !w);
|
|
496
|
+
if (!_.isValid)
|
|
497
|
+
throw _.error;
|
|
498
|
+
const U = await X(O);
|
|
499
|
+
o && (c.current = { folderId: o, productName: O.name }), U?.productId && H(U.productId), U?.versionId && D(U.versionId), m.length < 1 && (I(!1), q());
|
|
500
|
+
} catch (_) {
|
|
501
|
+
N(_), I(!1);
|
|
502
502
|
}
|
|
503
503
|
},
|
|
504
504
|
[X, m.length, q, Q, w]
|
|
505
505
|
);
|
|
506
|
-
|
|
506
|
+
$(() => {
|
|
507
507
|
if (!(!y || b != null))
|
|
508
|
-
return g(x ? (
|
|
508
|
+
return g(x ? (O) => ({ ...O, version: x.version + 1 }) : ne), () => {
|
|
509
509
|
g(ne);
|
|
510
510
|
};
|
|
511
|
-
}, [y, x, b]),
|
|
512
|
-
if (!y ||
|
|
513
|
-
const
|
|
514
|
-
if (
|
|
515
|
-
g((Z) => ({ ...Z, name:
|
|
511
|
+
}, [y, x, b]), $(() => {
|
|
512
|
+
if (!y || s || d.length === 0 || R.name !== ne.name) return;
|
|
513
|
+
const O = c.current;
|
|
514
|
+
if (O && O.folderId === o && d.some((Z) => Z.name === O.productName)) {
|
|
515
|
+
g((Z) => ({ ...Z, name: O.productName }));
|
|
516
516
|
return;
|
|
517
517
|
}
|
|
518
|
-
const
|
|
519
|
-
|
|
520
|
-
}, [y,
|
|
521
|
-
if (!(!y ||
|
|
518
|
+
const _ = d[d.length - 1];
|
|
519
|
+
_ && g((U) => ({ ...U, name: _.name }));
|
|
520
|
+
}, [y, s, d]), $(() => {
|
|
521
|
+
if (!(!y || s))
|
|
522
522
|
if (F) {
|
|
523
|
-
g((
|
|
524
|
-
...
|
|
523
|
+
g((_) => ({
|
|
524
|
+
..._,
|
|
525
525
|
productType: F.productType,
|
|
526
526
|
...F.latestVersion && {
|
|
527
527
|
version: F.latestVersion.version + 1
|
|
528
528
|
}
|
|
529
529
|
}));
|
|
530
|
-
const
|
|
531
|
-
|
|
532
|
-
id:
|
|
533
|
-
name:
|
|
534
|
-
label:
|
|
535
|
-
taskType:
|
|
536
|
-
}), p.current = !0) : !
|
|
530
|
+
const O = F.latestVersion?.task;
|
|
531
|
+
O && (l === null || p.current) ? (f(O.id), E({
|
|
532
|
+
id: O.id,
|
|
533
|
+
name: O.name,
|
|
534
|
+
label: O.label,
|
|
535
|
+
taskType: O.taskType
|
|
536
|
+
}), p.current = !0) : !O && p.current && (f(null), E(null), p.current = !1);
|
|
537
537
|
} else
|
|
538
|
-
g((
|
|
539
|
-
}, [y,
|
|
540
|
-
const
|
|
541
|
-
f(
|
|
542
|
-
}, []),
|
|
538
|
+
g((O) => ({ ...O, version: ne.version })), (l === null || p.current) && (f(null), E(null), p.current = !1);
|
|
539
|
+
}, [y, s, F]);
|
|
540
|
+
const ke = ee((O) => {
|
|
541
|
+
f(O), p.current = !1;
|
|
542
|
+
}, []), We = me(
|
|
543
543
|
() => ({
|
|
544
|
-
productId:
|
|
544
|
+
productId: s,
|
|
545
545
|
setProductId: h,
|
|
546
546
|
folderId: o,
|
|
547
|
-
taskId:
|
|
547
|
+
taskId: G,
|
|
548
548
|
linkedTask: n,
|
|
549
549
|
isLoadingTask: j,
|
|
550
|
-
setTaskId:
|
|
550
|
+
setTaskId: ke,
|
|
551
551
|
setLinkedTask: E,
|
|
552
|
-
setFolderId:
|
|
552
|
+
setFolderId: a,
|
|
553
553
|
isOpen: y,
|
|
554
554
|
projectName: e,
|
|
555
555
|
latestVersion: Q,
|
|
@@ -561,25 +561,25 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
561
561
|
extractAndSetVersionFromFiles: fe,
|
|
562
562
|
form: R,
|
|
563
563
|
setForm: g,
|
|
564
|
-
isSubmitting:
|
|
565
|
-
error:
|
|
564
|
+
isSubmitting: V,
|
|
565
|
+
error: L,
|
|
566
566
|
createdProductId: M,
|
|
567
|
-
createdVersionId:
|
|
567
|
+
createdVersionId: z,
|
|
568
568
|
handleFormChange: J,
|
|
569
569
|
handleFormSubmit: Ee,
|
|
570
570
|
folderProducts: d,
|
|
571
|
-
isFolderProductsLoading:
|
|
571
|
+
isFolderProductsLoading: C,
|
|
572
572
|
matchedProduct: F,
|
|
573
|
-
dispatch:
|
|
573
|
+
dispatch: u
|
|
574
574
|
}),
|
|
575
575
|
[
|
|
576
576
|
o,
|
|
577
|
-
s,
|
|
578
577
|
a,
|
|
579
|
-
|
|
578
|
+
s,
|
|
579
|
+
G,
|
|
580
580
|
n,
|
|
581
581
|
j,
|
|
582
|
-
|
|
582
|
+
ke,
|
|
583
583
|
E,
|
|
584
584
|
h,
|
|
585
585
|
y,
|
|
@@ -592,74 +592,74 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
592
592
|
X,
|
|
593
593
|
fe,
|
|
594
594
|
R,
|
|
595
|
-
|
|
596
|
-
|
|
595
|
+
V,
|
|
596
|
+
L,
|
|
597
597
|
M,
|
|
598
|
-
|
|
598
|
+
z,
|
|
599
599
|
J,
|
|
600
600
|
Ee,
|
|
601
601
|
d,
|
|
602
|
-
|
|
602
|
+
C,
|
|
603
603
|
F,
|
|
604
|
-
|
|
604
|
+
u
|
|
605
605
|
]
|
|
606
606
|
);
|
|
607
|
-
return /* @__PURE__ */
|
|
608
|
-
},
|
|
609
|
-
const [e, i] =
|
|
607
|
+
return /* @__PURE__ */ k(qt.Provider, { value: We, children: t });
|
|
608
|
+
}, Za = ({ children: t }) => {
|
|
609
|
+
const [e, i] = P(!1), { siteInfo: u, user: o, cloudInfo: a } = Be(), { data: s, isLoading: h } = Vt(
|
|
610
610
|
{},
|
|
611
611
|
{
|
|
612
|
-
skip: !o?.name || !
|
|
612
|
+
skip: !o?.name || !a?.connected
|
|
613
613
|
}
|
|
614
614
|
), l = () => {
|
|
615
|
-
e || (
|
|
615
|
+
e || (Pt(() => {
|
|
616
616
|
if (document.getElementById("featurebase-sdk")) return;
|
|
617
|
-
const
|
|
618
|
-
|
|
617
|
+
const c = document.createElement("script");
|
|
618
|
+
c.src = "https://do.featurebase.app/js/sdk.js", c.id = "featurebase-sdk", c.async = !0, document.body.appendChild(c);
|
|
619
619
|
}), i(!0));
|
|
620
620
|
}, f = () => {
|
|
621
|
-
const
|
|
622
|
-
typeof
|
|
623
|
-
(
|
|
621
|
+
const c = window;
|
|
622
|
+
typeof c.Featurebase != "function" && (c.Featurebase = function() {
|
|
623
|
+
(c.Featurebase.q = c.Featurebase.q || []).push(arguments);
|
|
624
624
|
});
|
|
625
|
-
}, n =
|
|
626
|
-
if (!o?.name || !
|
|
627
|
-
const
|
|
628
|
-
...
|
|
625
|
+
}, n = u?.version?.split("+")[0] || "unknown", E = u?.version?.split("+")[1] || "unknown", y = () => {
|
|
626
|
+
if (!o?.name || !s?.available) return;
|
|
627
|
+
const c = {
|
|
628
|
+
...s.data,
|
|
629
629
|
customFields: {
|
|
630
630
|
origin: window.location.origin,
|
|
631
631
|
serverVersion: n,
|
|
632
632
|
frontendVersion: E,
|
|
633
|
-
instanceId:
|
|
633
|
+
instanceId: a?.instanceId
|
|
634
634
|
}
|
|
635
635
|
};
|
|
636
|
-
console.log(
|
|
637
|
-
|
|
636
|
+
console.log(c), window.Featurebase("identify", c, (C) => {
|
|
637
|
+
C ? console.error(C) : console.log("Featurebase identify completed");
|
|
638
638
|
});
|
|
639
|
-
}, [
|
|
640
|
-
const
|
|
641
|
-
if (typeof
|
|
642
|
-
if (console.log("Initializing Featurebase messenger widget"), !
|
|
639
|
+
}, [T, m] = P(!1), [A, R] = P(0), g = () => {
|
|
640
|
+
const c = window;
|
|
641
|
+
if (typeof c.Featurebase == "function") {
|
|
642
|
+
if (console.log("Initializing Featurebase messenger widget"), !s?.available)
|
|
643
643
|
return console.warn("messenger verification not available, skipping messenger init");
|
|
644
|
-
|
|
644
|
+
c.Featurebase(
|
|
645
645
|
"boot",
|
|
646
646
|
{
|
|
647
647
|
theme: "dark",
|
|
648
|
-
...
|
|
648
|
+
...s?.data
|
|
649
649
|
},
|
|
650
650
|
(d) => {
|
|
651
|
-
d ? console.error(d) : (console.log("Featurebase messenger completed"), m(!0),
|
|
652
|
-
R(
|
|
651
|
+
d ? console.error(d) : (console.log("Featurebase messenger completed"), m(!0), c.Featurebase("onUnreadCountChange", function(C) {
|
|
652
|
+
R(C);
|
|
653
653
|
}));
|
|
654
654
|
}
|
|
655
655
|
);
|
|
656
656
|
}
|
|
657
|
-
},
|
|
658
|
-
const
|
|
657
|
+
}, V = () => {
|
|
658
|
+
const c = [];
|
|
659
659
|
if (o?.data?.isAdmin) {
|
|
660
|
-
const
|
|
661
|
-
|
|
662
|
-
} else
|
|
660
|
+
const C = ["Server", "Addon", "Pipeline"];
|
|
661
|
+
c.push(...C);
|
|
662
|
+
} else u?.disableChangelog || c.push("Highlights");
|
|
663
663
|
const d = window;
|
|
664
664
|
return typeof d.Featurebase == "function" && d.Featurebase("init_changelog_widget", {
|
|
665
665
|
organization: "ayon",
|
|
@@ -671,12 +671,12 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
671
671
|
usersName: o?.attrib?.fullName,
|
|
672
672
|
autoOpenForNewUpdates: !0
|
|
673
673
|
},
|
|
674
|
-
category:
|
|
674
|
+
category: c,
|
|
675
675
|
theme: "dark"
|
|
676
676
|
}), !1;
|
|
677
677
|
}, I = () => {
|
|
678
|
-
const
|
|
679
|
-
return typeof
|
|
678
|
+
const c = window;
|
|
679
|
+
return typeof c.Featurebase == "function" && c.Featurebase(
|
|
680
680
|
"initialize_feedback_widget",
|
|
681
681
|
{
|
|
682
682
|
organization: "ayon",
|
|
@@ -687,9 +687,9 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
687
687
|
d && console.error("Error initializing feedback widget:", d);
|
|
688
688
|
}
|
|
689
689
|
), !1;
|
|
690
|
-
},
|
|
691
|
-
const
|
|
692
|
-
return typeof
|
|
690
|
+
}, L = () => {
|
|
691
|
+
const c = window;
|
|
692
|
+
return typeof c.Featurebase == "function" && c.Featurebase(
|
|
693
693
|
"initialize_portal_widget",
|
|
694
694
|
{
|
|
695
695
|
organization: "ayon",
|
|
@@ -698,16 +698,16 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
698
698
|
},
|
|
699
699
|
(d) => d ? (console.error("Error initializing portal widget:", d), !1) : !0
|
|
700
700
|
), !1;
|
|
701
|
-
},
|
|
702
|
-
const
|
|
703
|
-
return typeof
|
|
701
|
+
}, N = () => {
|
|
702
|
+
const c = window;
|
|
703
|
+
return typeof c.Featurebase == "function" && c.Featurebase(
|
|
704
704
|
"initialize_survey_widget",
|
|
705
705
|
{
|
|
706
706
|
organization: "ayon",
|
|
707
707
|
placement: "bottom-right",
|
|
708
708
|
theme: "dark",
|
|
709
709
|
email: o?.attrib?.email,
|
|
710
|
-
featurebaseJwt:
|
|
710
|
+
featurebaseJwt: s?.data?.featurebaseJwt,
|
|
711
711
|
locale: "en"
|
|
712
712
|
},
|
|
713
713
|
(d) => {
|
|
@@ -715,91 +715,91 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
715
715
|
}
|
|
716
716
|
), !1;
|
|
717
717
|
};
|
|
718
|
-
|
|
719
|
-
o?.name &&
|
|
720
|
-
}, [o?.name, e,
|
|
721
|
-
const [M,
|
|
722
|
-
|
|
723
|
-
!o?.name || !
|
|
718
|
+
$(() => {
|
|
719
|
+
o?.name && u && (u.disableFeedback || e || (l(), f(), V(), I(), L()));
|
|
720
|
+
}, [o?.name, e, u]);
|
|
721
|
+
const [M, H] = P(!1);
|
|
722
|
+
$(() => {
|
|
723
|
+
!o?.name || !a || !s || !e || M || (y(), N(), H(!0));
|
|
724
724
|
}, [
|
|
725
725
|
o?.name,
|
|
726
|
-
|
|
727
|
-
|
|
726
|
+
a?.instanceId,
|
|
727
|
+
s?.available,
|
|
728
728
|
e,
|
|
729
729
|
window.location.pathname,
|
|
730
730
|
M
|
|
731
|
-
]),
|
|
731
|
+
]), $(() => {
|
|
732
732
|
h || !e || g();
|
|
733
|
-
}, [
|
|
734
|
-
const
|
|
733
|
+
}, [s, h, e]);
|
|
734
|
+
const z = () => {
|
|
735
735
|
window.postMessage({
|
|
736
736
|
target: "FeaturebaseWidget",
|
|
737
737
|
data: {
|
|
738
738
|
action: "openFeedbackWidget"
|
|
739
739
|
}
|
|
740
740
|
});
|
|
741
|
-
},
|
|
741
|
+
}, D = (c = "MainView", d) => {
|
|
742
742
|
window.postMessage({
|
|
743
743
|
target: "FeaturebaseWidget",
|
|
744
744
|
data: {
|
|
745
745
|
action: "changePage",
|
|
746
|
-
payload:
|
|
746
|
+
payload: c,
|
|
747
747
|
openWidget: !0,
|
|
748
748
|
...d && { articleId: d }
|
|
749
749
|
}
|
|
750
750
|
});
|
|
751
|
-
}, [b, v] =
|
|
752
|
-
|
|
753
|
-
!e || !
|
|
754
|
-
}, [e,
|
|
755
|
-
if (!e || !
|
|
756
|
-
const
|
|
757
|
-
typeof
|
|
751
|
+
}, [b, v] = P(!1), S = document.getElementById("fb-messenger-root"), r = (c) => S instanceof HTMLElement && (S.style.display = c ? "block" : "none");
|
|
752
|
+
$(() => {
|
|
753
|
+
!e || !T || r(b);
|
|
754
|
+
}, [e, T, b]), $(() => {
|
|
755
|
+
if (!e || !T) return;
|
|
756
|
+
const c = window;
|
|
757
|
+
typeof c.Featurebase == "function" && c.Featurebase("onHide", function() {
|
|
758
758
|
v(!1);
|
|
759
759
|
});
|
|
760
|
-
}, [e,
|
|
761
|
-
const p = (
|
|
762
|
-
const
|
|
763
|
-
if (typeof
|
|
760
|
+
}, [e, T]);
|
|
761
|
+
const p = (c = "Home", d) => {
|
|
762
|
+
const C = window;
|
|
763
|
+
if (typeof C.Featurebase != "function") {
|
|
764
764
|
window.alert("Featurebase SDK is not loaded yet. Please try again later."), console.warn("Featurebase SDK is not loaded yet.");
|
|
765
765
|
return;
|
|
766
766
|
}
|
|
767
767
|
if (b) {
|
|
768
|
-
|
|
768
|
+
C.Featurebase("hide"), v(!1);
|
|
769
769
|
return;
|
|
770
770
|
}
|
|
771
|
-
switch (v(!0),
|
|
771
|
+
switch (v(!0), c) {
|
|
772
772
|
case "Home":
|
|
773
|
-
|
|
773
|
+
C.Featurebase("show");
|
|
774
774
|
break;
|
|
775
775
|
case "Messages":
|
|
776
|
-
|
|
776
|
+
C.Featurebase("show", "messages");
|
|
777
777
|
break;
|
|
778
778
|
case "Changelog":
|
|
779
|
-
|
|
779
|
+
C.Featurebase("show", "changelog");
|
|
780
780
|
break;
|
|
781
781
|
case "Help":
|
|
782
|
-
|
|
782
|
+
C.Featurebase("show", "help");
|
|
783
783
|
break;
|
|
784
784
|
case "ShowArticle":
|
|
785
|
-
d ?
|
|
785
|
+
d ? C.Featurebase("showArticle", d) : C.Featurebase("show", "help");
|
|
786
786
|
break;
|
|
787
787
|
case "NewMessage":
|
|
788
|
-
|
|
788
|
+
C.Featurebase("showNewMessage", d);
|
|
789
789
|
break;
|
|
790
790
|
default:
|
|
791
|
-
|
|
791
|
+
C.Featurebase("show");
|
|
792
792
|
break;
|
|
793
793
|
}
|
|
794
794
|
};
|
|
795
|
-
return /* @__PURE__ */
|
|
795
|
+
return /* @__PURE__ */ k(
|
|
796
796
|
xt.Provider,
|
|
797
797
|
{
|
|
798
798
|
value: {
|
|
799
799
|
openSupport: p,
|
|
800
|
-
openFeedback:
|
|
801
|
-
openPortal:
|
|
802
|
-
messengerLoaded:
|
|
800
|
+
openFeedback: z,
|
|
801
|
+
openPortal: D,
|
|
802
|
+
messengerLoaded: T,
|
|
803
803
|
unreadCount: A,
|
|
804
804
|
messengerVisibility: b,
|
|
805
805
|
setMessengerVisibility: v,
|
|
@@ -808,17 +808,17 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
808
808
|
children: t
|
|
809
809
|
}
|
|
810
810
|
);
|
|
811
|
-
},
|
|
811
|
+
}, es = ({
|
|
812
812
|
projectName: t,
|
|
813
813
|
list: e,
|
|
814
814
|
isLoading: i,
|
|
815
|
-
attributes:
|
|
815
|
+
attributes: u = []
|
|
816
816
|
}) => {
|
|
817
|
-
const [o,
|
|
817
|
+
const [o, a] = P({
|
|
818
818
|
label: "",
|
|
819
819
|
tags: [],
|
|
820
820
|
active: !1
|
|
821
|
-
}),
|
|
821
|
+
}), s = (e?.accessLevel || 0) >= 30, { tags: h } = mt(), { data: l = [] } = Rt(), f = me(
|
|
822
822
|
() => l.filter((m) => m.scope?.includes("list")).map((m) => ({
|
|
823
823
|
name: m.name,
|
|
824
824
|
data: m.data
|
|
@@ -839,25 +839,25 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
839
839
|
},
|
|
840
840
|
...f,
|
|
841
841
|
{ name: "active", data: { type: "boolean", title: "Active" } },
|
|
842
|
-
...
|
|
842
|
+
...u
|
|
843
843
|
],
|
|
844
|
-
[h, f,
|
|
844
|
+
[h, f, u]
|
|
845
845
|
);
|
|
846
|
-
|
|
846
|
+
$(() => {
|
|
847
847
|
if (e) {
|
|
848
|
-
const m = e.attrib || {}, R = [...f, ...
|
|
849
|
-
const I = m[
|
|
850
|
-
return g[
|
|
848
|
+
const m = e.attrib || {}, R = [...f, ...u].reduce((g, { name: V }) => {
|
|
849
|
+
const I = m[V];
|
|
850
|
+
return g[V] = I || "", g;
|
|
851
851
|
}, {});
|
|
852
|
-
|
|
852
|
+
a({
|
|
853
853
|
label: e?.label || "",
|
|
854
854
|
tags: e?.tags || [],
|
|
855
855
|
active: e?.active ?? !1,
|
|
856
856
|
...R
|
|
857
857
|
});
|
|
858
858
|
}
|
|
859
|
-
}, [e, JSON.stringify(
|
|
860
|
-
const [E] = It(), y = (m) =>
|
|
859
|
+
}, [e, JSON.stringify(u), JSON.stringify(f)]);
|
|
860
|
+
const [E] = It(), y = (m) => u.some((A) => A.name === m) || f.some((A) => A.name === m), T = ee(
|
|
861
861
|
async (m, A) => {
|
|
862
862
|
if (!e?.id) return console.warn("No list ID provided");
|
|
863
863
|
let R;
|
|
@@ -873,10 +873,10 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
873
873
|
...g,
|
|
874
874
|
[m]: A
|
|
875
875
|
}
|
|
876
|
-
},
|
|
876
|
+
}, a((V) => ({ ...V, [m]: A }));
|
|
877
877
|
} else {
|
|
878
878
|
const g = { [m]: A };
|
|
879
|
-
R = g,
|
|
879
|
+
R = g, a((V) => ({ ...V, ...g }));
|
|
880
880
|
}
|
|
881
881
|
try {
|
|
882
882
|
await E({
|
|
@@ -888,26 +888,26 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
888
888
|
console.error(g), he.error("Failed to update list attribute: ", g.attrib.detail);
|
|
889
889
|
}
|
|
890
890
|
},
|
|
891
|
-
[e?.id, e?.attrib, t, E, f,
|
|
891
|
+
[e?.id, e?.attrib, t, E, f, u]
|
|
892
892
|
);
|
|
893
|
-
return /* @__PURE__ */
|
|
893
|
+
return /* @__PURE__ */ k(
|
|
894
894
|
wt,
|
|
895
895
|
{
|
|
896
|
-
enableEditing:
|
|
896
|
+
enableEditing: s,
|
|
897
897
|
projectName: t,
|
|
898
898
|
fields: n,
|
|
899
899
|
form: o,
|
|
900
900
|
isLoading: i,
|
|
901
|
-
onChange:
|
|
901
|
+
onChange: T,
|
|
902
902
|
title: "Attributes"
|
|
903
903
|
}
|
|
904
904
|
);
|
|
905
|
-
},
|
|
905
|
+
}, ts = ({ list: t, isLoading: e }) => {
|
|
906
906
|
const i = Object.fromEntries(
|
|
907
907
|
Object.entries(t?.data || {}).filter(
|
|
908
|
-
([
|
|
908
|
+
([a, s]) => !["category", "count"].includes(a) && s !== null && typeof s != "object"
|
|
909
909
|
)
|
|
910
|
-
),
|
|
910
|
+
), u = {
|
|
911
911
|
Id: t?.id,
|
|
912
912
|
"Entity type": t?.entityType,
|
|
913
913
|
"List type": t?.entityListType,
|
|
@@ -918,143 +918,143 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
918
918
|
"Updated at": t?.updatedAt && re(new Date(t?.updatedAt), "PPpp"),
|
|
919
919
|
"Last updated by": t?.updatedBy,
|
|
920
920
|
...i
|
|
921
|
-
}, o = Object.keys(
|
|
922
|
-
name:
|
|
921
|
+
}, o = Object.keys(u).map((a) => ({
|
|
922
|
+
name: a,
|
|
923
923
|
data: { type: "string" },
|
|
924
924
|
hidden: !1
|
|
925
925
|
}));
|
|
926
|
-
return /* @__PURE__ */
|
|
927
|
-
},
|
|
926
|
+
return /* @__PURE__ */ k(yt, { form: u, fields: o, isLoading: !!e });
|
|
927
|
+
}, as = ({
|
|
928
928
|
label: t,
|
|
929
929
|
description: e,
|
|
930
930
|
features: i,
|
|
931
|
-
isCloseable:
|
|
931
|
+
isCloseable: u = !0,
|
|
932
932
|
addon: o
|
|
933
933
|
}) => {
|
|
934
|
-
const [
|
|
934
|
+
const [a, s] = P(!1), { setPowerpackDialog: h, selectedPowerPack: l, powerpackDialog: f, addonDialog: n } = ht(), E = !!o || !!n, y = t ?? f?.label ?? n?.label, T = e ?? f?.description ?? (n ? n.features[n.selectedFeature ?? ""]?.description ?? Object.values(n.features)[0]?.description : void 0), m = o?.icon ?? (n ? n.icon : "bolt");
|
|
935
935
|
if (!f && !n && (!t || !e)) return null;
|
|
936
936
|
const R = (() => {
|
|
937
937
|
if (i)
|
|
938
938
|
return Object.entries(i);
|
|
939
939
|
if (n) {
|
|
940
|
-
const
|
|
940
|
+
const V = n.featureOrder.filter((I) => I in n.features).map(
|
|
941
941
|
(I) => [I, n.features[I]]
|
|
942
942
|
);
|
|
943
943
|
if (n.selectedFeature) {
|
|
944
|
-
const I =
|
|
944
|
+
const I = V.findIndex(([L]) => L === n.selectedFeature);
|
|
945
945
|
if (I > 0) {
|
|
946
|
-
const [
|
|
947
|
-
|
|
946
|
+
const [L] = V.splice(I, 1);
|
|
947
|
+
V.unshift(L);
|
|
948
948
|
}
|
|
949
949
|
}
|
|
950
|
-
return
|
|
950
|
+
return V;
|
|
951
951
|
}
|
|
952
|
-
return Object.entries(bt).sort(([
|
|
953
|
-
if (
|
|
952
|
+
return Object.entries(bt).sort(([V], [I]) => {
|
|
953
|
+
if (V === l) return -1;
|
|
954
954
|
if (I === l) return 1;
|
|
955
|
-
const
|
|
956
|
-
return
|
|
955
|
+
const L = Ve.indexOf(V), N = Ve.indexOf(I);
|
|
956
|
+
return L > -1 && N > -1 ? L - N : L > -1 ? -1 : N > -1 ? 1 : 0;
|
|
957
957
|
});
|
|
958
958
|
})();
|
|
959
|
-
return /* @__PURE__ */
|
|
959
|
+
return /* @__PURE__ */ Y(
|
|
960
960
|
et,
|
|
961
961
|
{
|
|
962
962
|
isOpen: !0,
|
|
963
963
|
onClose: () => {
|
|
964
|
-
|
|
964
|
+
u && (h(null), s(!1));
|
|
965
965
|
},
|
|
966
966
|
size: "lg",
|
|
967
|
-
hideCancelButton: !
|
|
968
|
-
hideBackdrop: !
|
|
967
|
+
hideCancelButton: !u,
|
|
968
|
+
hideBackdrop: !u,
|
|
969
969
|
children: [
|
|
970
|
-
/* @__PURE__ */
|
|
971
|
-
/* @__PURE__ */
|
|
972
|
-
/* @__PURE__ */
|
|
970
|
+
/* @__PURE__ */ Y(tt, { children: [
|
|
971
|
+
/* @__PURE__ */ Y("h1", { children: [
|
|
972
|
+
/* @__PURE__ */ k(le, { icon: m }),
|
|
973
973
|
y
|
|
974
974
|
] }),
|
|
975
|
-
/* @__PURE__ */
|
|
975
|
+
/* @__PURE__ */ k("h2", { children: T })
|
|
976
976
|
] }),
|
|
977
|
-
/* @__PURE__ */
|
|
978
|
-
E ? /* @__PURE__ */
|
|
977
|
+
/* @__PURE__ */ Y(at, { children: [
|
|
978
|
+
E ? /* @__PURE__ */ Y("h3", { children: [
|
|
979
979
|
"Unlock all ",
|
|
980
|
-
/* @__PURE__ */
|
|
980
|
+
/* @__PURE__ */ k("span", { className: "green", children: "Premium Addons" }),
|
|
981
981
|
" with an AYON Studio subscription."
|
|
982
|
-
] }) : /* @__PURE__ */
|
|
982
|
+
] }) : /* @__PURE__ */ Y("h3", { children: [
|
|
983
983
|
"Unlock all ",
|
|
984
|
-
/* @__PURE__ */
|
|
984
|
+
/* @__PURE__ */ k(le, { icon: "bolt" }),
|
|
985
985
|
" ",
|
|
986
|
-
/* @__PURE__ */
|
|
986
|
+
/* @__PURE__ */ k("span", { className: "green", children: "Power Features" }),
|
|
987
987
|
" with an AYON subscription."
|
|
988
988
|
] }),
|
|
989
|
-
/* @__PURE__ */
|
|
990
|
-
/* @__PURE__ */
|
|
991
|
-
/* @__PURE__ */
|
|
992
|
-
] },
|
|
993
|
-
!
|
|
989
|
+
/* @__PURE__ */ k("ul", { children: R.slice(0, a ? void 0 : 5).map(([V, I]) => /* @__PURE__ */ Y("li", { children: [
|
|
990
|
+
/* @__PURE__ */ k(le, { icon: I.icon ?? "check" }),
|
|
991
|
+
/* @__PURE__ */ k("span", { children: I.bullet })
|
|
992
|
+
] }, V)) }),
|
|
993
|
+
!a && R.length > 5 && /* @__PURE__ */ k(st, { onClick: () => s(!0), children: "Show all" })
|
|
994
994
|
] }),
|
|
995
|
-
/* @__PURE__ */
|
|
995
|
+
/* @__PURE__ */ k(ot, { addon: o?.name, children: /* @__PURE__ */ k(nt, {}) })
|
|
996
996
|
]
|
|
997
997
|
}
|
|
998
998
|
);
|
|
999
|
-
},
|
|
999
|
+
}, Pe = ({
|
|
1000
1000
|
Component: t,
|
|
1001
1001
|
projectName: e,
|
|
1002
1002
|
state: i,
|
|
1003
|
-
dispatch:
|
|
1003
|
+
dispatch: u,
|
|
1004
1004
|
useSelector: o,
|
|
1005
|
-
onOpenImage:
|
|
1006
|
-
onGoToFrame:
|
|
1005
|
+
onOpenImage: a,
|
|
1006
|
+
onGoToFrame: s,
|
|
1007
1007
|
onOpenViewer: h,
|
|
1008
1008
|
onUpdateEntity: l,
|
|
1009
1009
|
...f
|
|
1010
1010
|
}) => {
|
|
1011
|
-
const n = gt(), { onCreateView: E, getLatestSettings: y, markCacheDirty:
|
|
1012
|
-
return /* @__PURE__ */
|
|
1011
|
+
const n = gt(), { onCreateView: E, getLatestSettings: y, markCacheDirty: T } = Nt();
|
|
1012
|
+
return /* @__PURE__ */ k(
|
|
1013
1013
|
t,
|
|
1014
1014
|
{
|
|
1015
|
-
router: { useParams:
|
|
1015
|
+
router: { useParams: Gt, useNavigate: Ut, useLocation: Bt, useSearchParams: Mt },
|
|
1016
1016
|
projectName: e,
|
|
1017
1017
|
views: {
|
|
1018
1018
|
...n,
|
|
1019
1019
|
settings: n.viewSettings,
|
|
1020
|
-
updateViewSettings: (...m) =>
|
|
1020
|
+
updateViewSettings: (...m) => Lt(...m, n, E, y, T)
|
|
1021
1021
|
},
|
|
1022
1022
|
context: {},
|
|
1023
1023
|
state: i,
|
|
1024
|
-
dispatch:
|
|
1024
|
+
dispatch: u,
|
|
1025
1025
|
useSelector: o,
|
|
1026
|
-
onOpenImage:
|
|
1027
|
-
onGoToFrame:
|
|
1026
|
+
onOpenImage: a,
|
|
1027
|
+
onGoToFrame: s,
|
|
1028
1028
|
onOpenViewer: h,
|
|
1029
1029
|
onUpdateEntity: l,
|
|
1030
1030
|
toast: he,
|
|
1031
1031
|
...f
|
|
1032
1032
|
}
|
|
1033
1033
|
);
|
|
1034
|
-
},
|
|
1035
|
-
const i =
|
|
1036
|
-
return /* @__PURE__ */
|
|
1037
|
-
|
|
1034
|
+
}, ea = ({ children: t, fields: e }) => {
|
|
1035
|
+
const i = Wt.filter((u) => e.includes(u.value));
|
|
1036
|
+
return /* @__PURE__ */ k("main", { style: { width: "100%", height: "100%" }, children: /* @__PURE__ */ Y(
|
|
1037
|
+
zt,
|
|
1038
1038
|
{
|
|
1039
1039
|
layout: "horizontal",
|
|
1040
1040
|
style: { width: "100%", height: "100%" },
|
|
1041
|
-
stateKey:
|
|
1041
|
+
stateKey: Yt,
|
|
1042
1042
|
stateStorage: "local",
|
|
1043
1043
|
children: [
|
|
1044
|
-
/* @__PURE__ */
|
|
1045
|
-
/* @__PURE__ */
|
|
1044
|
+
/* @__PURE__ */ k(Ie, { ...Ht, children: /* @__PURE__ */ k(ut, { wrap: !0, children: /* @__PURE__ */ k($t, { sliceFields: i, pinnedSliceType: "hierarchy" }) }) }),
|
|
1045
|
+
/* @__PURE__ */ k(Ie, { size: 80, children: t })
|
|
1046
1046
|
]
|
|
1047
1047
|
}
|
|
1048
1048
|
) });
|
|
1049
|
-
},
|
|
1049
|
+
}, ss = ({
|
|
1050
1050
|
Component: t,
|
|
1051
1051
|
projectName: e,
|
|
1052
1052
|
slicer: i,
|
|
1053
|
-
state:
|
|
1053
|
+
state: u = {},
|
|
1054
1054
|
addonProps: o,
|
|
1055
|
-
...
|
|
1055
|
+
...a
|
|
1056
1056
|
}) => {
|
|
1057
|
-
let
|
|
1057
|
+
let s = /* @__PURE__ */ k(Pe, { Component: t, projectName: e, ...a });
|
|
1058
1058
|
if (i && e) {
|
|
1059
1059
|
let h = null;
|
|
1060
1060
|
try {
|
|
@@ -1062,19 +1062,19 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1062
1062
|
} catch {
|
|
1063
1063
|
console.log("Slicer context not available for this addon page");
|
|
1064
1064
|
}
|
|
1065
|
-
|
|
1066
|
-
|
|
1065
|
+
s = /* @__PURE__ */ k(ea, { fields: i.fields, children: /* @__PURE__ */ k(
|
|
1066
|
+
Pe,
|
|
1067
1067
|
{
|
|
1068
1068
|
Component: t,
|
|
1069
1069
|
projectName: e,
|
|
1070
|
-
...
|
|
1071
|
-
state: { slicer: h, ...
|
|
1070
|
+
...a,
|
|
1071
|
+
state: { slicer: h, ...u },
|
|
1072
1072
|
...o
|
|
1073
1073
|
}
|
|
1074
1074
|
) });
|
|
1075
1075
|
}
|
|
1076
|
-
return
|
|
1077
|
-
},
|
|
1076
|
+
return s;
|
|
1077
|
+
}, ta = /* @__PURE__ */ new Set([
|
|
1078
1078
|
"name",
|
|
1079
1079
|
"status",
|
|
1080
1080
|
"tags",
|
|
@@ -1089,21 +1089,21 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1089
1089
|
"hasReviewables",
|
|
1090
1090
|
"createdAt",
|
|
1091
1091
|
"updatedAt"
|
|
1092
|
-
]),
|
|
1092
|
+
]), os = ({
|
|
1093
1093
|
filterTypes: t = [],
|
|
1094
1094
|
projectNames: e,
|
|
1095
1095
|
scope: i,
|
|
1096
|
-
scopes:
|
|
1096
|
+
scopes: u,
|
|
1097
1097
|
data: o,
|
|
1098
|
-
config:
|
|
1099
|
-
power:
|
|
1098
|
+
config: a,
|
|
1099
|
+
power: s
|
|
1100
1100
|
}) => {
|
|
1101
1101
|
const h = vt(), l = o.productTypes || [], f = o.productBaseTypes || [];
|
|
1102
1102
|
let n = [];
|
|
1103
|
-
const E = /* @__PURE__ */ new Map(), y =
|
|
1103
|
+
const E = /* @__PURE__ */ new Map(), y = u || (i ? Array.isArray(i) ? i : [i] : []).map((v) => ({
|
|
1104
1104
|
scope: v,
|
|
1105
1105
|
filterTypes: t
|
|
1106
|
-
})),
|
|
1106
|
+
})), T = y.length > 1, m = new Set(
|
|
1107
1107
|
Array.from(new Set(y.flatMap(({ filterTypes: b }) => b))).filter(
|
|
1108
1108
|
(b) => y.filter(({ filterTypes: v }) => v.includes(b)).length > 1
|
|
1109
1109
|
)
|
|
@@ -1120,29 +1120,29 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1120
1120
|
{
|
|
1121
1121
|
skip: !e?.length || !A
|
|
1122
1122
|
}
|
|
1123
|
-
), { data:
|
|
1123
|
+
), { data: V = [] } = Ft(
|
|
1124
1124
|
{ projects: e },
|
|
1125
1125
|
{
|
|
1126
1126
|
skip: !e?.length || !R
|
|
1127
1127
|
}
|
|
1128
|
-
), { attributes: I } = Be(),
|
|
1128
|
+
), { attributes: I } = Be(), L = lt(pt), N = L?.attribFields?.length ? L.attribFields : I, M = /* @__PURE__ */ new Map();
|
|
1129
1129
|
y.forEach(({ scope: b, filterTypes: v }) => {
|
|
1130
|
-
v.includes("attributes") &&
|
|
1130
|
+
v.includes("attributes") && N.filter((S) => S.scope?.includes(b)).forEach((S) => {
|
|
1131
1131
|
M.set(
|
|
1132
|
-
|
|
1133
|
-
(M.get(
|
|
1132
|
+
S.name,
|
|
1133
|
+
(M.get(S.name) || 0) + 1
|
|
1134
1134
|
);
|
|
1135
1135
|
});
|
|
1136
1136
|
}), y.forEach(({ scope: b, filterTypes: v }) => {
|
|
1137
|
-
const
|
|
1137
|
+
const S = T ? b : void 0;
|
|
1138
1138
|
if (v.includes("taskType") && b !== "user") {
|
|
1139
|
-
const r =
|
|
1139
|
+
const r = W(
|
|
1140
1140
|
"taskType",
|
|
1141
1141
|
{
|
|
1142
|
-
...
|
|
1142
|
+
...a,
|
|
1143
1143
|
enableOperatorChange: !1
|
|
1144
1144
|
},
|
|
1145
|
-
|
|
1145
|
+
S,
|
|
1146
1146
|
m.has("taskType")
|
|
1147
1147
|
);
|
|
1148
1148
|
if (r) {
|
|
@@ -1151,13 +1151,13 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1151
1151
|
}
|
|
1152
1152
|
}
|
|
1153
1153
|
if (v.includes("folderType") && b !== "user") {
|
|
1154
|
-
const r =
|
|
1154
|
+
const r = W(
|
|
1155
1155
|
"folderType",
|
|
1156
1156
|
{
|
|
1157
|
-
...
|
|
1157
|
+
...a,
|
|
1158
1158
|
enableOperatorChange: !1
|
|
1159
1159
|
},
|
|
1160
|
-
|
|
1160
|
+
S,
|
|
1161
1161
|
m.has("folderType")
|
|
1162
1162
|
);
|
|
1163
1163
|
if (r) {
|
|
@@ -1166,13 +1166,13 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1166
1166
|
}
|
|
1167
1167
|
}
|
|
1168
1168
|
if (v.includes("productType") && b !== "user") {
|
|
1169
|
-
const r =
|
|
1169
|
+
const r = W(
|
|
1170
1170
|
"productType",
|
|
1171
1171
|
{
|
|
1172
|
-
...
|
|
1172
|
+
...a,
|
|
1173
1173
|
enableOperatorChange: !1
|
|
1174
1174
|
},
|
|
1175
|
-
|
|
1175
|
+
S,
|
|
1176
1176
|
m.has("productType")
|
|
1177
1177
|
);
|
|
1178
1178
|
if (r) {
|
|
@@ -1181,53 +1181,53 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1181
1181
|
}
|
|
1182
1182
|
}
|
|
1183
1183
|
if (v.includes("productBaseType") && b !== "user") {
|
|
1184
|
-
const r =
|
|
1184
|
+
const r = W(
|
|
1185
1185
|
"productBaseType",
|
|
1186
1186
|
{
|
|
1187
|
-
...
|
|
1187
|
+
...a,
|
|
1188
1188
|
enableOperatorChange: !1
|
|
1189
1189
|
},
|
|
1190
|
-
|
|
1190
|
+
S,
|
|
1191
1191
|
m.has("productBaseType")
|
|
1192
1192
|
);
|
|
1193
|
-
r && (f.forEach(({ icon: p, name:
|
|
1194
|
-
r.values?.some((d) => d.id ===
|
|
1195
|
-
id:
|
|
1196
|
-
label:
|
|
1197
|
-
icon: p ||
|
|
1193
|
+
r && (f.forEach(({ icon: p, name: c }) => {
|
|
1194
|
+
r.values?.some((d) => d.id === c) || r.values?.push({
|
|
1195
|
+
id: c,
|
|
1196
|
+
label: c,
|
|
1197
|
+
icon: p || se("product")
|
|
1198
1198
|
});
|
|
1199
|
-
}), o.productBaseTypes?.forEach(({ icon: p, name:
|
|
1200
|
-
r.values?.some((d) => d.id ===
|
|
1201
|
-
id:
|
|
1202
|
-
label:
|
|
1203
|
-
icon: p ||
|
|
1199
|
+
}), o.productBaseTypes?.forEach(({ icon: p, name: c }) => {
|
|
1200
|
+
r.values?.some((d) => d.id === c) || r.values?.push({
|
|
1201
|
+
id: c,
|
|
1202
|
+
label: c,
|
|
1203
|
+
icon: p || se("product")
|
|
1204
1204
|
});
|
|
1205
1205
|
}), n.push(r));
|
|
1206
1206
|
}
|
|
1207
1207
|
if (v.includes("productName") && b === "product") {
|
|
1208
|
-
const r =
|
|
1208
|
+
const r = W(
|
|
1209
1209
|
"productName",
|
|
1210
|
-
|
|
1211
|
-
|
|
1210
|
+
a,
|
|
1211
|
+
S,
|
|
1212
1212
|
m.has("productName")
|
|
1213
1213
|
);
|
|
1214
1214
|
r && (o.productNames?.forEach((p) => {
|
|
1215
|
-
r.values?.some((
|
|
1215
|
+
r.values?.some((c) => c.id === p) || r.values?.push({
|
|
1216
1216
|
id: p,
|
|
1217
1217
|
label: p
|
|
1218
1218
|
});
|
|
1219
1219
|
}), n.push(r));
|
|
1220
1220
|
}
|
|
1221
1221
|
if (v.includes("status")) {
|
|
1222
|
-
const r =
|
|
1222
|
+
const r = W(
|
|
1223
1223
|
"status",
|
|
1224
|
-
{ ...
|
|
1225
|
-
|
|
1224
|
+
{ ...a, enableOperatorChange: !1 },
|
|
1225
|
+
S,
|
|
1226
1226
|
m.has("status")
|
|
1227
1227
|
);
|
|
1228
1228
|
r && (Object.values(g).forEach((p) => {
|
|
1229
1229
|
(p?.statuses || []).filter((d) => d.scope?.includes(b)).forEach((d) => {
|
|
1230
|
-
r.values?.some((
|
|
1230
|
+
r.values?.some((C) => C.id === d.name) || r.values?.push({
|
|
1231
1231
|
id: d.name,
|
|
1232
1232
|
label: d.name,
|
|
1233
1233
|
icon: d.icon,
|
|
@@ -1237,33 +1237,33 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1237
1237
|
}), n.push(r));
|
|
1238
1238
|
}
|
|
1239
1239
|
if (v.includes("assignees")) {
|
|
1240
|
-
const r =
|
|
1240
|
+
const r = W(
|
|
1241
1241
|
"assignees",
|
|
1242
|
-
|
|
1243
|
-
|
|
1242
|
+
a,
|
|
1243
|
+
S,
|
|
1244
1244
|
m.has("assignees")
|
|
1245
1245
|
);
|
|
1246
|
-
r && (
|
|
1247
|
-
r.values?.some((
|
|
1246
|
+
r && (V.forEach((p) => {
|
|
1247
|
+
r.values?.some((c) => c.id === p.name) || r.values?.push({
|
|
1248
1248
|
id: p.name,
|
|
1249
1249
|
label: p.attrib.fullName || p.name,
|
|
1250
1250
|
img: `/api/users/${p.name}/avatar`,
|
|
1251
1251
|
icon: null
|
|
1252
1252
|
});
|
|
1253
|
-
}), r.values?.sort((p,
|
|
1253
|
+
}), r.values?.sort((p, c) => {
|
|
1254
1254
|
const d = o.assignees?.filter((F) => F === p.id).length || 0;
|
|
1255
|
-
return (o.assignees?.filter((F) => F ===
|
|
1255
|
+
return (o.assignees?.filter((F) => F === c.id).length || 0) - d;
|
|
1256
1256
|
}), n.push(r));
|
|
1257
1257
|
}
|
|
1258
1258
|
if (v.includes("author")) {
|
|
1259
|
-
const r =
|
|
1259
|
+
const r = W(
|
|
1260
1260
|
"author",
|
|
1261
|
-
|
|
1262
|
-
|
|
1261
|
+
a,
|
|
1262
|
+
S,
|
|
1263
1263
|
m.has("author")
|
|
1264
1264
|
);
|
|
1265
|
-
r && (
|
|
1266
|
-
r.values?.some((
|
|
1265
|
+
r && (V.forEach((p) => {
|
|
1266
|
+
r.values?.some((c) => c.id === p.name) || r.values?.push({
|
|
1267
1267
|
id: p.name,
|
|
1268
1268
|
label: p.attrib.fullName || p.name,
|
|
1269
1269
|
img: `/api/users/${p.name}/avatar`,
|
|
@@ -1272,57 +1272,57 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1272
1272
|
}), n.push(r));
|
|
1273
1273
|
}
|
|
1274
1274
|
if (v.includes("tags")) {
|
|
1275
|
-
const r =
|
|
1275
|
+
const r = W("tags", a, S, m.has("tags"));
|
|
1276
1276
|
if (r) {
|
|
1277
1277
|
const p = /* @__PURE__ */ new Map();
|
|
1278
|
-
Object.values(g).forEach((
|
|
1279
|
-
|
|
1278
|
+
Object.values(g).forEach((C) => {
|
|
1279
|
+
C?.tags && C.tags.forEach((F) => {
|
|
1280
1280
|
p.has(F.name) || p.set(F.name, F);
|
|
1281
1281
|
});
|
|
1282
1282
|
});
|
|
1283
|
-
const
|
|
1284
|
-
o.tags?.forEach((
|
|
1285
|
-
const F =
|
|
1283
|
+
const c = /* @__PURE__ */ new Map();
|
|
1284
|
+
o.tags?.forEach((C) => {
|
|
1285
|
+
const F = c.get(C);
|
|
1286
1286
|
if (F) {
|
|
1287
1287
|
F.count++;
|
|
1288
1288
|
return;
|
|
1289
1289
|
} else {
|
|
1290
|
-
const w = p.get(
|
|
1291
|
-
|
|
1292
|
-
id:
|
|
1290
|
+
const w = p.get(C);
|
|
1291
|
+
c.set(C, {
|
|
1292
|
+
id: C,
|
|
1293
1293
|
type: "string",
|
|
1294
|
-
label:
|
|
1294
|
+
label: C,
|
|
1295
1295
|
values: [],
|
|
1296
1296
|
color: w?.color || null,
|
|
1297
1297
|
count: 1
|
|
1298
1298
|
});
|
|
1299
1299
|
}
|
|
1300
1300
|
});
|
|
1301
|
-
const d = Array.from(
|
|
1302
|
-
(
|
|
1301
|
+
const d = Array.from(c.values()).sort(
|
|
1302
|
+
(C, F) => F.count - C.count
|
|
1303
1303
|
);
|
|
1304
1304
|
r.values?.push(...d), n.push(r);
|
|
1305
1305
|
}
|
|
1306
1306
|
}
|
|
1307
1307
|
if (v.includes("version")) {
|
|
1308
|
-
const r =
|
|
1309
|
-
r && (rt.forEach((
|
|
1308
|
+
const r = W("version", a, S);
|
|
1309
|
+
r && (rt.forEach((c) => {
|
|
1310
1310
|
r.values?.push({
|
|
1311
|
-
id:
|
|
1312
|
-
label:
|
|
1313
|
-
icon:
|
|
1311
|
+
id: c.value,
|
|
1312
|
+
label: c.label,
|
|
1313
|
+
icon: c.icon
|
|
1314
1314
|
});
|
|
1315
1315
|
}), n.push(r));
|
|
1316
1316
|
}
|
|
1317
1317
|
if (v.includes("name")) {
|
|
1318
|
-
const r =
|
|
1318
|
+
const r = W("name", a, S, m.has("name"));
|
|
1319
1319
|
r && n.push(r);
|
|
1320
1320
|
}
|
|
1321
1321
|
if (v.includes("hasReviewables")) {
|
|
1322
|
-
const r =
|
|
1322
|
+
const r = W(
|
|
1323
1323
|
"hasReviewables",
|
|
1324
|
-
|
|
1325
|
-
|
|
1324
|
+
a,
|
|
1325
|
+
S,
|
|
1326
1326
|
m.has("hasReviewables")
|
|
1327
1327
|
);
|
|
1328
1328
|
if (r) {
|
|
@@ -1342,60 +1342,60 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1342
1342
|
}
|
|
1343
1343
|
}
|
|
1344
1344
|
if (v.includes("createdAt")) {
|
|
1345
|
-
const r =
|
|
1345
|
+
const r = W(
|
|
1346
1346
|
"createdAt",
|
|
1347
|
-
|
|
1348
|
-
|
|
1347
|
+
a,
|
|
1348
|
+
S,
|
|
1349
1349
|
m.has("createdAt")
|
|
1350
1350
|
);
|
|
1351
1351
|
r && (r.values?.push(we), r.values?.push(
|
|
1352
1352
|
...ye().map((p) => ({
|
|
1353
1353
|
...p,
|
|
1354
|
-
contentAfter:
|
|
1354
|
+
contentAfter: s ? void 0 : /* @__PURE__ */ k(le, { icon: "bolt" })
|
|
1355
1355
|
}))
|
|
1356
1356
|
), n.push(r));
|
|
1357
1357
|
}
|
|
1358
1358
|
if (v.includes("updatedAt")) {
|
|
1359
|
-
const r =
|
|
1359
|
+
const r = W(
|
|
1360
1360
|
"updatedAt",
|
|
1361
|
-
|
|
1362
|
-
|
|
1361
|
+
a,
|
|
1362
|
+
S,
|
|
1363
1363
|
m.has("updatedAt")
|
|
1364
1364
|
);
|
|
1365
1365
|
r && (r.values?.push(we), r.values?.push(
|
|
1366
1366
|
...ye().map((p) => ({
|
|
1367
1367
|
...p,
|
|
1368
|
-
contentAfter:
|
|
1368
|
+
contentAfter: s ? void 0 : /* @__PURE__ */ k(le, { icon: "bolt" })
|
|
1369
1369
|
}))
|
|
1370
1370
|
), n.push(r));
|
|
1371
1371
|
}
|
|
1372
1372
|
if (v.includes("attributes")) {
|
|
1373
|
-
const r =
|
|
1373
|
+
const r = N.filter(
|
|
1374
1374
|
(d) => d.scope?.includes(b)
|
|
1375
|
-
), p =
|
|
1375
|
+
), p = _t(o.attributes) ? r : r.filter(
|
|
1376
1376
|
(d) => o.attributes && o.attributes[d.name]
|
|
1377
1377
|
);
|
|
1378
|
-
(
|
|
1379
|
-
const
|
|
1378
|
+
(a?.enableRelativeValues ? p : p.filter((d) => d.data.type !== "datetime")).forEach((d) => {
|
|
1379
|
+
const C = o.attributes && o.attributes[d.name], F = d.data.enum, w = d.data.type, x = [
|
|
1380
1380
|
"list_of_strings",
|
|
1381
1381
|
"list_of_integers",
|
|
1382
1382
|
"list_of_any",
|
|
1383
1383
|
"list_of_submodels"
|
|
1384
|
-
].includes(w || ""), B = w === "datetime",
|
|
1384
|
+
].includes(w || ""), B = w === "datetime", G = w === "string", j = w === "integer" || w === "float", te = x ? a?.enableOperatorChange : !1, q = d.data.default !== void 0 && d.data.default !== null && d.data.inherit !== !1, pe = (x || B || G || j) && !q ? a?.enableRelativeValues : !1, X = aa(
|
|
1385
1385
|
d,
|
|
1386
1386
|
{
|
|
1387
|
-
...
|
|
1387
|
+
...a,
|
|
1388
1388
|
allowsCustomValues: !0,
|
|
1389
1389
|
enableOperatorChange: te,
|
|
1390
1390
|
enableRelativeValues: pe
|
|
1391
1391
|
},
|
|
1392
|
-
|
|
1392
|
+
S,
|
|
1393
1393
|
(M.get(d.name) || 0) > 1
|
|
1394
1394
|
);
|
|
1395
1395
|
if (d.data.enumResolver) {
|
|
1396
1396
|
const J = d.data;
|
|
1397
1397
|
X.loadValuesKey = e?.[0], X.loadValues = async () => xe(
|
|
1398
|
-
|
|
1398
|
+
C,
|
|
1399
1399
|
await h(J, e?.[0]),
|
|
1400
1400
|
w
|
|
1401
1401
|
);
|
|
@@ -1408,7 +1408,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1408
1408
|
"list_of_integers"
|
|
1409
1409
|
], Q = [];
|
|
1410
1410
|
if (fe.includes(w)) {
|
|
1411
|
-
const J = xe(
|
|
1411
|
+
const J = xe(C, F, w);
|
|
1412
1412
|
Q.push(...J);
|
|
1413
1413
|
}
|
|
1414
1414
|
if (w === "boolean") {
|
|
@@ -1429,51 +1429,51 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1429
1429
|
B && (Q.push(we), Q.push(
|
|
1430
1430
|
...ye().map((J) => ({
|
|
1431
1431
|
...J,
|
|
1432
|
-
contentAfter:
|
|
1432
|
+
contentAfter: s ? void 0 : /* @__PURE__ */ k(le, { icon: "bolt" })
|
|
1433
1433
|
}))
|
|
1434
1434
|
)), X.values?.push(...Q), E.set(X.id, d.name), n.push(X);
|
|
1435
1435
|
});
|
|
1436
1436
|
}
|
|
1437
1437
|
});
|
|
1438
|
-
const
|
|
1438
|
+
const H = n.reduce((b, v) => {
|
|
1439
1439
|
if (!v.group) return b;
|
|
1440
|
-
const
|
|
1441
|
-
return b.some((
|
|
1440
|
+
const S = typeof v.group == "string" ? void 0 : v.group, r = S?.name || v.group, p = y.some(({ scope: c }) => c === r);
|
|
1441
|
+
return b.some((c) => c.name === r) || b.push({
|
|
1442
1442
|
name: r,
|
|
1443
|
-
label: p ? de(r) :
|
|
1444
|
-
icon: p ?
|
|
1445
|
-
color:
|
|
1443
|
+
label: p ? de(r) : S?.label || v.label,
|
|
1444
|
+
icon: p ? se(r) : S?.icon || v.icon,
|
|
1445
|
+
color: S?.color || v.color
|
|
1446
1446
|
}), b;
|
|
1447
|
-
}, []),
|
|
1447
|
+
}, []), z = sa(n, E, N), D = oa(
|
|
1448
|
+
H,
|
|
1448
1449
|
z,
|
|
1449
|
-
$,
|
|
1450
1450
|
E,
|
|
1451
|
-
|
|
1451
|
+
N
|
|
1452
1452
|
);
|
|
1453
|
-
return { options:
|
|
1453
|
+
return { options: z, groupOptions: D };
|
|
1454
1454
|
}, ve = ({
|
|
1455
1455
|
projectsInfo: t,
|
|
1456
1456
|
productTypes: e
|
|
1457
1457
|
}, i) => {
|
|
1458
|
-
const
|
|
1459
|
-
return i === "product" ? e.forEach(({ icon: o, name:
|
|
1460
|
-
|
|
1461
|
-
id:
|
|
1458
|
+
const u = [];
|
|
1459
|
+
return i === "product" ? e.forEach(({ icon: o, name: a }) => {
|
|
1460
|
+
u.push({
|
|
1461
|
+
id: a,
|
|
1462
1462
|
type: "string",
|
|
1463
|
-
label:
|
|
1464
|
-
icon: o ||
|
|
1463
|
+
label: a,
|
|
1464
|
+
icon: o || se("product"),
|
|
1465
1465
|
inverted: !1,
|
|
1466
1466
|
values: [],
|
|
1467
1467
|
allowsCustomValues: !1
|
|
1468
1468
|
});
|
|
1469
1469
|
}) : i === "task" ? Object.values(t).forEach((o) => {
|
|
1470
|
-
(o?.taskTypes || []).forEach((
|
|
1471
|
-
|
|
1472
|
-
id:
|
|
1470
|
+
(o?.taskTypes || []).forEach((s) => {
|
|
1471
|
+
u.some((h) => h.id === s.name) || u.push({
|
|
1472
|
+
id: s.name,
|
|
1473
1473
|
type: "string",
|
|
1474
|
-
label:
|
|
1475
|
-
icon:
|
|
1476
|
-
color:
|
|
1474
|
+
label: s.name,
|
|
1475
|
+
icon: s.icon,
|
|
1476
|
+
color: s.color,
|
|
1477
1477
|
inverted: !1,
|
|
1478
1478
|
values: [],
|
|
1479
1479
|
allowsCustomValues: !1,
|
|
@@ -1485,13 +1485,13 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1485
1485
|
});
|
|
1486
1486
|
});
|
|
1487
1487
|
}) : i === "folder" && Object.values(t).forEach((o) => {
|
|
1488
|
-
(o?.folderTypes || []).forEach((
|
|
1489
|
-
|
|
1490
|
-
id:
|
|
1488
|
+
(o?.folderTypes || []).forEach((s) => {
|
|
1489
|
+
u.some((h) => h.id === s.name) || u.push({
|
|
1490
|
+
id: s.name,
|
|
1491
1491
|
type: "string",
|
|
1492
|
-
label:
|
|
1493
|
-
icon:
|
|
1494
|
-
color:
|
|
1492
|
+
label: s.name,
|
|
1493
|
+
icon: s.icon,
|
|
1494
|
+
color: s.color,
|
|
1495
1495
|
inverted: !1,
|
|
1496
1496
|
values: [],
|
|
1497
1497
|
allowsCustomValues: !1,
|
|
@@ -1502,17 +1502,17 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1502
1502
|
}
|
|
1503
1503
|
});
|
|
1504
1504
|
});
|
|
1505
|
-
}),
|
|
1506
|
-
}, Ue = (t, e, i,
|
|
1507
|
-
const { prefixes: o, keys:
|
|
1508
|
-
let
|
|
1509
|
-
return
|
|
1510
|
-
},
|
|
1505
|
+
}), u;
|
|
1506
|
+
}, Ue = (t, e, i, u) => {
|
|
1507
|
+
const { prefixes: o, keys: a } = i || {};
|
|
1508
|
+
let s = t;
|
|
1509
|
+
return a && e in a ? s = `${a[e]}` : o && e in o && (s = `${o[e]}${t}`), u && (s = `${u}_${s}`), s;
|
|
1510
|
+
}, W = (t, e, i, u = !1) => {
|
|
1511
1511
|
const o = (l) => Ue(l, t, e, i);
|
|
1512
|
-
let
|
|
1512
|
+
let a = null;
|
|
1513
1513
|
switch (t) {
|
|
1514
1514
|
case "taskType":
|
|
1515
|
-
|
|
1515
|
+
a = {
|
|
1516
1516
|
id: o("taskType"),
|
|
1517
1517
|
type: "string",
|
|
1518
1518
|
label: "Task Type",
|
|
@@ -1528,7 +1528,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1528
1528
|
};
|
|
1529
1529
|
break;
|
|
1530
1530
|
case "folderType":
|
|
1531
|
-
|
|
1531
|
+
a = {
|
|
1532
1532
|
id: o("folderType"),
|
|
1533
1533
|
type: "string",
|
|
1534
1534
|
label: "Folder Type",
|
|
@@ -1544,7 +1544,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1544
1544
|
};
|
|
1545
1545
|
break;
|
|
1546
1546
|
case "productType":
|
|
1547
|
-
|
|
1547
|
+
a = {
|
|
1548
1548
|
id: o("productType"),
|
|
1549
1549
|
type: "string",
|
|
1550
1550
|
label: "Product Type",
|
|
@@ -1560,7 +1560,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1560
1560
|
};
|
|
1561
1561
|
break;
|
|
1562
1562
|
case "productBaseType":
|
|
1563
|
-
|
|
1563
|
+
a = {
|
|
1564
1564
|
id: o("productBaseType"),
|
|
1565
1565
|
type: "string",
|
|
1566
1566
|
label: "Product Base Type",
|
|
@@ -1576,7 +1576,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1576
1576
|
};
|
|
1577
1577
|
break;
|
|
1578
1578
|
case "productName":
|
|
1579
|
-
|
|
1579
|
+
a = {
|
|
1580
1580
|
id: o("productNames"),
|
|
1581
1581
|
type: "string",
|
|
1582
1582
|
label: "Product Name",
|
|
@@ -1592,7 +1592,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1592
1592
|
};
|
|
1593
1593
|
break;
|
|
1594
1594
|
case "status":
|
|
1595
|
-
|
|
1595
|
+
a = {
|
|
1596
1596
|
id: o("status"),
|
|
1597
1597
|
type: "string",
|
|
1598
1598
|
label: "Status",
|
|
@@ -1608,7 +1608,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1608
1608
|
};
|
|
1609
1609
|
break;
|
|
1610
1610
|
case "assignees":
|
|
1611
|
-
|
|
1611
|
+
a = {
|
|
1612
1612
|
id: o("assignees"),
|
|
1613
1613
|
type: "list_of_strings",
|
|
1614
1614
|
label: "Assignee",
|
|
@@ -1624,7 +1624,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1624
1624
|
};
|
|
1625
1625
|
break;
|
|
1626
1626
|
case "author":
|
|
1627
|
-
|
|
1627
|
+
a = {
|
|
1628
1628
|
id: o("author"),
|
|
1629
1629
|
type: "string",
|
|
1630
1630
|
label: "Author",
|
|
@@ -1640,7 +1640,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1640
1640
|
};
|
|
1641
1641
|
break;
|
|
1642
1642
|
case "tags":
|
|
1643
|
-
|
|
1643
|
+
a = {
|
|
1644
1644
|
id: o("tags"),
|
|
1645
1645
|
type: "list_of_strings",
|
|
1646
1646
|
label: "Tags",
|
|
@@ -1656,11 +1656,11 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1656
1656
|
};
|
|
1657
1657
|
break;
|
|
1658
1658
|
case "version":
|
|
1659
|
-
|
|
1659
|
+
a = {
|
|
1660
1660
|
id: o("version"),
|
|
1661
1661
|
type: "string",
|
|
1662
1662
|
label: "Version",
|
|
1663
|
-
icon:
|
|
1663
|
+
icon: se("version"),
|
|
1664
1664
|
inverted: !1,
|
|
1665
1665
|
operator: "OR",
|
|
1666
1666
|
values: [],
|
|
@@ -1673,7 +1673,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1673
1673
|
};
|
|
1674
1674
|
break;
|
|
1675
1675
|
case "name":
|
|
1676
|
-
|
|
1676
|
+
a = {
|
|
1677
1677
|
id: o("name"),
|
|
1678
1678
|
type: "string",
|
|
1679
1679
|
label: "Name",
|
|
@@ -1689,7 +1689,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1689
1689
|
};
|
|
1690
1690
|
break;
|
|
1691
1691
|
case "hasReviewables":
|
|
1692
|
-
|
|
1692
|
+
a = {
|
|
1693
1693
|
id: o("hasReviewables"),
|
|
1694
1694
|
type: "boolean",
|
|
1695
1695
|
label: "Has Reviewables",
|
|
@@ -1706,7 +1706,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1706
1706
|
};
|
|
1707
1707
|
break;
|
|
1708
1708
|
case "createdAt":
|
|
1709
|
-
|
|
1709
|
+
a = {
|
|
1710
1710
|
id: o("createdAt"),
|
|
1711
1711
|
type: "datetime",
|
|
1712
1712
|
label: "Created",
|
|
@@ -1723,7 +1723,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1723
1723
|
};
|
|
1724
1724
|
break;
|
|
1725
1725
|
case "updatedAt":
|
|
1726
|
-
|
|
1726
|
+
a = {
|
|
1727
1727
|
id: o("updatedAt"),
|
|
1728
1728
|
type: "datetime",
|
|
1729
1729
|
label: "Updated",
|
|
@@ -1740,21 +1740,21 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1740
1740
|
};
|
|
1741
1741
|
break;
|
|
1742
1742
|
}
|
|
1743
|
-
const
|
|
1744
|
-
if ((
|
|
1743
|
+
const s = de(i || ""), h = (l) => i ? `${s} ${l}` : l;
|
|
1744
|
+
if ((u || i) && a) {
|
|
1745
1745
|
const l = i || t;
|
|
1746
|
-
|
|
1746
|
+
a.group = {
|
|
1747
1747
|
name: l,
|
|
1748
|
-
label: i ? de(i) :
|
|
1749
|
-
icon: i ?
|
|
1748
|
+
label: i ? de(i) : a.label,
|
|
1749
|
+
icon: i ? se(i) : a.icon
|
|
1750
1750
|
};
|
|
1751
1751
|
}
|
|
1752
|
-
return
|
|
1753
|
-
},
|
|
1754
|
-
const o = t.data.title || t.name,
|
|
1752
|
+
return a && i && (a.tooltip = h(a.label), a.value = { label: h(a.label) }), a && t === "version" && i === "version" && (a.value = { label: "Product Version" }, a.tooltip = "Product Version"), a;
|
|
1753
|
+
}, aa = (t, e, i, u = !1) => {
|
|
1754
|
+
const o = t.data.title || t.name, a = u || i ? {
|
|
1755
1755
|
name: i || t.name,
|
|
1756
1756
|
label: i ? de(i) : o,
|
|
1757
|
-
icon: i ?
|
|
1757
|
+
icon: i ? se(i) : K(t.name, t.data.type, Re(t.data))
|
|
1758
1758
|
} : void 0;
|
|
1759
1759
|
return {
|
|
1760
1760
|
id: Ue(t.name, "attributes", e, i),
|
|
@@ -1769,26 +1769,26 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1769
1769
|
allowExcludes: e?.enableExcludes,
|
|
1770
1770
|
operatorChangeable: e?.enableOperatorChange,
|
|
1771
1771
|
icon: K(t.name, t.data.type, Re(t.data)),
|
|
1772
|
-
group:
|
|
1772
|
+
group: a,
|
|
1773
1773
|
tooltip: i ? `${de(i)} ${o}` : void 0,
|
|
1774
|
-
value: i ? { icon:
|
|
1774
|
+
value: i ? { icon: se(i) } : void 0,
|
|
1775
1775
|
singleSelect: ["boolean", "datetime"].includes(t.data.type || "")
|
|
1776
1776
|
};
|
|
1777
1777
|
}, xe = (t, e, i) => {
|
|
1778
|
-
const
|
|
1778
|
+
const u = [], o = [];
|
|
1779
1779
|
if (e) {
|
|
1780
|
-
const
|
|
1781
|
-
Et(e,
|
|
1782
|
-
(
|
|
1783
|
-
const h =
|
|
1784
|
-
|
|
1785
|
-
id:
|
|
1780
|
+
const a = (t || []).flatMap((s) => Array.isArray(s) ? s : [s]);
|
|
1781
|
+
Et(e, a).forEach(
|
|
1782
|
+
(s) => {
|
|
1783
|
+
const h = s.icon, l = kt(h);
|
|
1784
|
+
u.push({
|
|
1785
|
+
id: s.value.toString(),
|
|
1786
1786
|
type: i,
|
|
1787
|
-
label:
|
|
1787
|
+
label: s.label,
|
|
1788
1788
|
values: [],
|
|
1789
1789
|
icon: l ? null : h,
|
|
1790
1790
|
img: l ? h : void 0,
|
|
1791
|
-
color:
|
|
1791
|
+
color: s.color,
|
|
1792
1792
|
pt: {
|
|
1793
1793
|
style: { color: "inherit" }
|
|
1794
1794
|
}
|
|
@@ -1796,21 +1796,21 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1796
1796
|
}
|
|
1797
1797
|
);
|
|
1798
1798
|
}
|
|
1799
|
-
return t?.forEach((
|
|
1800
|
-
if (!
|
|
1801
|
-
let
|
|
1802
|
-
switch (typeof
|
|
1799
|
+
return t?.forEach((a) => {
|
|
1800
|
+
if (!a) return;
|
|
1801
|
+
let s = "";
|
|
1802
|
+
switch (typeof a) {
|
|
1803
1803
|
case "string":
|
|
1804
1804
|
case "number":
|
|
1805
1805
|
case "boolean":
|
|
1806
|
-
|
|
1806
|
+
s = a.toString();
|
|
1807
1807
|
break;
|
|
1808
1808
|
case "object":
|
|
1809
|
-
Array.isArray(
|
|
1809
|
+
Array.isArray(a) ? s = a.join(", ") : s = JSON.stringify(a);
|
|
1810
1810
|
break;
|
|
1811
1811
|
}
|
|
1812
|
-
const h =
|
|
1813
|
-
if (
|
|
1812
|
+
const h = s.trim().toLowerCase().replace(/[^a-z0-9\s]/g, "").replace(/\s+/g, "-");
|
|
1813
|
+
if (u?.find((n) => n.id === h)) return;
|
|
1814
1814
|
const f = o.find((n) => n.id === h);
|
|
1815
1815
|
if (f) {
|
|
1816
1816
|
f.count++;
|
|
@@ -1819,37 +1819,37 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1819
1819
|
o.push({
|
|
1820
1820
|
id: h,
|
|
1821
1821
|
type: i,
|
|
1822
|
-
label:
|
|
1822
|
+
label: s,
|
|
1823
1823
|
values: [],
|
|
1824
1824
|
count: 1
|
|
1825
1825
|
});
|
|
1826
|
-
}), o.sort((
|
|
1827
|
-
},
|
|
1828
|
-
ge(
|
|
1829
|
-
e.get(
|
|
1826
|
+
}), o.sort((a, s) => s.count - a.count), [...u, ...o];
|
|
1827
|
+
}, sa = (t, e, i) => [...t].sort((u, o) => Ge(
|
|
1828
|
+
ge(u),
|
|
1829
|
+
e.get(u.id),
|
|
1830
1830
|
ge(o),
|
|
1831
1831
|
e.get(o.id),
|
|
1832
1832
|
i
|
|
1833
|
-
)), ge = (t) => t.group ? typeof t.group == "string" ? t.group : t.group.name : t.id,
|
|
1834
|
-
const
|
|
1835
|
-
return
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
h ? ge(h) :
|
|
1839
|
-
h ? i.get(h.id) :
|
|
1840
|
-
|
|
1833
|
+
)), ge = (t) => t.group ? typeof t.group == "string" ? t.group : t.group.name : t.id, oa = (t, e, i, u) => [...t].sort((o, a) => {
|
|
1834
|
+
const s = e.find((l) => (typeof l.group == "string" ? l.group : l.group?.name) === o.name), h = e.find((l) => (typeof l.group == "string" ? l.group : l.group?.name) === a.name);
|
|
1835
|
+
return Ge(
|
|
1836
|
+
s ? ge(s) : o.name,
|
|
1837
|
+
s ? i.get(s.id) : o.name,
|
|
1838
|
+
h ? ge(h) : a.name,
|
|
1839
|
+
h ? i.get(h.id) : a.name,
|
|
1840
|
+
u
|
|
1841
1841
|
);
|
|
1842
|
-
}),
|
|
1843
|
-
const
|
|
1842
|
+
}), Ge = (t, e, i, u, o) => {
|
|
1843
|
+
const a = new Map(o.map((f, n) => [f.name, n])), s = (f) => {
|
|
1844
1844
|
let n = 0;
|
|
1845
|
-
for (const E of
|
|
1845
|
+
for (const E of ta) {
|
|
1846
1846
|
if (f === E || f.endsWith(`_${E}`)) return n;
|
|
1847
1847
|
n++;
|
|
1848
1848
|
}
|
|
1849
1849
|
return Number.MAX_SAFE_INTEGER;
|
|
1850
|
-
}, h = e ? [1,
|
|
1850
|
+
}, h = e ? [1, a.get(e) ?? Number.MAX_SAFE_INTEGER] : [0, s(t)], l = u ? [1, a.get(u) ?? Number.MAX_SAFE_INTEGER] : [0, s(i)];
|
|
1851
1851
|
return h[0] - l[0] || h[1] - l[1];
|
|
1852
|
-
},
|
|
1852
|
+
}, ns = (t, e, i, u) => {
|
|
1853
1853
|
const o = {
|
|
1854
1854
|
folder: { conditions: [], operator: t?.operator || "and" },
|
|
1855
1855
|
product: { conditions: [], operator: t?.operator || "and" },
|
|
@@ -1860,7 +1860,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1860
1860
|
};
|
|
1861
1861
|
if (!t?.conditions || t?.conditions.length === 0)
|
|
1862
1862
|
return o;
|
|
1863
|
-
const
|
|
1863
|
+
const a = (l) => {
|
|
1864
1864
|
const f = e.find((n) => l.startsWith(`${n}_`));
|
|
1865
1865
|
if (f) {
|
|
1866
1866
|
const n = l.substring(`${f}_`.length);
|
|
@@ -1868,7 +1868,7 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1868
1868
|
} else if (i?.fallbackScope)
|
|
1869
1869
|
return { scope: i.fallbackScope, cleanId: l };
|
|
1870
1870
|
return { scope: null, cleanId: l };
|
|
1871
|
-
},
|
|
1871
|
+
}, s = (l) => {
|
|
1872
1872
|
const f = {
|
|
1873
1873
|
folder: [],
|
|
1874
1874
|
product: [],
|
|
@@ -1878,33 +1878,33 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1878
1878
|
unscoped: []
|
|
1879
1879
|
};
|
|
1880
1880
|
if ("conditions" in l && !("key" in l)) {
|
|
1881
|
-
const n = (l.conditions || []).map((E) =>
|
|
1881
|
+
const n = (l.conditions || []).map((E) => s(E));
|
|
1882
1882
|
Object.keys(f).forEach((E) => {
|
|
1883
|
-
const y = E,
|
|
1884
|
-
|
|
1885
|
-
conditions:
|
|
1883
|
+
const y = E, T = n.flatMap((m) => m[y]);
|
|
1884
|
+
T.length > 0 && (T.length === 1 && !l.operator ? f[y].push(T[0]) : f[y].push({
|
|
1885
|
+
conditions: T,
|
|
1886
1886
|
operator: l.operator
|
|
1887
1887
|
}));
|
|
1888
1888
|
});
|
|
1889
1889
|
} else if ("key" in l) {
|
|
1890
|
-
const { scope: n, cleanId: E } =
|
|
1890
|
+
const { scope: n, cleanId: E } = a(l.key);
|
|
1891
1891
|
if (n)
|
|
1892
1892
|
f[n].push({ ...l, key: E });
|
|
1893
1893
|
else {
|
|
1894
|
-
const y =
|
|
1895
|
-
y ? f[y].push(l) : l.key ===
|
|
1896
|
-
f[
|
|
1894
|
+
const y = u?.[l.key];
|
|
1895
|
+
y ? f[y].push(l) : l.key === ct || l.key === "name" || l.key?.endsWith("_name") ? e.forEach((T) => {
|
|
1896
|
+
f[T].push(l);
|
|
1897
1897
|
}) : f.unscoped.push(l);
|
|
1898
1898
|
}
|
|
1899
1899
|
}
|
|
1900
1900
|
return f;
|
|
1901
|
-
}, h = (t.conditions || []).map((l) =>
|
|
1901
|
+
}, h = (t.conditions || []).map((l) => s(l));
|
|
1902
1902
|
return Object.keys(o).forEach((l) => {
|
|
1903
1903
|
const f = l;
|
|
1904
1904
|
o[f].conditions = h.flatMap((n) => n[f]);
|
|
1905
1905
|
}), o;
|
|
1906
|
-
},
|
|
1907
|
-
const
|
|
1906
|
+
}, rs = (t, e, i) => {
|
|
1907
|
+
const u = {
|
|
1908
1908
|
folder: [],
|
|
1909
1909
|
product: [],
|
|
1910
1910
|
task: [],
|
|
@@ -1913,30 +1913,30 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1913
1913
|
unscoped: []
|
|
1914
1914
|
};
|
|
1915
1915
|
if (!t || t.length === 0)
|
|
1916
|
-
return
|
|
1917
|
-
const o = (
|
|
1916
|
+
return u;
|
|
1917
|
+
const o = (s) => e.find((l) => s.startsWith(`${l}_`)) || null, a = (s, h) => {
|
|
1918
1918
|
const l = `${h}_`;
|
|
1919
|
-
return
|
|
1919
|
+
return s.startsWith(l) ? s.substring(l.length) : s;
|
|
1920
1920
|
};
|
|
1921
|
-
return t.forEach((
|
|
1922
|
-
if (!
|
|
1923
|
-
const h = o(
|
|
1921
|
+
return t.forEach((s) => {
|
|
1922
|
+
if (!s.id) return;
|
|
1923
|
+
const h = o(s.id);
|
|
1924
1924
|
if (h) {
|
|
1925
1925
|
const l = {
|
|
1926
|
-
...
|
|
1927
|
-
id: s
|
|
1926
|
+
...s,
|
|
1927
|
+
id: a(s.id, h)
|
|
1928
1928
|
};
|
|
1929
|
-
|
|
1929
|
+
u[h].push(l);
|
|
1930
1930
|
} else {
|
|
1931
|
-
const l = i?.[
|
|
1932
|
-
l ?
|
|
1931
|
+
const l = i?.[s.id];
|
|
1932
|
+
l ? u[l].push(s) : u.unscoped.push(s);
|
|
1933
1933
|
}
|
|
1934
|
-
}),
|
|
1935
|
-
},
|
|
1936
|
-
folder: [...
|
|
1937
|
-
task: [...
|
|
1934
|
+
}), u;
|
|
1935
|
+
}, ue = ["status", "tags", "attributes", "createdAt", "updatedAt"], na = {
|
|
1936
|
+
folder: [...ue, "name", "folderType"],
|
|
1937
|
+
task: [...ue, "name", "taskType", "folderType", "assignees"],
|
|
1938
1938
|
version: [
|
|
1939
|
-
...
|
|
1939
|
+
...ue,
|
|
1940
1940
|
"version",
|
|
1941
1941
|
"productName",
|
|
1942
1942
|
"productType",
|
|
@@ -1946,145 +1946,183 @@ const Ae = 500, Zt = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, Xs = ({
|
|
|
1946
1946
|
"taskType",
|
|
1947
1947
|
"folderType"
|
|
1948
1948
|
],
|
|
1949
|
-
product: [...
|
|
1950
|
-
user: [...
|
|
1951
|
-
},
|
|
1949
|
+
product: [...ue, "productName", "productBaseType"],
|
|
1950
|
+
user: [...ue]
|
|
1951
|
+
}, ls = (t, e) => t.map((i) => ({
|
|
1952
1952
|
scope: i,
|
|
1953
|
-
filterTypes:
|
|
1953
|
+
filterTypes: na[i].filter((u) => !e?.[i]?.includes(u))
|
|
1954
1954
|
}));
|
|
1955
1955
|
export {
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1956
|
+
oo as $createMediaNode,
|
|
1957
|
+
no as $createMentionNode,
|
|
1958
|
+
ro as $createYouTubeNode,
|
|
1959
|
+
lo as $getMarkdown,
|
|
1960
|
+
io as $isMediaNode,
|
|
1961
|
+
uo as $isMentionNode,
|
|
1962
|
+
co as $isYouTubeNode,
|
|
1963
|
+
po as $setMarkdown,
|
|
1964
|
+
Qa as ACCESS_LEVEL_LABELS,
|
|
1965
|
+
fo as ACTIVITY_LINK_LABEL,
|
|
1966
|
+
Xa as AccessSearchInput,
|
|
1967
|
+
Ce as AccessUser,
|
|
1968
|
+
cs as AddColumnButton,
|
|
1969
|
+
js as AddNewLinks,
|
|
1970
|
+
ds as AddonLoadingScreen,
|
|
1971
|
+
ps as AttributeEditor,
|
|
1972
|
+
De as BLOCK_DIALOG_CLOSE_CLASS,
|
|
1973
|
+
Hs as Badge,
|
|
1974
|
+
$s as BadgeWrapper,
|
|
1975
|
+
mo as CUSTOM_RANGE_ICON,
|
|
1976
|
+
ho as CUSTOM_RANGE_ID,
|
|
1977
|
+
go as CellEditingDialog,
|
|
1978
|
+
Xs as Chips,
|
|
1979
|
+
yr as ColumnHeaderMenuUI,
|
|
1980
|
+
Kn as ColumnMenuButton,
|
|
1981
|
+
fs as ColumnsSettings,
|
|
1982
|
+
ms as ColumnsSettingsWithContext,
|
|
1983
|
+
ur as CustomDateRangeDialog,
|
|
1984
|
+
hs as CustomizeButton,
|
|
1985
|
+
gs as DEFAULT_FEATURED_ORDER,
|
|
1986
|
+
bo as DEFAULT_TOOLBAR,
|
|
1987
|
+
qo as DELETE_CONFIRM_THRESHOLD,
|
|
1988
|
+
an as DELETE_TYPE_ORDER,
|
|
1989
|
+
wo as DESCRIPTION_TOOLBAR,
|
|
1990
|
+
Ja as DateRangePicker,
|
|
1991
|
+
Zo as DeleteConfirmContent,
|
|
1992
|
+
sn as DeleteEntitiesConfirmDialog,
|
|
1993
|
+
Qs as DescriptionSection,
|
|
1994
|
+
cn as DetailsDialog,
|
|
1984
1995
|
wt as DetailsPanelAttributesEditor,
|
|
1985
|
-
|
|
1996
|
+
pn as DetailsPanelDetails,
|
|
1986
1997
|
yt as DetailsSection,
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
1998
|
+
yo as DoneCheckbox,
|
|
1999
|
+
Yn as ENTITY_TOOLTIP_TYPES,
|
|
2000
|
+
bs as EVERYONE_GROUP_KEY,
|
|
2001
|
+
ws as EVERY_GUESTS_KEY,
|
|
2002
|
+
ys as EarlyPreview,
|
|
2003
|
+
Cn as EmptyPlaceholder,
|
|
2004
|
+
Tn as EmptyPlaceholderFlex,
|
|
2005
|
+
Dn as EmptyPlaceholderFlexWrapper,
|
|
2006
|
+
Js as EntityIcon,
|
|
2007
|
+
Mn as EntityPanelUploader,
|
|
2008
|
+
Bn as EntityPath,
|
|
2009
|
+
Hn as EntityTooltip,
|
|
2010
|
+
vs as EnumEditor,
|
|
2011
|
+
Es as EnumEditorItem,
|
|
2001
2012
|
rt as FEATURED_VERSION_TYPES,
|
|
2002
|
-
|
|
2003
|
-
|
|
2013
|
+
na as FILTER_TYPES_BY_SCOPE,
|
|
2014
|
+
vo as FLOATING_TOOLBAR,
|
|
2015
|
+
ks as FeaturedVersionOrder,
|
|
2004
2016
|
xt as FeedbackContext,
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2017
|
+
Za as FeedbackProvider,
|
|
2018
|
+
fn as FieldLabel,
|
|
2019
|
+
mn as FileThumbnail,
|
|
2020
|
+
qn as FilterErrorActions,
|
|
2009
2021
|
ot as FreeTrialLink,
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2022
|
+
Cs as GROUP_KEY_PREFIX,
|
|
2023
|
+
Os as GUEST_KEY_PREFIX,
|
|
2024
|
+
Eo as INSERT_MENTION_TRIGGER_COMMAND,
|
|
2025
|
+
Pn as InfoMessage,
|
|
2026
|
+
Nn as JsonViewer,
|
|
2027
|
+
Ss as LegacyBadge,
|
|
2028
|
+
qs as LinkManagerItem,
|
|
2029
|
+
Zs as LinksManager,
|
|
2030
|
+
es as ListAttributeForm,
|
|
2031
|
+
ts as ListMetaData,
|
|
2032
|
+
ko as MARKDOWN_TRANSFORMERS,
|
|
2033
|
+
Co as MENTION,
|
|
2034
|
+
Oo as MENTION_REF_TYPES,
|
|
2035
|
+
So as MENTION_TRIGGER_BY_TYPE,
|
|
2036
|
+
Vn as MENU_PORTAL_CONTENT_ID,
|
|
2037
|
+
Rn as MENU_PORTAL_DIALOG_ID,
|
|
2038
|
+
To as MarkdownEditor,
|
|
2039
|
+
Do as MediaBlock,
|
|
2040
|
+
Vo as MediaNode,
|
|
2041
|
+
Ro as MentionNode,
|
|
2042
|
+
In as Menu,
|
|
2043
|
+
An as MenuContainer,
|
|
2044
|
+
Fn as MenuList,
|
|
2045
|
+
Io as NO_DATE,
|
|
2046
|
+
On as Placeholder,
|
|
2047
|
+
Ts as PowerpackButton,
|
|
2048
|
+
as as PowerpackDialog,
|
|
2049
|
+
ss as ProjectPageRemote,
|
|
2050
|
+
Ds as ProjectTableSettings,
|
|
2051
|
+
en as RefreshToast,
|
|
2052
|
+
Pe as RemotePageWrapper,
|
|
2053
|
+
Vs as RequiredAddonVersion,
|
|
2054
|
+
hn as ReviewableCard,
|
|
2055
|
+
gn as ReviewableProgressCard,
|
|
2056
|
+
bn as ReviewableUpload,
|
|
2057
|
+
Un as ReviewablesList,
|
|
2058
|
+
Rs as ReviewablesSelector,
|
|
2059
|
+
Is as SettingOption,
|
|
2060
|
+
As as SettingSwitch,
|
|
2061
|
+
Fs as SettingsPanel,
|
|
2062
|
+
_s as SettingsPanelItemTemplate,
|
|
2063
|
+
Ps as ShareOptionIcon,
|
|
2064
|
+
zs as SimpleForm,
|
|
2065
|
+
pr as SimpleFormDialog,
|
|
2066
|
+
xs as SizeSlider,
|
|
2067
|
+
Ns as SplitterStyles,
|
|
2068
|
+
wn as StackedThumbnails,
|
|
2069
|
+
Ls as StyledLink,
|
|
2049
2070
|
eo as SubtasksManagerWrapper,
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
|
|
2071
|
+
jn as SupportBubble,
|
|
2072
|
+
lr as SyncButton,
|
|
2073
|
+
Ms as TEAM_KEY_PREFIX,
|
|
2074
|
+
Bs as TableGridSwitch,
|
|
2075
|
+
mr as TableSearch,
|
|
2076
|
+
nr as TableSettingsFallback,
|
|
2077
|
+
yn as Thumbnail,
|
|
2078
|
+
cr as ThumbnailSimple,
|
|
2079
|
+
Us as USER_KEY_PREFIX,
|
|
2080
|
+
Gs as UploadVersionDialog,
|
|
2081
|
+
Ao as UserImage,
|
|
2061
2082
|
qt as VersionUploadContext,
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2083
|
+
qa as VersionUploadProvider,
|
|
2084
|
+
vn as Watchers,
|
|
2085
|
+
Fo as YouTubeEmbed,
|
|
2086
|
+
_o as YouTubeNode,
|
|
2087
|
+
on as buildChildrenDetails,
|
|
2088
|
+
nn as buildEntityLabel,
|
|
2089
|
+
rn as buildExpectedCounts,
|
|
2090
|
+
ls as buildScopes,
|
|
2091
|
+
Po as createFeedMentionSource,
|
|
2068
2092
|
we as customRangeOption,
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2093
|
+
xo as dateOptions,
|
|
2094
|
+
No as datePresetOptions,
|
|
2095
|
+
Lo as detectRelativeDatePattern,
|
|
2096
|
+
Mo as filterDateFunctions,
|
|
2097
|
+
Bo as generateDateOptions,
|
|
2074
2098
|
ye as generateDatePresetOptions,
|
|
2075
|
-
|
|
2076
|
-
|
|
2099
|
+
Gn as getGroupedReviewables,
|
|
2100
|
+
Uo as getInlineMediaFileIds,
|
|
2101
|
+
Go as getLinkLabel,
|
|
2102
|
+
Wo as getMediaKind,
|
|
2103
|
+
Yo as getMentionTrigger,
|
|
2104
|
+
Ho as getProjectFileId,
|
|
2105
|
+
$o as getSourceLink,
|
|
2106
|
+
Ws as getUiTypeLabel,
|
|
2077
2107
|
to as groupLinksByEntity,
|
|
2108
|
+
zo as isMediaFile,
|
|
2109
|
+
er as markdownToPlainText,
|
|
2110
|
+
Ko as normalizeLegacyMarkdown,
|
|
2111
|
+
jo as parseActivityLink,
|
|
2078
2112
|
Jt as parseFilename,
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2113
|
+
Xo as parseYouTubeUrl,
|
|
2114
|
+
tr as renderMediaParagraph,
|
|
2115
|
+
ar as renderYouTubeParagraph,
|
|
2116
|
+
rs as splitClientFiltersByScope,
|
|
2117
|
+
ns as splitFiltersByScope,
|
|
2118
|
+
ln as sumExpectedCounts,
|
|
2119
|
+
Qo as toggleBlockFormat,
|
|
2120
|
+
os as useBuildFilterOptions,
|
|
2121
|
+
sr as useDateRangeFilter,
|
|
2122
|
+
Xn as useFeedback,
|
|
2123
|
+
Qn as useFeedbackSafe,
|
|
2124
|
+
gr as useOptionalVersionUploadContext,
|
|
2125
|
+
En as useReviewablesUpload,
|
|
2126
|
+
ao as useUpdateLinks,
|
|
2127
|
+
br as useVersionUploadContext
|
|
2090
2128
|
};
|