@edifice.io/collect-frontend 0.2.2-develop-pedago.3.20260427140647 → 0.2.2-develop-pedago.3.20260427141148
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/lib/{AppHeaderCollection-kvrVhjY4.js → AppHeaderCollection-CdMZTmC6.js} +2 -2
- package/lib/{CXEL7IU7-YR1p-dSz.js → CXEL7IU7-BLUeaFt5.js} +2 -2
- package/lib/{Collection-DjhIi0xZ.js → Collection-CUCjNGrr.js} +5 -5
- package/lib/CollectionsLayout-DVYmui3o.js +187 -0
- package/lib/{CollectionsList-BfBhNzg0.js → CollectionsList-Ba1LoCCN.js} +3 -3
- package/lib/{DeleteCollectionModal-CqvWe76x.js → DeleteCollectionModal-CtmfiR2H.js} +6 -6
- package/lib/{DropdownActionTable-HE8xkue1.js → DropdownActionTable-BhSk2sde.js} +1 -1
- package/lib/{FormEdit-BAUK0iW4.js → FormEdit-DZFkw7z9.js} +5 -5
- package/lib/{HASRA6WW-DNF4eod8.js → HASRA6WW-BPaxT9L-.js} +1 -1
- package/lib/{I3HPI4QX-CrHrEiVm.js → I3HPI4QX-BuVHGkjY.js} +7 -7
- package/lib/{MembersEdit-BC5Xh_DT.js → MembersEdit-CblCChDS.js} +5 -5
- package/lib/{Root-DfmgZRZW.js → Root--z47Brfh.js} +1 -1
- package/lib/{Submission-DXh-e8oM.js → Submission-AzDGz_dM.js} +4 -4
- package/lib/{SubmissionList-Cm7DopEJ.js → SubmissionList-Db_nRSqg.js} +9 -9
- package/lib/{index-DT2Ns44Q.js → index-HU8ua_Ev.js} +576 -586
- package/lib/index.js +1 -1
- package/lib/{submission.queries-DQbHLY_g.js → submission.queries-Cr0bP5uv.js} +1 -1
- package/package.json +1 -1
- package/lib/CollectionsLayout-CkXyUy2P.js +0 -187
|
@@ -2,10 +2,10 @@ import { jsxs as c, jsx as o } from "react/jsx-runtime";
|
|
|
2
2
|
import { useEdificeClient as m, Flex as r, Button as u, IconButton as I, useBreakpoint as f, useDate as S, Badge as g } from "@edifice.io/react";
|
|
3
3
|
import { IconPinOn as O, IconOptions as y, IconSave as L, IconSend as v, IconArrowLeft as M, IconCalendarLight as N } from "@edifice.io/react/icons";
|
|
4
4
|
import { useTranslation as p } from "react-i18next";
|
|
5
|
-
import { u as b, D as w } from "./DropdownActionTable-
|
|
5
|
+
import { u as b, D as w } from "./DropdownActionTable-BhSk2sde.js";
|
|
6
6
|
import { ContribSubmissionStatus as x } from "@edifice.io/collect-client-rest";
|
|
7
7
|
import { create as A } from "zustand";
|
|
8
|
-
import { c as H } from "./index-
|
|
8
|
+
import { c as H } from "./index-HU8ua_Ev.js";
|
|
9
9
|
const D = ({
|
|
10
10
|
collection: n
|
|
11
11
|
}) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./HASRA6WW-
|
|
2
|
-
import {
|
|
1
|
+
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./HASRA6WW-BPaxT9L-.js";
|
|
2
|
+
import { l as v, m as C, n as e } from "./index-HU8ua_Ev.js";
|
|
3
3
|
var h = (t) => {
|
|
4
4
|
const [r, o] = s({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -3,15 +3,15 @@ import { SubmissionStatus as f, ManagerSubmissionStatus as M, WORKFLOW_RIGHTS as
|
|
|
3
3
|
import { useDirectory as R, Flex as u, Avatar as P, Badge as v, useEdificeClient as w, Heading as O, Table as C, Button as x, LoadingScreen as T, Modal as I, Dropdown as N, useToast as G, useBreakpoint as j, useDate as _, EmptyScreen as K, Checkbox as Y, Grid as L, useHasWorkflow as J } from "@edifice.io/react";
|
|
4
4
|
import { useNavigate as $, useParams as X } from "react-router-dom";
|
|
5
5
|
import { useState as A, useEffect as k } from "react";
|
|
6
|
-
import { A as Z, C as q } from "./AppHeaderCollection-
|
|
6
|
+
import { A as Z, C as q } from "./AppHeaderCollection-CdMZTmC6.js";
|
|
7
7
|
import { IconUsers as ee, IconRafterDown as U, IconEdit as te, IconTextPage as se, IconCalendarLight as ne } from "@edifice.io/react/icons";
|
|
8
8
|
import { useTranslation as D } from "react-i18next";
|
|
9
|
-
import { u as ie, a as oe, s as ae } from "./submission.queries-
|
|
9
|
+
import { u as ie, a as oe, s as ae } from "./submission.queries-Cr0bP5uv.js";
|
|
10
10
|
import { create as ce } from "zustand";
|
|
11
|
-
import { c as le,
|
|
11
|
+
import { c as le, e as re, P as de, f as ue } from "./index-HU8ua_Ev.js";
|
|
12
12
|
import { u as F } from "./useGetStatusSubmission-DxHmLPxr.js";
|
|
13
|
-
import { u as E } from "./DropdownActionTable-
|
|
14
|
-
import { D as me } from "./DeleteCollectionModal-
|
|
13
|
+
import { u as E } from "./DropdownActionTable-BhSk2sde.js";
|
|
14
|
+
import { D as me } from "./DeleteCollectionModal-CtmfiR2H.js";
|
|
15
15
|
import { Editor as H } from "@edifice.io/react/editor";
|
|
16
16
|
import { E as he } from "./emptyscreen-list-collection-CWGxO4Ss.js";
|
|
17
17
|
const W = (t) => {
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import { jsxs as s, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { WORKFLOW_RIGHTS as C } from "@edifice.io/collect-client-rest";
|
|
3
|
+
import { useEdificeClient as L, useHasWorkflow as T, Button as _, Menu as h, Tree as k, Dropdown as m, Flex as E, useBreakpoint as R, AppHeader as w, Breadcrumb as U, Grid as M, LoadingScreen as A } from "@edifice.io/react";
|
|
4
|
+
import { Suspense as y } from "react";
|
|
5
|
+
import { useNavigate as N, useLocation as f, Navigate as F, Outlet as H } from "react-router-dom";
|
|
6
|
+
import { IconDepositeInbox as $, IconPlus as j, IconSubmission as v, IconCollect as x } from "@edifice.io/react/icons";
|
|
7
|
+
import { useTranslation as b } from "react-i18next";
|
|
8
|
+
import { create as D } from "zustand";
|
|
9
|
+
import { c as W } from "./index-HU8ua_Ev.js";
|
|
10
|
+
function G() {
|
|
11
|
+
const { appCode: i } = L(), { t: l } = b(i), r = N(), c = T(C.COLLECTION_CREATE);
|
|
12
|
+
return /* @__PURE__ */ s("div", { className: "d-flex flex-fill align-items-center justify-content-end gap-12 align-self-end", children: [
|
|
13
|
+
/* @__PURE__ */ e(
|
|
14
|
+
_,
|
|
15
|
+
{
|
|
16
|
+
type: "button",
|
|
17
|
+
color: "primary",
|
|
18
|
+
variant: "outline",
|
|
19
|
+
leftIcon: /* @__PURE__ */ e($, {}),
|
|
20
|
+
onClick: () => {
|
|
21
|
+
},
|
|
22
|
+
children: l("collection.appHeaderAction.button.toCollection")
|
|
23
|
+
}
|
|
24
|
+
),
|
|
25
|
+
c && /* @__PURE__ */ e(
|
|
26
|
+
_,
|
|
27
|
+
{
|
|
28
|
+
"data-testid": "collect-collection-app-header-create-collection-button",
|
|
29
|
+
type: "button",
|
|
30
|
+
color: "primary",
|
|
31
|
+
leftIcon: /* @__PURE__ */ e(j, {}),
|
|
32
|
+
onClick: () => r("/create/form"),
|
|
33
|
+
children: l("collection.appHeaderAction.button.newCollection")
|
|
34
|
+
}
|
|
35
|
+
)
|
|
36
|
+
] });
|
|
37
|
+
}
|
|
38
|
+
const t = {
|
|
39
|
+
LIST_COLLECTIONS: "list-collections",
|
|
40
|
+
LIST_SUBMISSIONS: "list-submissions"
|
|
41
|
+
}, K = D((i) => ({
|
|
42
|
+
mobileMenuOpen: !1,
|
|
43
|
+
selectedMenu: "list-collections",
|
|
44
|
+
setMobileMenuOpen: (l) => i({ mobileMenuOpen: l }),
|
|
45
|
+
setSelectedMenu: (l) => i({ selectedMenu: l })
|
|
46
|
+
})), B = W(K), P = () => {
|
|
47
|
+
const i = N(), { pathname: l } = f(), { appCode: r } = L(), { t: c } = b(r), a = B.use.setSelectedMenu(), d = T(C.COLLECTION_CREATE), O = [
|
|
48
|
+
...d ? [
|
|
49
|
+
{
|
|
50
|
+
id: t.LIST_COLLECTIONS,
|
|
51
|
+
name: c("collection.collection")
|
|
52
|
+
}
|
|
53
|
+
] : [],
|
|
54
|
+
{
|
|
55
|
+
id: t.LIST_SUBMISSIONS,
|
|
56
|
+
name: c("collection.submission")
|
|
57
|
+
}
|
|
58
|
+
], S = (o) => {
|
|
59
|
+
switch (o) {
|
|
60
|
+
case t.LIST_COLLECTIONS:
|
|
61
|
+
return /* @__PURE__ */ e(x, {});
|
|
62
|
+
case t.LIST_SUBMISSIONS:
|
|
63
|
+
return /* @__PURE__ */ e(v, {});
|
|
64
|
+
default:
|
|
65
|
+
return null;
|
|
66
|
+
}
|
|
67
|
+
}, g = (o) => {
|
|
68
|
+
a(o), i(`/${o}`);
|
|
69
|
+
}, u = () => {
|
|
70
|
+
const p = {
|
|
71
|
+
"/": t.LIST_COLLECTIONS,
|
|
72
|
+
"/list-collections": t.LIST_COLLECTIONS,
|
|
73
|
+
"/list-submissions": t.LIST_SUBMISSIONS
|
|
74
|
+
}[l] || null;
|
|
75
|
+
return !d && p === t.LIST_COLLECTIONS ? t.LIST_SUBMISSIONS : p;
|
|
76
|
+
};
|
|
77
|
+
return /* @__PURE__ */ s("div", { className: "border-end p-16 h-100 ps-0", children: [
|
|
78
|
+
/* @__PURE__ */ e("p", { className: "caption text-uppercase fw-semibold text-gray-700", children: c("collection.title") }),
|
|
79
|
+
/* @__PURE__ */ s(h, { label: c("collection.title"), children: [
|
|
80
|
+
/* @__PURE__ */ e(h.Item, { children: /* @__PURE__ */ e("div", { className: "treeview ps-16 pt-16", children: /* @__PURE__ */ e(
|
|
81
|
+
k,
|
|
82
|
+
{
|
|
83
|
+
nodes: O,
|
|
84
|
+
selectedNodeId: u(),
|
|
85
|
+
showIcon: !1,
|
|
86
|
+
renderNode: ({ node: o }) => /* @__PURE__ */ s("div", { className: "d-flex align-items-center gap-8", children: [
|
|
87
|
+
S(o.id),
|
|
88
|
+
/* @__PURE__ */ e("span", { children: o.name })
|
|
89
|
+
] }),
|
|
90
|
+
onTreeItemClick: g
|
|
91
|
+
}
|
|
92
|
+
) }) }),
|
|
93
|
+
/* @__PURE__ */ e(h.Item, { children: /* @__PURE__ */ e("div", { className: "separator-dashed w-100 mt-12 my-12" }) })
|
|
94
|
+
] })
|
|
95
|
+
] });
|
|
96
|
+
}, q = () => {
|
|
97
|
+
const i = N(), { pathname: l } = f(), { appCode: r } = L(), { t: c } = b(r), a = T(C.COLLECTION_CREATE), { setSelectedMenu: d, setMobileMenuOpen: O } = B((n) => ({
|
|
98
|
+
setSelectedMenu: n.setSelectedMenu,
|
|
99
|
+
setMobileMenuOpen: n.setMobileMenuOpen
|
|
100
|
+
})), S = [
|
|
101
|
+
...a ? [
|
|
102
|
+
{
|
|
103
|
+
id: "collection",
|
|
104
|
+
label: c("collection.collection"),
|
|
105
|
+
icon: /* @__PURE__ */ e(x, {}),
|
|
106
|
+
path: "/list-collections",
|
|
107
|
+
filterMenu: t.LIST_COLLECTIONS
|
|
108
|
+
}
|
|
109
|
+
] : [],
|
|
110
|
+
{
|
|
111
|
+
id: "submission",
|
|
112
|
+
label: c("collection.submission"),
|
|
113
|
+
icon: /* @__PURE__ */ e(v, {}),
|
|
114
|
+
path: "/list-submissions",
|
|
115
|
+
filterMenu: t.LIST_SUBMISSIONS
|
|
116
|
+
}
|
|
117
|
+
], u = (() => {
|
|
118
|
+
const I = {
|
|
119
|
+
"/": t.LIST_COLLECTIONS,
|
|
120
|
+
"/list-collections": t.LIST_COLLECTIONS,
|
|
121
|
+
"/list-submissions": t.LIST_SUBMISSIONS
|
|
122
|
+
}[l] || t.LIST_SUBMISSIONS;
|
|
123
|
+
return !a && I === t.LIST_COLLECTIONS ? t.LIST_SUBMISSIONS : I;
|
|
124
|
+
})(), o = S.find(
|
|
125
|
+
(n) => n.filterMenu === u
|
|
126
|
+
), p = (n, I) => {
|
|
127
|
+
d(I), i(n);
|
|
128
|
+
};
|
|
129
|
+
return /* @__PURE__ */ e("div", { className: "position-relative w-100 p-16", children: /* @__PURE__ */ s(m, { block: !0, onToggle: (n) => O(n), children: [
|
|
130
|
+
/* @__PURE__ */ e(
|
|
131
|
+
m.Trigger,
|
|
132
|
+
{
|
|
133
|
+
label: /* @__PURE__ */ s(E, { align: "center", gap: "8", children: [
|
|
134
|
+
o == null ? void 0 : o.icon,
|
|
135
|
+
(o == null ? void 0 : o.label) || c("collection.title")
|
|
136
|
+
] })
|
|
137
|
+
}
|
|
138
|
+
),
|
|
139
|
+
/* @__PURE__ */ e(m.Menu, { children: S.map((n) => /* @__PURE__ */ e(
|
|
140
|
+
m.Item,
|
|
141
|
+
{
|
|
142
|
+
onClick: () => p(n.path, n.filterMenu),
|
|
143
|
+
icon: n.icon,
|
|
144
|
+
className: u === n.filterMenu ? "active" : "",
|
|
145
|
+
children: /* @__PURE__ */ e("span", { children: n.label })
|
|
146
|
+
},
|
|
147
|
+
n.id
|
|
148
|
+
)) })
|
|
149
|
+
] }) });
|
|
150
|
+
}, ne = async () => null, oe = () => {
|
|
151
|
+
const { currentApp: i } = L(), { lg: l } = R(), { pathname: r } = f(), c = T(C.COLLECTION_CREATE), a = r === "/" || r === `/${t.LIST_COLLECTIONS}`;
|
|
152
|
+
return c !== void 0 && !c && a ? /* @__PURE__ */ e(F, { to: `/${t.LIST_SUBMISSIONS}`, replace: !0 }) : /* @__PURE__ */ s(E, { direction: "column", className: "flex-grow-1", children: [
|
|
153
|
+
/* @__PURE__ */ e(w, { render: G, children: /* @__PURE__ */ e(U, { app: i }) }),
|
|
154
|
+
/* @__PURE__ */ s(M, { className: "flex-grow-1", children: [
|
|
155
|
+
/* @__PURE__ */ e(
|
|
156
|
+
M.Col,
|
|
157
|
+
{
|
|
158
|
+
sm: "3",
|
|
159
|
+
md: "3",
|
|
160
|
+
lg: "2",
|
|
161
|
+
xl: "3",
|
|
162
|
+
className: "d-none d-lg-block",
|
|
163
|
+
as: "aside",
|
|
164
|
+
children: /* @__PURE__ */ e(P, {})
|
|
165
|
+
}
|
|
166
|
+
),
|
|
167
|
+
/* @__PURE__ */ s(
|
|
168
|
+
M.Col,
|
|
169
|
+
{
|
|
170
|
+
sm: "4",
|
|
171
|
+
md: "8",
|
|
172
|
+
lg: "6",
|
|
173
|
+
xl: "9",
|
|
174
|
+
className: `${l ? "cancel-gap" : ""}`,
|
|
175
|
+
children: [
|
|
176
|
+
!l && /* @__PURE__ */ e(q, {}),
|
|
177
|
+
/* @__PURE__ */ e(y, { fallback: /* @__PURE__ */ e(A, {}), children: /* @__PURE__ */ e(H, {}) })
|
|
178
|
+
]
|
|
179
|
+
}
|
|
180
|
+
)
|
|
181
|
+
] })
|
|
182
|
+
] });
|
|
183
|
+
};
|
|
184
|
+
export {
|
|
185
|
+
oe as Component,
|
|
186
|
+
ne as loader
|
|
187
|
+
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { jsx as e, Fragment as T, jsxs as u } from "react/jsx-runtime";
|
|
2
2
|
import { useState as D, useMemo as L, useCallback as B, useEffect as E } from "react";
|
|
3
3
|
import { S as A } from "./SearchBarCollect-DBKaVVDV.js";
|
|
4
|
-
import { c as F,
|
|
4
|
+
import { c as F, u as M, W as O, a as R } from "./index-HU8ua_Ev.js";
|
|
5
5
|
import { useDate as $, Table as m, Flex as I, Badge as k, IconButton as S, useEdificeClient as v, EmptyScreen as G, LoadingScreen as j } from "@edifice.io/react";
|
|
6
6
|
import { useTranslation as N } from "react-i18next";
|
|
7
7
|
import { E as Q } from "./emptyscreen-list-collection-CWGxO4Ss.js";
|
|
8
|
-
import { D as W } from "./DeleteCollectionModal-
|
|
8
|
+
import { D as W } from "./DeleteCollectionModal-CtmfiR2H.js";
|
|
9
9
|
import { SortDirection as b, CollectionSortField as y } from "@edifice.io/collect-client-rest";
|
|
10
10
|
import { create as _ } from "zustand";
|
|
11
11
|
import { IconOptions as H, IconRafterLeft as z, IconRafterRight as K, IconListOrder as U, IconArrowUp as Y, IconArrowDown as Z } from "@edifice.io/react/icons";
|
|
12
12
|
import { t as q } from "i18next";
|
|
13
13
|
import { useNavigate as J } from "react-router-dom";
|
|
14
|
-
import { D as V } from "./DropdownActionTable-
|
|
14
|
+
import { D as V } from "./DropdownActionTable-BhSk2sde.js";
|
|
15
15
|
const X = {
|
|
16
16
|
search: "",
|
|
17
17
|
sortBy: y.DEADLINE,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsxs as s, jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { useEdificeClient as m, useToast as
|
|
3
|
-
import { IconDelete as
|
|
2
|
+
import { useEdificeClient as m, useToast as f, Modal as d, Button as C } from "@edifice.io/react";
|
|
3
|
+
import { IconDelete as h } from "@edifice.io/react/icons";
|
|
4
4
|
import { useTranslation as p } from "react-i18next";
|
|
5
|
-
import {
|
|
6
|
-
import { u as D } from "./DropdownActionTable-
|
|
5
|
+
import { g as M } from "./index-HU8ua_Ev.js";
|
|
6
|
+
import { u as D } from "./DropdownActionTable-BhSk2sde.js";
|
|
7
7
|
const y = () => {
|
|
8
|
-
const { appCode: r } = m(), { t: n } = p(r), e =
|
|
8
|
+
const { appCode: r } = m(), { t: n } = p(r), e = f(), a = M(), { isDeleteModalOpen: l, onCloseDeleteModal: c, deleteCollectionId: i } = D((o) => ({
|
|
9
9
|
isDeleteModalOpen: o.isDeleteModalOpen,
|
|
10
10
|
onCloseDeleteModal: o.onCloseDeleteModal,
|
|
11
11
|
deleteCollectionId: o.deleteCollectionId
|
|
@@ -57,7 +57,7 @@ const y = () => {
|
|
|
57
57
|
"data-testid": "collect-collection-delete-modal-button-delete",
|
|
58
58
|
color: "danger",
|
|
59
59
|
onClick: i,
|
|
60
|
-
leftIcon: /* @__PURE__ */ t(
|
|
60
|
+
leftIcon: /* @__PURE__ */ t(h, {}),
|
|
61
61
|
children: e("collection.delete")
|
|
62
62
|
}
|
|
63
63
|
)
|
|
@@ -6,7 +6,7 @@ import { IconExternalLink as I, IconEdit as h, IconShare as O, IconDelete as w }
|
|
|
6
6
|
import { useTranslation as D } from "react-i18next";
|
|
7
7
|
import { useNavigate as C } from "react-router-dom";
|
|
8
8
|
import { create as b } from "zustand";
|
|
9
|
-
import { c as M } from "./index-
|
|
9
|
+
import { c as M } from "./index-HU8ua_Ev.js";
|
|
10
10
|
const T = b((e) => ({
|
|
11
11
|
isDeleteModalOpen: !1,
|
|
12
12
|
deleteCollectionId: null,
|
|
@@ -2,17 +2,17 @@ import { jsx as t, jsxs as g, Fragment as N } from "react/jsx-runtime";
|
|
|
2
2
|
import { WORKFLOW_RIGHTS as v, MediaType as x } from "@edifice.io/collect-client-rest";
|
|
3
3
|
import { useEdificeClient as I, useBreakpoint as w, useToast as E, useHasWorkflow as F, LoadingScreen as L, Grid as h, Flex as y, Button as C } from "@edifice.io/react";
|
|
4
4
|
import { useState as O } from "react";
|
|
5
|
-
import { useTranslation as
|
|
6
|
-
import { useParams as
|
|
7
|
-
import {
|
|
8
|
-
import { s as S } from "./submission.queries-
|
|
5
|
+
import { useTranslation as k } from "react-i18next";
|
|
6
|
+
import { useParams as P, useNavigate as A } from "react-router-dom";
|
|
7
|
+
import { k as Q, e as R, P as W, F as j, f as H } from "./index-HU8ua_Ev.js";
|
|
8
|
+
import { s as S } from "./submission.queries-Cr0bP5uv.js";
|
|
9
9
|
const J = (s) => async ({ params: i }) => {
|
|
10
10
|
const a = Number(i.collectionId);
|
|
11
11
|
return await s.ensureQueryData(H(a)), await s.prefetchInfiniteQuery(
|
|
12
12
|
S(a)
|
|
13
13
|
), null;
|
|
14
14
|
}, V = () => {
|
|
15
|
-
const { appCode: s } = I(), { t: i } =
|
|
15
|
+
const { appCode: s } = I(), { t: i } = k(s), { lg: a } = w(), d = P(), u = A(), m = E(), f = F(v.COLLECTION_CREATE), p = Q(), [e, T] = O(void 0), { data: o, isLoading: l } = R(
|
|
16
16
|
Number(d.collectionId)
|
|
17
17
|
);
|
|
18
18
|
if (l)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var bs = Object.defineProperty;
|
|
2
2
|
var ps = (e, t, n) => t in e ? bs(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
3
|
var qe = (e, t, n) => ps(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
-
import {
|
|
4
|
+
import { o as z, p as H, m as D, n as v, q as xe, r as wt, s as _o, t as N, v as k, w as G, x as T, y as ws, z as or, A as $e, B as V, C as Gn, D as Vn, E as dt, G as M, H as q, I as xs, J as cn, K as Ne, L as $s, N as qt, O as zt, Q as Cs, R as Ss, T as $n, U as ks, V as Br, X as Kt, $ as Ro, Y as Es, Z as W, _ as Nr, a0 as Ds, a1 as As, a2 as ir, a3 as Ms, a4 as Ts, a5 as Fs, a6 as zn, a7 as Is, a8 as Os, a9 as oe, aa as Ls, ab as Ps } from "./index-HU8ua_Ev.js";
|
|
5
5
|
var qs = (e) => e != null, _s = (e) => e.filter(qs);
|
|
6
6
|
function Rs(e) {
|
|
7
7
|
return (...t) => {
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { c, T as l, P as m, a as u, D as v, Q as i } from "./HASRA6WW-
|
|
2
|
-
import {
|
|
1
|
+
import { c, T as l, P as m, a as u, D as v, Q as i } from "./HASRA6WW-BPaxT9L-.js";
|
|
2
|
+
import { l as d, m as f, n as e } from "./index-HU8ua_Ev.js";
|
|
3
3
|
var p = (a) => {
|
|
4
|
-
const [r,
|
|
4
|
+
const [r, t] = c({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
6
6
|
}), n = d(), s = f(() => {
|
|
7
|
-
const
|
|
8
|
-
return
|
|
7
|
+
const o = r.theme_preference || l;
|
|
8
|
+
return o !== "system" ? o : n();
|
|
9
9
|
});
|
|
10
10
|
return e(i.Provider, {
|
|
11
11
|
value: a,
|
|
12
12
|
get children() {
|
|
13
13
|
return e(m, {
|
|
14
14
|
localStore: r,
|
|
15
|
-
setLocalStore:
|
|
15
|
+
setLocalStore: t,
|
|
16
16
|
get children() {
|
|
17
17
|
return e(u.Provider, {
|
|
18
18
|
value: s,
|
|
19
19
|
get children() {
|
|
20
20
|
return e(v, {
|
|
21
21
|
localStore: r,
|
|
22
|
-
setLocalStore:
|
|
22
|
+
setLocalStore: t
|
|
23
23
|
});
|
|
24
24
|
}
|
|
25
25
|
});
|
|
@@ -2,21 +2,21 @@ import { jsx as e, jsxs as c, Fragment as T } from "react/jsx-runtime";
|
|
|
2
2
|
import { WORKFLOW_RIGHTS as N } from "@edifice.io/collect-client-rest";
|
|
3
3
|
import { useEdificeClient as v, useBreakpoint as I, useToast as D, useHasWorkflow as E, LoadingScreen as O, Grid as l, Flex as d, Button as u } from "@edifice.io/react";
|
|
4
4
|
import { useTranslation as S } from "react-i18next";
|
|
5
|
-
import { useParams as
|
|
6
|
-
import {
|
|
7
|
-
import { s as R } from "./submission.queries-
|
|
5
|
+
import { useParams as w, useNavigate as A } from "react-router-dom";
|
|
6
|
+
import { h as L, i as m, e as j, P as k, M, f as P, j as Q } from "./index-HU8ua_Ev.js";
|
|
7
|
+
import { s as R } from "./submission.queries-Cr0bP5uv.js";
|
|
8
8
|
const K = (o) => async ({ params: t }) => {
|
|
9
9
|
const s = Number(t.collectionId);
|
|
10
10
|
return await o.ensureQueryData(P(s)), await o.prefetchInfiniteQuery(
|
|
11
11
|
R(s)
|
|
12
12
|
), null;
|
|
13
13
|
}, $ = () => {
|
|
14
|
-
const { appCode: o } = v(), { t } = S(o), { lg: s } = I(), p =
|
|
14
|
+
const { appCode: o } = v(), { t } = S(o), { lg: s } = I(), p = w(), a = D(), n = A(), g = E(N.COLLECTION_CREATE), h = L(), f = m.use.usersToAdd(), b = m.use.usersToDelete(), { data: i, isLoading: r } = j(
|
|
15
15
|
Number(p.collectionId)
|
|
16
16
|
);
|
|
17
17
|
if (r)
|
|
18
18
|
return /* @__PURE__ */ e(O, {});
|
|
19
|
-
if (!g || !i) return /* @__PURE__ */ e(
|
|
19
|
+
if (!g || !i) return /* @__PURE__ */ e(k, {});
|
|
20
20
|
const C = async () => {
|
|
21
21
|
const y = Q(b, f);
|
|
22
22
|
try {
|
|
@@ -2,7 +2,7 @@ import { jsx as o, jsxs as i } from "react/jsx-runtime";
|
|
|
2
2
|
import { WORKFLOW_RIGHTS as e } from "@edifice.io/collect-client-rest";
|
|
3
3
|
import { useEdificeClient as n, useHasWorkflow as s, LoadingScreen as c, Layout as f } from "@edifice.io/react";
|
|
4
4
|
import { Outlet as a, ScrollRestoration as l } from "react-router-dom";
|
|
5
|
-
import { P as m } from "./index-
|
|
5
|
+
import { P as m } from "./index-HU8ua_Ev.js";
|
|
6
6
|
const R = async () => null;
|
|
7
7
|
function S() {
|
|
8
8
|
const { init: r } = n(), t = s(e.COLLECTION_ACCESS);
|
|
@@ -2,14 +2,14 @@ import { jsxs as a, jsx as s } from "react/jsx-runtime";
|
|
|
2
2
|
import { useEdificeClient as m, Flex as l, Heading as y, IconButton as v, Modal as u, Button as C, useToast as E, useBreakpoint as O, Grid as h, LoadingScreen as P } from "@edifice.io/react";
|
|
3
3
|
import { useNavigate as x, useParams as k } from "react-router-dom";
|
|
4
4
|
import { useState as B, useEffect as N } from "react";
|
|
5
|
-
import { u as g, A as T, C as j } from "./AppHeaderCollection-
|
|
5
|
+
import { u as g, A as T, C as j } from "./AppHeaderCollection-CdMZTmC6.js";
|
|
6
6
|
import { Editor as U } from "@edifice.io/react/editor";
|
|
7
7
|
import { IconPinOn as A, IconRafterUp as H, IconRafterDown as Q, IconSend as F, IconTextPage as R } from "@edifice.io/react/icons";
|
|
8
8
|
import { useTranslation as b } from "react-i18next";
|
|
9
9
|
import { ContribSubmissionStatus as $ } from "@edifice.io/collect-client-rest";
|
|
10
|
-
import { u as w } from "./DropdownActionTable-
|
|
11
|
-
import { b as W, c as z, d as G } from "./submission.queries-
|
|
12
|
-
import {
|
|
10
|
+
import { u as w } from "./DropdownActionTable-BhSk2sde.js";
|
|
11
|
+
import { b as W, c as z, d as G } from "./submission.queries-Cr0bP5uv.js";
|
|
12
|
+
import { e as V, P as J, f as K } from "./index-HU8ua_Ev.js";
|
|
13
13
|
const I = ({
|
|
14
14
|
collection: n,
|
|
15
15
|
isMobile: o = !1
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx as t, Fragment as C, jsxs as r } from "react/jsx-runtime";
|
|
2
|
-
import { useEdificeClient as
|
|
2
|
+
import { useEdificeClient as b, SegmentedControl as D, useDate as I, useDirectory as B, Card as p, Flex as g, Avatar as w, Badge as F, LoadingScreen as M, EmptyScreen as E, Grid as f, Button as P, useBreakpoint as $ } from "@edifice.io/react";
|
|
3
3
|
import { S as j } from "./SearchBarCollect-DBKaVVDV.js";
|
|
4
4
|
import { CollectionStatus as N, SubmissionStatus as v } from "@edifice.io/collect-client-rest";
|
|
5
|
-
import { useTranslation as
|
|
5
|
+
import { useTranslation as x } from "react-i18next";
|
|
6
6
|
import { create as R } from "zustand";
|
|
7
|
-
import { c as U,
|
|
7
|
+
import { c as U, b as Y, d as k } from "./index-HU8ua_Ev.js";
|
|
8
8
|
import { IconRafterDown as z } from "@edifice.io/react/icons";
|
|
9
9
|
import { useNavigate as A } from "react-router-dom";
|
|
10
10
|
import { E as G } from "./emptyscreen-list-collection-CWGxO4Ss.js";
|
|
@@ -12,14 +12,14 @@ import { u as O } from "./useGetStatusSubmission-DxHmLPxr.js";
|
|
|
12
12
|
const Q = {
|
|
13
13
|
search: "",
|
|
14
14
|
filter: void 0
|
|
15
|
-
},
|
|
15
|
+
}, S = U(
|
|
16
16
|
R((e) => ({
|
|
17
17
|
...Q,
|
|
18
18
|
setFilter: (s) => e({ filter: s }),
|
|
19
19
|
setSearchSubmission: (s) => e({ search: s })
|
|
20
20
|
}))
|
|
21
21
|
), V = () => {
|
|
22
|
-
const { appCode: e } =
|
|
22
|
+
const { appCode: e } = b(), { t: s } = x(e), { filter: o, setFilter: n } = S(), i = [
|
|
23
23
|
{
|
|
24
24
|
label: s("collection.submissionList.filter.all"),
|
|
25
25
|
value: "all"
|
|
@@ -48,7 +48,7 @@ const Q = {
|
|
|
48
48
|
collectionToSubmit: e,
|
|
49
49
|
onClick: s
|
|
50
50
|
}) => {
|
|
51
|
-
const { fromNow: o, formatDate: n } = I(), { getAvatarURL: i } = B(), { appCode: m } =
|
|
51
|
+
const { fromNow: o, formatDate: n } = I(), { getAvatarURL: i } = B(), { appCode: m } = b(), { t: l } = x(m), { getSubmissionStatus: c } = O(), a = e.status === v.SUBMITTED || e.status === v.VERIFIED, u = i(e.createdBy.entId, "user"), d = new Date(e.deadline) < /* @__PURE__ */ new Date(), h = c({
|
|
52
52
|
status: e.status,
|
|
53
53
|
isPastDeadline: d,
|
|
54
54
|
isSubmissionCard: !0
|
|
@@ -115,7 +115,7 @@ const Q = {
|
|
|
115
115
|
] });
|
|
116
116
|
}, _ = () => {
|
|
117
117
|
var h, y;
|
|
118
|
-
const { filter: e, search: s } =
|
|
118
|
+
const { filter: e, search: s } = S(), o = e || void 0, n = s || void 0, { data: i, isLoading: m, fetchNextPage: l } = Y({
|
|
119
119
|
filter: o,
|
|
120
120
|
search: n
|
|
121
121
|
}), c = (y = (h = i == null ? void 0 : i.pages) == null ? void 0 : h[i.pages.length - 1]) == null ? void 0 : y.meta, a = !!c && Number(c.currentPage ?? 0) < Number(c.totalPages ?? 0), u = (i == null ? void 0 : i.pages.flatMap((L) => L.items)) ?? [], d = u.length > 0;
|
|
@@ -127,7 +127,7 @@ const Q = {
|
|
|
127
127
|
fetchNextPage: l
|
|
128
128
|
};
|
|
129
129
|
}, q = () => {
|
|
130
|
-
const { appCode: e } =
|
|
130
|
+
const { appCode: e } = b(), { t: s } = x(e), o = A(), {
|
|
131
131
|
collectionsToSubmit: n,
|
|
132
132
|
isLoading: i,
|
|
133
133
|
hasMoreResources: m,
|
|
@@ -172,7 +172,7 @@ const Q = {
|
|
|
172
172
|
filter: void 0
|
|
173
173
|
})
|
|
174
174
|
), null), re = () => {
|
|
175
|
-
const { lg: e } = $(), s =
|
|
175
|
+
const { lg: e } = $(), s = S(
|
|
176
176
|
(o) => o.setSearchSubmission
|
|
177
177
|
);
|
|
178
178
|
return /* @__PURE__ */ r(C, { children: [
|