@australiangreens/ag-internal-components 0.0.71 → 0.0.72
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/.gitignore +0 -0
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/components/FetchAutocomplete/FetchAutocomplete.d.ts +3 -3
- package/dist/components/FetchAutocomplete/FetchAutocomplete.d.ts.map +1 -1
- package/dist/esm/index.js +702 -685
- package/dist/esm/index.js.map +1 -1
- package/dist/testing/wrappers.d.ts +0 -1
- package/dist/testing/wrappers.d.ts.map +1 -1
- package/package.json +19 -22
package/dist/esm/index.js
CHANGED
|
@@ -1,109 +1,108 @@
|
|
|
1
|
-
var
|
|
1
|
+
var Ot = Object.defineProperty, $t = Object.defineProperties;
|
|
2
2
|
var It = Object.getOwnPropertyDescriptors;
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
var
|
|
3
|
+
var ee = Object.getOwnPropertySymbols;
|
|
4
|
+
var ye = Object.prototype.hasOwnProperty, Ne = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var ge = (e, t, n) => t in e ? Ot(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, i = (e, t) => {
|
|
6
6
|
for (var n in t || (t = {}))
|
|
7
|
-
|
|
8
|
-
if (
|
|
9
|
-
for (var n of
|
|
10
|
-
|
|
7
|
+
ye.call(t, n) && ge(e, n, t[n]);
|
|
8
|
+
if (ee)
|
|
9
|
+
for (var n of ee(t))
|
|
10
|
+
Ne.call(t, n) && ge(e, n, t[n]);
|
|
11
11
|
return e;
|
|
12
|
-
},
|
|
13
|
-
var
|
|
12
|
+
}, S = (e, t) => $t(e, It(t));
|
|
13
|
+
var Pe = (e, t) => {
|
|
14
14
|
var n = {};
|
|
15
|
-
for (var
|
|
16
|
-
|
|
17
|
-
if (e != null &&
|
|
18
|
-
for (var
|
|
19
|
-
t.indexOf(
|
|
15
|
+
for (var r in e)
|
|
16
|
+
ye.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
|
|
17
|
+
if (e != null && ee)
|
|
18
|
+
for (var r of ee(e))
|
|
19
|
+
t.indexOf(r) < 0 && Ne.call(e, r) && (n[r] = e[r]);
|
|
20
20
|
return n;
|
|
21
21
|
};
|
|
22
|
-
var
|
|
23
|
-
var
|
|
24
|
-
var
|
|
22
|
+
var Be = (e, t, n) => (ge(e, typeof t != "symbol" ? t + "" : t, n), n);
|
|
23
|
+
var B = (e, t, n) => new Promise((r, s) => {
|
|
24
|
+
var l = (p) => {
|
|
25
25
|
try {
|
|
26
|
-
|
|
27
|
-
} catch (
|
|
28
|
-
|
|
26
|
+
h(n.next(p));
|
|
27
|
+
} catch (u) {
|
|
28
|
+
s(u);
|
|
29
29
|
}
|
|
30
|
-
},
|
|
30
|
+
}, d = (p) => {
|
|
31
31
|
try {
|
|
32
|
-
|
|
33
|
-
} catch (
|
|
34
|
-
|
|
32
|
+
h(n.throw(p));
|
|
33
|
+
} catch (u) {
|
|
34
|
+
s(u);
|
|
35
35
|
}
|
|
36
|
-
},
|
|
37
|
-
|
|
36
|
+
}, h = (p) => p.done ? r(p.value) : Promise.resolve(p.value).then(l, d);
|
|
37
|
+
h((n = n.apply(e, t)).next());
|
|
38
38
|
});
|
|
39
|
-
import { jsxs as
|
|
40
|
-
import { useState as
|
|
41
|
-
import { Typography as
|
|
39
|
+
import { jsxs as f, Fragment as L, jsx as o } from "react/jsx-runtime";
|
|
40
|
+
import { useState as O, createContext as Je, useCallback as oe, useContext as Ye, useEffect as re, useMemo as Et, createElement as xe, useRef as fe } from "react";
|
|
41
|
+
import { Typography as T, Button as we, Paper as Ze, Box as D, Drawer as Ae, Dialog as Tt, DialogTitle as Ft, DialogContent as yt, DialogActions as Nt, Autocomplete as Se, TextField as De, CircularProgress as ke, Chip as Pt, Tooltip as Bt, Stack as Lt, styled as Oe, IconButton as Q, Container as et, useTheme as ae, useMediaQuery as Mt, Collapse as _t, Avatar as Le, Fade as Ht, Skeleton as Me, Toolbar as Rt, Divider as _e, CssBaseline as Wt, Snackbar as zt, Alert as Gt, LinearProgress as Ut, FormHelperText as Vt } from "@mui/material";
|
|
42
42
|
import qt from "@mui/material/CssBaseline";
|
|
43
|
-
import { styled as M, createTheme as
|
|
44
|
-
import { AgError as
|
|
45
|
-
import { createHelper as
|
|
46
|
-
import
|
|
47
|
-
import { Cancel as
|
|
48
|
-
import Kt from "autosuggest-highlight/match";
|
|
43
|
+
import { styled as M, createTheme as tt, alpha as me } from "@mui/material/styles";
|
|
44
|
+
import { AgError as Xt } from "@australiangreens/ag-error";
|
|
45
|
+
import { createHelper as se } from "souvlaki";
|
|
46
|
+
import nt from "@mui/material/List";
|
|
47
|
+
import { Cancel as jt, ArrowDropDown as Qt, ArrowForward as ot, ArrowBack as rt, ViewHeadline as Kt } from "@mui/icons-material";
|
|
49
48
|
import Jt from "autosuggest-highlight/parse";
|
|
50
|
-
import
|
|
51
|
-
import { atom as
|
|
52
|
-
import { useHydrateAtoms as
|
|
53
|
-
function
|
|
54
|
-
const [t, n] =
|
|
55
|
-
return /* @__PURE__ */
|
|
56
|
-
/* @__PURE__ */ o(
|
|
57
|
-
/* @__PURE__ */ o(
|
|
49
|
+
import Yt from "autosuggest-highlight/match";
|
|
50
|
+
import { atom as N, useSetAtom as it, useAtomValue as He, useAtom as V, getDefaultStore as Zt, Provider as at } from "jotai";
|
|
51
|
+
import { useHydrateAtoms as st } from "jotai/utils";
|
|
52
|
+
function co({ text: e }) {
|
|
53
|
+
const [t, n] = O(0);
|
|
54
|
+
return /* @__PURE__ */ f(L, { children: [
|
|
55
|
+
/* @__PURE__ */ o(T, { variant: "h6", color: "inherit", component: "div", sx: { fontSize: "22px" }, children: "Hello world" }),
|
|
56
|
+
/* @__PURE__ */ o(T, { variant: "caption", display: "block", children: /* @__PURE__ */ o("span", { children: "Just ensuring MUI is working as planned as a peer dependency. v0.0.11" }) }),
|
|
58
57
|
/* @__PURE__ */ o(
|
|
59
|
-
|
|
58
|
+
we,
|
|
60
59
|
{
|
|
61
60
|
variant: "outlined",
|
|
62
|
-
onClick: () => n((
|
|
61
|
+
onClick: () => n((r) => r + 1),
|
|
63
62
|
"aria-label": "Increment",
|
|
64
63
|
children: "Hello I am a button"
|
|
65
64
|
}
|
|
66
65
|
),
|
|
67
|
-
/* @__PURE__ */
|
|
66
|
+
/* @__PURE__ */ f("p", { children: [
|
|
68
67
|
"This is some text: ",
|
|
69
68
|
/* @__PURE__ */ o("span", { children: e })
|
|
70
69
|
] }),
|
|
71
|
-
/* @__PURE__ */
|
|
70
|
+
/* @__PURE__ */ f(Ze, { children: [
|
|
72
71
|
"This number will incremember when button pressed: ",
|
|
73
72
|
t
|
|
74
73
|
] })
|
|
75
74
|
] });
|
|
76
75
|
}
|
|
77
|
-
const
|
|
78
|
-
root: `${
|
|
79
|
-
menuButton: `${
|
|
80
|
-
hide: `${
|
|
81
|
-
content: `${
|
|
82
|
-
userInfoHolder: `${
|
|
83
|
-
settings: `${
|
|
84
|
-
pieChartIcon: `${
|
|
85
|
-
},
|
|
76
|
+
const lt = 330, ct = 73, G = "Navbar", q = {
|
|
77
|
+
root: `${G}-root`,
|
|
78
|
+
menuButton: `${G}-menuButton`,
|
|
79
|
+
hide: `${G}-hide`,
|
|
80
|
+
content: `${G}-content`,
|
|
81
|
+
userInfoHolder: `${G}-userInfoHolder`,
|
|
82
|
+
settings: `${G}-settings`,
|
|
83
|
+
pieChartIcon: `${G}-pieChartIcon`
|
|
84
|
+
}, en = M(D, {
|
|
86
85
|
name: "NavBar"
|
|
87
86
|
})(({ theme: e }) => ({
|
|
88
|
-
[`&.${
|
|
87
|
+
[`&.${q.root}`]: {
|
|
89
88
|
display: "flex"
|
|
90
89
|
},
|
|
91
|
-
[`& .${
|
|
90
|
+
[`& .${q.menuButton}`]: {
|
|
92
91
|
marginRight: 36
|
|
93
92
|
},
|
|
94
|
-
[`& .${
|
|
93
|
+
[`& .${q.hide}`]: {
|
|
95
94
|
display: "none"
|
|
96
95
|
},
|
|
97
|
-
[`& .${
|
|
96
|
+
[`& .${q.content}`]: {
|
|
98
97
|
flexGrow: 1,
|
|
99
98
|
padding: e.spacing(3)
|
|
100
99
|
},
|
|
101
|
-
[`& .${
|
|
100
|
+
[`& .${q.userInfoHolder}`]: {
|
|
102
101
|
height: "148px",
|
|
103
102
|
marginTop: "64px",
|
|
104
103
|
marginBottom: "16px"
|
|
105
104
|
}
|
|
106
|
-
})),
|
|
105
|
+
})), dt = () => ({
|
|
107
106
|
position: "absolute",
|
|
108
107
|
height: "100%",
|
|
109
108
|
overflowX: "hidden",
|
|
@@ -111,51 +110,51 @@ const it = 330, rt = 73, z = "Navbar", V = {
|
|
|
111
110
|
color: "white",
|
|
112
111
|
backgroundColor: "black"
|
|
113
112
|
// backgroundColor: '#e8e8e8',
|
|
114
|
-
}),
|
|
115
|
-
width:
|
|
116
|
-
},
|
|
117
|
-
width:
|
|
118
|
-
},
|
|
113
|
+
}), tn = () => i({
|
|
114
|
+
width: lt
|
|
115
|
+
}, dt()), nn = () => i({
|
|
116
|
+
width: ct
|
|
117
|
+
}, dt()), on = M(Ae, {
|
|
119
118
|
shouldForwardProp: (e) => e !== "open"
|
|
120
|
-
})(({ theme: e, open: t }) =>
|
|
121
|
-
width: t ?
|
|
119
|
+
})(({ theme: e, open: t }) => i(i({
|
|
120
|
+
width: t ? lt : ct,
|
|
122
121
|
flexShrink: 0,
|
|
123
122
|
whiteSpace: "nowrap",
|
|
124
123
|
boxSizing: "border-box",
|
|
125
124
|
zIndex: e.zIndex.drawer + 100
|
|
126
125
|
}, t && {
|
|
127
|
-
"& .MuiDrawer-paper":
|
|
126
|
+
"& .MuiDrawer-paper": tn()
|
|
128
127
|
}), !t && {
|
|
129
|
-
"& .MuiDrawer-paper":
|
|
128
|
+
"& .MuiDrawer-paper": nn()
|
|
130
129
|
}));
|
|
131
|
-
class
|
|
130
|
+
class $e extends Xt {
|
|
132
131
|
}
|
|
133
|
-
|
|
134
|
-
const
|
|
135
|
-
overrideState: e =
|
|
136
|
-
overrideActions: t =
|
|
132
|
+
Be($e, "errorName", "ContextError");
|
|
133
|
+
const pt = Je(null), rn = {}, an = {}, sn = ({
|
|
134
|
+
overrideState: e = rn,
|
|
135
|
+
overrideActions: t = an,
|
|
137
136
|
children: n
|
|
138
137
|
}) => {
|
|
139
|
-
const [{ open:
|
|
140
|
-
|
|
141
|
-
}, []),
|
|
142
|
-
|
|
143
|
-
}, []),
|
|
144
|
-
open:
|
|
145
|
-
setOpen:
|
|
146
|
-
toggleOpen:
|
|
138
|
+
const [{ open: r }, s] = O({ open: !0 }), l = oe((p) => {
|
|
139
|
+
s({ open: p });
|
|
140
|
+
}, []), d = oe(() => {
|
|
141
|
+
s((p) => S(i({}, p), { open: !p.open }));
|
|
142
|
+
}, []), h = i(i({
|
|
143
|
+
open: r,
|
|
144
|
+
setOpen: l,
|
|
145
|
+
toggleOpen: d
|
|
147
146
|
}, e), t);
|
|
148
|
-
return /* @__PURE__ */ o(
|
|
149
|
-
},
|
|
150
|
-
const e =
|
|
147
|
+
return /* @__PURE__ */ o(pt.Provider, { value: h, children: n });
|
|
148
|
+
}, ln = () => {
|
|
149
|
+
const e = Ye(pt);
|
|
151
150
|
if (e === null)
|
|
152
|
-
throw new
|
|
151
|
+
throw new $e("Error: Tried to useNavBar outside of a <NavBarProvider>");
|
|
153
152
|
return e;
|
|
154
|
-
},
|
|
153
|
+
}, cn = (e = {}) => i({
|
|
155
154
|
open: !0
|
|
156
|
-
}, e),
|
|
157
|
-
(e =
|
|
158
|
-
),
|
|
155
|
+
}, e), po = se(
|
|
156
|
+
(e = cn(), t = {}) => ({ children: n }) => /* @__PURE__ */ o(sn, { overrideState: e, overrideActions: t, children: n })
|
|
157
|
+
), Re = 7, uo = M(nt)(({ theme: e }) => ({
|
|
159
158
|
backgroundColor: "black",
|
|
160
159
|
color: "white",
|
|
161
160
|
"& .MuiListItem-root": {
|
|
@@ -164,7 +163,7 @@ const st = Xe(null), sn = {}, ln = {}, cn = ({
|
|
|
164
163
|
"& .MuiListItemButton-root": {
|
|
165
164
|
" .MuiListItemIcon-root": {
|
|
166
165
|
color: "white",
|
|
167
|
-
padding: `${
|
|
166
|
+
padding: `${Re}px`
|
|
168
167
|
},
|
|
169
168
|
// Focus state
|
|
170
169
|
"&.Mui-focusVisible": {
|
|
@@ -175,7 +174,7 @@ const st = Xe(null), sn = {}, ln = {}, cn = ({
|
|
|
175
174
|
borderLeftStyle: "solid",
|
|
176
175
|
borderLeftWidth: "7px",
|
|
177
176
|
borderLeftColor: e.palette.primary.main,
|
|
178
|
-
paddingLeft: `calc(${e.spacing(2)} - ${
|
|
177
|
+
paddingLeft: `calc(${e.spacing(2)} - ${Re}px)`
|
|
179
178
|
},
|
|
180
179
|
// Hover state
|
|
181
180
|
"&:hover": {
|
|
@@ -193,7 +192,7 @@ const st = Xe(null), sn = {}, ln = {}, cn = ({
|
|
|
193
192
|
// '&.Mui-selected.Mui-focusVisible:hover': {
|
|
194
193
|
// },
|
|
195
194
|
}
|
|
196
|
-
})),
|
|
195
|
+
})), We = 7, ho = M(nt)(({ theme: e }) => ({
|
|
197
196
|
backgroundColor: "#e8e8e8",
|
|
198
197
|
color: "inherit",
|
|
199
198
|
"& .MuiListItem-root": {
|
|
@@ -202,7 +201,7 @@ const st = Xe(null), sn = {}, ln = {}, cn = ({
|
|
|
202
201
|
"& .MuiListItemButton-root": {
|
|
203
202
|
" .MuiListItemIcon-root": {
|
|
204
203
|
color: "inherit",
|
|
205
|
-
padding: `${
|
|
204
|
+
padding: `${We}px`
|
|
206
205
|
},
|
|
207
206
|
// Focus state
|
|
208
207
|
"&.Mui-focusVisible": {
|
|
@@ -213,7 +212,7 @@ const st = Xe(null), sn = {}, ln = {}, cn = ({
|
|
|
213
212
|
borderLeftStyle: "solid",
|
|
214
213
|
borderLeftWidth: "7px",
|
|
215
214
|
borderLeftColor: e.palette.primary.main,
|
|
216
|
-
paddingLeft: `calc(${e.spacing(2)} - ${
|
|
215
|
+
paddingLeft: `calc(${e.spacing(2)} - ${We}px)`
|
|
217
216
|
},
|
|
218
217
|
// Hover state
|
|
219
218
|
"&:hover": {
|
|
@@ -232,15 +231,15 @@ const st = Xe(null), sn = {}, ln = {}, cn = ({
|
|
|
232
231
|
// },
|
|
233
232
|
}
|
|
234
233
|
}));
|
|
235
|
-
function
|
|
234
|
+
function go({
|
|
236
235
|
"data-testid": e,
|
|
237
236
|
children: t
|
|
238
237
|
}) {
|
|
239
|
-
const { open: n } =
|
|
240
|
-
return /* @__PURE__ */
|
|
238
|
+
const { open: n } = ln();
|
|
239
|
+
return /* @__PURE__ */ f(en, { className: q.root, "data-testid": e, children: [
|
|
241
240
|
/* @__PURE__ */ o(qt, {}),
|
|
242
241
|
/* @__PURE__ */ o(
|
|
243
|
-
|
|
242
|
+
on,
|
|
244
243
|
{
|
|
245
244
|
variant: "permanent",
|
|
246
245
|
anchor: "left",
|
|
@@ -251,55 +250,55 @@ function Co({
|
|
|
251
250
|
)
|
|
252
251
|
] });
|
|
253
252
|
}
|
|
254
|
-
const
|
|
253
|
+
const dn = ({
|
|
255
254
|
isOpen: e,
|
|
256
255
|
dialogTitle: t,
|
|
257
256
|
children: n,
|
|
258
|
-
maxWidth:
|
|
259
|
-
primaryButton:
|
|
260
|
-
secondaryButton:
|
|
261
|
-
onClose:
|
|
262
|
-
sx:
|
|
263
|
-
"data-testid":
|
|
257
|
+
maxWidth: r,
|
|
258
|
+
primaryButton: s,
|
|
259
|
+
secondaryButton: l,
|
|
260
|
+
onClose: d,
|
|
261
|
+
sx: h,
|
|
262
|
+
"data-testid": p
|
|
264
263
|
}) => {
|
|
265
|
-
var b,
|
|
266
|
-
const [
|
|
267
|
-
return /* @__PURE__ */
|
|
268
|
-
|
|
264
|
+
var b, A;
|
|
265
|
+
const [u, w] = O(!1);
|
|
266
|
+
return /* @__PURE__ */ f(
|
|
267
|
+
Tt,
|
|
269
268
|
{
|
|
270
269
|
open: e,
|
|
271
|
-
onClose: () =>
|
|
272
|
-
|
|
270
|
+
onClose: () => B(void 0, null, function* () {
|
|
271
|
+
u || (l != null && l.onClick ? yield l.onClick() : d());
|
|
273
272
|
}),
|
|
274
273
|
fullWidth: !0,
|
|
275
|
-
maxWidth:
|
|
276
|
-
"data-testid":
|
|
277
|
-
sx:
|
|
274
|
+
maxWidth: r != null ? r : "xs",
|
|
275
|
+
"data-testid": p,
|
|
276
|
+
sx: h,
|
|
278
277
|
children: [
|
|
279
|
-
/* @__PURE__ */ o(
|
|
280
|
-
/* @__PURE__ */ o(
|
|
281
|
-
/* @__PURE__ */
|
|
278
|
+
/* @__PURE__ */ o(Ft, { children: t }),
|
|
279
|
+
/* @__PURE__ */ o(yt, { sx: { "& > :last-child": { marginBottom: 0 } }, children: n }),
|
|
280
|
+
/* @__PURE__ */ f(Nt, { children: [
|
|
282
281
|
/* @__PURE__ */ o(
|
|
283
|
-
|
|
282
|
+
we,
|
|
284
283
|
{
|
|
285
|
-
onClick: (b =
|
|
286
|
-
"data-testid":
|
|
287
|
-
disabled: (
|
|
288
|
-
color:
|
|
289
|
-
children: (
|
|
284
|
+
onClick: (b = l == null ? void 0 : l.onClick) != null ? b : d,
|
|
285
|
+
"data-testid": l == null ? void 0 : l.testId,
|
|
286
|
+
disabled: (l == null ? void 0 : l.disabled) || u,
|
|
287
|
+
color: l == null ? void 0 : l.buttonColor,
|
|
288
|
+
children: (A = l == null ? void 0 : l.text) != null ? A : "Cancel"
|
|
290
289
|
}
|
|
291
290
|
),
|
|
292
|
-
|
|
293
|
-
|
|
291
|
+
s && /* @__PURE__ */ o(
|
|
292
|
+
we,
|
|
294
293
|
{
|
|
295
|
-
onClick: () =>
|
|
294
|
+
onClick: () => B(void 0, null, function* () {
|
|
296
295
|
var C;
|
|
297
|
-
w(!0), yield (C =
|
|
296
|
+
w(!0), yield (C = s.onClick) == null ? void 0 : C.call(s), w(!1);
|
|
298
297
|
}),
|
|
299
|
-
"data-testid":
|
|
300
|
-
disabled:
|
|
301
|
-
color:
|
|
302
|
-
children:
|
|
298
|
+
"data-testid": s.testId,
|
|
299
|
+
disabled: s.disabled || u,
|
|
300
|
+
color: s == null ? void 0 : s.buttonColor,
|
|
301
|
+
children: s.text
|
|
303
302
|
}
|
|
304
303
|
)
|
|
305
304
|
] })
|
|
@@ -307,116 +306,138 @@ const un = ({
|
|
|
307
306
|
}
|
|
308
307
|
);
|
|
309
308
|
};
|
|
310
|
-
function
|
|
311
|
-
lookup: e = () =>
|
|
309
|
+
function fo({
|
|
310
|
+
lookup: e = () => B(this, null, function* () {
|
|
312
311
|
}),
|
|
313
312
|
enableHighlighting: t = !0,
|
|
314
313
|
onChange: n,
|
|
315
|
-
minLength:
|
|
316
|
-
label:
|
|
317
|
-
value:
|
|
318
|
-
"data-testid":
|
|
319
|
-
sx:
|
|
320
|
-
textFieldColor:
|
|
321
|
-
textFieldVariant:
|
|
314
|
+
minLength: r,
|
|
315
|
+
label: s,
|
|
316
|
+
value: l,
|
|
317
|
+
"data-testid": d,
|
|
318
|
+
sx: h,
|
|
319
|
+
textFieldColor: p,
|
|
320
|
+
textFieldVariant: u = "filled",
|
|
322
321
|
loadingText: w = "Loading...",
|
|
323
322
|
noOptionsText: b = "No options",
|
|
324
|
-
popupIcon:
|
|
323
|
+
popupIcon: A = /* @__PURE__ */ o(Qt, {}),
|
|
325
324
|
error: C = !1,
|
|
326
|
-
helperText:
|
|
327
|
-
preLoadedOptions:
|
|
328
|
-
disablePortal:
|
|
325
|
+
helperText: k = "",
|
|
326
|
+
preLoadedOptions: v = void 0,
|
|
327
|
+
disablePortal: $ = !1
|
|
329
328
|
}) {
|
|
330
|
-
const [
|
|
331
|
-
const
|
|
332
|
-
n(
|
|
333
|
-
}
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
)
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
329
|
+
const [g, m] = O(""), [_, F] = O(v || []), [y, I] = O(!1), [H, P] = O(!1), R = (a, c) => {
|
|
330
|
+
const x = l.filter((X) => X.id !== c);
|
|
331
|
+
n(x, "delete", a);
|
|
332
|
+
};
|
|
333
|
+
re(() => {
|
|
334
|
+
let a;
|
|
335
|
+
const c = () => B(this, null, function* () {
|
|
336
|
+
a = new AbortController();
|
|
337
|
+
try {
|
|
338
|
+
const x = yield e(g, a.signal);
|
|
339
|
+
F(x != null ? x : []), P(!1);
|
|
340
|
+
} catch (x) {
|
|
341
|
+
if (x instanceof Error && x.name === "AbortError")
|
|
342
|
+
console.debug("Previous lookup request was cancelled");
|
|
343
|
+
else
|
|
344
|
+
throw x;
|
|
345
|
+
}
|
|
346
|
+
});
|
|
347
|
+
if (g !== "")
|
|
348
|
+
return (!r || g.length >= r) && !v ? (P(!0), c()) : P(!1), function() {
|
|
349
|
+
a && a.abort();
|
|
350
|
+
};
|
|
351
|
+
}, [g, e, r, v]), re(() => {
|
|
352
|
+
!y && !v && F([]), !y && v && F(v);
|
|
353
|
+
}, [y, v]);
|
|
354
|
+
const W = Et(() => v ? (a, c) => a.filter(
|
|
355
|
+
(x) => x.label.toLowerCase().includes(c.inputValue.toLowerCase())
|
|
356
|
+
) : (a) => a, [v]);
|
|
357
|
+
return /* @__PURE__ */ f("div", { "data-testid": d, children: [
|
|
340
358
|
/* @__PURE__ */ o(
|
|
341
|
-
|
|
359
|
+
Se,
|
|
342
360
|
{
|
|
343
|
-
sx:
|
|
344
|
-
"data-testid":
|
|
345
|
-
disablePortal:
|
|
361
|
+
sx: h,
|
|
362
|
+
"data-testid": d ? `${d}:Autocomplete` : void 0,
|
|
363
|
+
disablePortal: $,
|
|
346
364
|
multiple: !0,
|
|
347
|
-
getOptionLabel: (
|
|
348
|
-
|
|
349
|
-
|
|
365
|
+
getOptionLabel: (a) => typeof a == "string" ? a : a.label,
|
|
366
|
+
filterOptions: W,
|
|
367
|
+
loading: H,
|
|
368
|
+
options: [...l, ..._],
|
|
350
369
|
filterSelectedOptions: !0,
|
|
351
370
|
includeInputInList: !0,
|
|
352
|
-
value:
|
|
353
|
-
|
|
354
|
-
|
|
371
|
+
value: l,
|
|
372
|
+
onOpen: () => I(!0),
|
|
373
|
+
onClose: () => I(!1),
|
|
374
|
+
onChange: (a, c, x) => {
|
|
375
|
+
n(c, x, a);
|
|
355
376
|
},
|
|
356
|
-
onInputChange: (
|
|
377
|
+
onInputChange: (a, c) => m(c),
|
|
357
378
|
noOptionsText: b,
|
|
358
379
|
loadingText: w,
|
|
359
|
-
popupIcon:
|
|
360
|
-
renderInput: (
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
label:
|
|
380
|
+
popupIcon: A,
|
|
381
|
+
renderInput: (a) => /* @__PURE__ */ o(
|
|
382
|
+
De,
|
|
383
|
+
S(i({}, a), {
|
|
384
|
+
label: s,
|
|
364
385
|
fullWidth: !0,
|
|
365
|
-
variant:
|
|
386
|
+
variant: u,
|
|
366
387
|
error: C,
|
|
367
|
-
helperText:
|
|
368
|
-
InputProps:
|
|
369
|
-
endAdornment: /* @__PURE__ */
|
|
370
|
-
|
|
371
|
-
|
|
388
|
+
helperText: k,
|
|
389
|
+
InputProps: S(i({}, a.InputProps), {
|
|
390
|
+
endAdornment: /* @__PURE__ */ f(L, { children: [
|
|
391
|
+
H ? /* @__PURE__ */ o(ke, { color: "inherit", size: 20 }) : null,
|
|
392
|
+
a.InputProps.endAdornment
|
|
372
393
|
] })
|
|
373
394
|
}),
|
|
374
|
-
"data-testid":
|
|
375
|
-
onKeyDown: (
|
|
376
|
-
(
|
|
395
|
+
"data-testid": d ? `${d}:Autocomplete:TextField` : void 0,
|
|
396
|
+
onKeyDown: (c) => {
|
|
397
|
+
(c.key === "Backspace" || c.key === "Delete") && c.stopPropagation();
|
|
377
398
|
},
|
|
378
|
-
color:
|
|
399
|
+
color: p
|
|
379
400
|
})
|
|
380
401
|
),
|
|
381
402
|
renderTags: () => null,
|
|
382
|
-
isOptionEqualToValue: (
|
|
383
|
-
renderOption: (
|
|
403
|
+
isOptionEqualToValue: (a, c) => a.id === c.id,
|
|
404
|
+
renderOption: (a, c, x) => {
|
|
384
405
|
if (t) {
|
|
385
|
-
const
|
|
406
|
+
const X = Yt(c.label, x.inputValue, {
|
|
386
407
|
insideWords: !0,
|
|
387
408
|
findAllOccurrences: !0
|
|
388
|
-
}),
|
|
389
|
-
return /* @__PURE__ */
|
|
409
|
+
}), le = Jt(c.label, X);
|
|
410
|
+
return /* @__PURE__ */ xe(
|
|
390
411
|
"li",
|
|
391
|
-
|
|
392
|
-
key:
|
|
393
|
-
"data-testid":
|
|
412
|
+
S(i({}, a), {
|
|
413
|
+
key: c.id,
|
|
414
|
+
"data-testid": d ? `${d}:Autocomplete:option(${c.id.toString()})` : void 0
|
|
394
415
|
}),
|
|
395
|
-
/* @__PURE__ */ o("div", { children:
|
|
416
|
+
/* @__PURE__ */ o("div", { children: le.map((J, ce) => /* @__PURE__ */ o(
|
|
396
417
|
"span",
|
|
397
418
|
{
|
|
398
419
|
style: {
|
|
399
|
-
fontWeight:
|
|
420
|
+
fontWeight: J.highlight ? 700 : 400
|
|
400
421
|
},
|
|
401
|
-
children:
|
|
422
|
+
children: J.text
|
|
402
423
|
},
|
|
403
|
-
|
|
424
|
+
ce
|
|
404
425
|
)) })
|
|
405
426
|
);
|
|
406
427
|
} else
|
|
407
|
-
return /* @__PURE__ */
|
|
428
|
+
return /* @__PURE__ */ xe(
|
|
408
429
|
"li",
|
|
409
|
-
|
|
410
|
-
key:
|
|
411
|
-
"data-testid":
|
|
430
|
+
S(i({}, a), {
|
|
431
|
+
key: c.id,
|
|
432
|
+
"data-testid": d ? `${d}:option(${c.id.toString()})` : void 0
|
|
412
433
|
}),
|
|
413
|
-
|
|
434
|
+
c.label
|
|
414
435
|
);
|
|
415
436
|
}
|
|
416
437
|
}
|
|
417
438
|
),
|
|
418
|
-
|
|
419
|
-
|
|
439
|
+
l.length > 0 && /* @__PURE__ */ o(D, { children: l.map((a) => /* @__PURE__ */ o(
|
|
440
|
+
Pt,
|
|
420
441
|
{
|
|
421
442
|
sx: {
|
|
422
443
|
marginTop: 1,
|
|
@@ -424,9 +445,9 @@ function vo({
|
|
|
424
445
|
height: "auto"
|
|
425
446
|
},
|
|
426
447
|
label: /* @__PURE__ */ o(
|
|
427
|
-
|
|
448
|
+
Bt,
|
|
428
449
|
{
|
|
429
|
-
title:
|
|
450
|
+
title: a.tooltipContent || "",
|
|
430
451
|
placement: "bottom-start",
|
|
431
452
|
PopperProps: {
|
|
432
453
|
modifiers: [
|
|
@@ -438,114 +459,114 @@ function vo({
|
|
|
438
459
|
}
|
|
439
460
|
]
|
|
440
461
|
},
|
|
441
|
-
children: /* @__PURE__ */ o(
|
|
462
|
+
children: /* @__PURE__ */ o(T, { style: { whiteSpace: "normal" }, children: a.chipLabel ? a.chipLabel : a.label })
|
|
442
463
|
}
|
|
443
464
|
),
|
|
444
|
-
"data-testid":
|
|
445
|
-
onDelete: (
|
|
465
|
+
"data-testid": d ? `${d}:Chip(${a.id.toString()})` : void 0,
|
|
466
|
+
onDelete: (c) => R(c, a.id),
|
|
446
467
|
deleteIcon: /* @__PURE__ */ o(
|
|
447
|
-
|
|
468
|
+
jt,
|
|
448
469
|
{
|
|
449
|
-
"data-testid":
|
|
470
|
+
"data-testid": d ? `${d}:Chip(${a.id.toString()}):deleteIcon` : void 0
|
|
450
471
|
}
|
|
451
472
|
)
|
|
452
473
|
},
|
|
453
|
-
|
|
474
|
+
a.id
|
|
454
475
|
)) })
|
|
455
476
|
] });
|
|
456
477
|
}
|
|
457
|
-
const
|
|
478
|
+
const mo = ({
|
|
458
479
|
lookup: e,
|
|
459
480
|
onChange: t,
|
|
460
481
|
label: n,
|
|
461
|
-
value:
|
|
462
|
-
sx:
|
|
463
|
-
textFieldColor:
|
|
464
|
-
textFieldVariant:
|
|
465
|
-
"data-testid":
|
|
466
|
-
noOptionsText:
|
|
467
|
-
minLength:
|
|
482
|
+
value: r,
|
|
483
|
+
sx: s,
|
|
484
|
+
textFieldColor: l,
|
|
485
|
+
textFieldVariant: d = "filled",
|
|
486
|
+
"data-testid": h,
|
|
487
|
+
noOptionsText: p = "No options",
|
|
488
|
+
minLength: u = 3,
|
|
468
489
|
disablePortal: w = !1
|
|
469
490
|
}) => {
|
|
470
|
-
const [b,
|
|
471
|
-
let
|
|
472
|
-
const
|
|
473
|
-
|
|
491
|
+
const [b, A] = O([]), [C, k] = O(!1);
|
|
492
|
+
let v;
|
|
493
|
+
const $ = (g) => B(void 0, null, function* () {
|
|
494
|
+
v = new AbortController();
|
|
474
495
|
try {
|
|
475
|
-
const
|
|
476
|
-
|
|
477
|
-
} catch (
|
|
478
|
-
if (
|
|
496
|
+
const m = yield e(g, v.signal);
|
|
497
|
+
A(m != null ? m : []), k(!1);
|
|
498
|
+
} catch (m) {
|
|
499
|
+
if (m instanceof Error && m.name === "AbortError")
|
|
479
500
|
console.debug("Previous lookup request was cancelled");
|
|
480
501
|
else
|
|
481
|
-
throw
|
|
502
|
+
throw m;
|
|
482
503
|
}
|
|
483
504
|
});
|
|
484
|
-
return /* @__PURE__ */ o("div", { "data-testid":
|
|
485
|
-
|
|
505
|
+
return /* @__PURE__ */ o("div", { "data-testid": h, children: /* @__PURE__ */ o(Lt, { direction: "row", spacing: 1, children: /* @__PURE__ */ o(
|
|
506
|
+
Se,
|
|
486
507
|
{
|
|
487
|
-
sx:
|
|
488
|
-
"data-testid":
|
|
508
|
+
sx: s,
|
|
509
|
+
"data-testid": h ? `${h}:Autocomplete` : void 0,
|
|
489
510
|
loading: C,
|
|
490
511
|
options: b,
|
|
491
|
-
onChange: (
|
|
492
|
-
t(
|
|
512
|
+
onChange: (g, m) => {
|
|
513
|
+
t(g, m);
|
|
493
514
|
},
|
|
494
515
|
disablePortal: w,
|
|
495
|
-
filterOptions: (
|
|
496
|
-
value:
|
|
497
|
-
noOptionsText:
|
|
498
|
-
getOptionLabel: (
|
|
499
|
-
renderInput: (
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
"data-testid":
|
|
503
|
-
},
|
|
504
|
-
variant:
|
|
516
|
+
filterOptions: (g) => g,
|
|
517
|
+
value: r,
|
|
518
|
+
noOptionsText: p,
|
|
519
|
+
getOptionLabel: (g) => g.label,
|
|
520
|
+
renderInput: (g) => /* @__PURE__ */ o(
|
|
521
|
+
De,
|
|
522
|
+
S(i({
|
|
523
|
+
"data-testid": h ? `${h}:Autocomplete:TextField` : void 0
|
|
524
|
+
}, g), {
|
|
525
|
+
variant: d,
|
|
505
526
|
label: n,
|
|
506
|
-
color:
|
|
527
|
+
color: l
|
|
507
528
|
})
|
|
508
529
|
),
|
|
509
|
-
isOptionEqualToValue: (
|
|
510
|
-
onInputChange: (
|
|
511
|
-
(
|
|
530
|
+
isOptionEqualToValue: (g, m) => g.id === m.id,
|
|
531
|
+
onInputChange: (g, m) => {
|
|
532
|
+
(m == null ? void 0 : m.length) >= u && (k(!0), $(m));
|
|
512
533
|
},
|
|
513
|
-
renderOption: (
|
|
534
|
+
renderOption: (g, m) => /* @__PURE__ */ xe(
|
|
514
535
|
"li",
|
|
515
|
-
|
|
516
|
-
key:
|
|
517
|
-
"data-testid":
|
|
536
|
+
S(i({}, g), {
|
|
537
|
+
key: m.id,
|
|
538
|
+
"data-testid": h ? `${h}:Autocomplete:option(${m.id.toString()})` : void 0
|
|
518
539
|
}),
|
|
519
|
-
|
|
540
|
+
m.label
|
|
520
541
|
)
|
|
521
542
|
}
|
|
522
543
|
) }) });
|
|
523
|
-
},
|
|
524
|
-
topStripe: `${
|
|
525
|
-
titleBar: `${
|
|
526
|
-
titleSlider: `${
|
|
527
|
-
titleText: `${
|
|
528
|
-
leftPanelButton: `${
|
|
529
|
-
rightPanelButton: `${
|
|
530
|
-
},
|
|
544
|
+
}, pn = 24, un = 64, U = "TopBar", E = {
|
|
545
|
+
topStripe: `${U}-topStripe`,
|
|
546
|
+
titleBar: `${U}-titleBar`,
|
|
547
|
+
titleSlider: `${U}-titleSlider`,
|
|
548
|
+
titleText: `${U}-titleText`,
|
|
549
|
+
leftPanelButton: `${U}-leftPanelButton`,
|
|
550
|
+
rightPanelButton: `${U}-leftPanelButton`
|
|
551
|
+
}, hn = Oe("div", {
|
|
531
552
|
shouldForwardProp: (e) => !["leftPanel", "rightPanel"].includes(e),
|
|
532
|
-
name:
|
|
553
|
+
name: U
|
|
533
554
|
})(({ theme: e, leftPanel: t, rightPanel: n }) => {
|
|
534
|
-
var
|
|
555
|
+
var r, s;
|
|
535
556
|
return {
|
|
536
557
|
width: "100%",
|
|
537
|
-
[`& .${
|
|
558
|
+
[`& .${E.topStripe}`]: {
|
|
538
559
|
width: "100%",
|
|
539
|
-
height: `${
|
|
560
|
+
height: `${pn}px`,
|
|
540
561
|
backgroundColor: e.palette.primary.main
|
|
541
562
|
},
|
|
542
|
-
[`& .${
|
|
563
|
+
[`& .${E.titleBar}`]: {
|
|
543
564
|
backgroundColor: e.palette.primary.light,
|
|
544
|
-
height: `${
|
|
565
|
+
height: `${un}px`,
|
|
545
566
|
padding: e.spacing(0, 3),
|
|
546
567
|
width: "100%"
|
|
547
568
|
},
|
|
548
|
-
[`& .${
|
|
569
|
+
[`& .${E.titleSlider}`]: i(i({
|
|
549
570
|
height: "100%",
|
|
550
571
|
display: "flex",
|
|
551
572
|
alignItems: "center",
|
|
@@ -554,14 +575,14 @@ const xo = ({
|
|
|
554
575
|
easing: e.transitions.easing.sharp,
|
|
555
576
|
duration: e.transitions.duration.leavingScreen
|
|
556
577
|
}),
|
|
557
|
-
[`& .${
|
|
578
|
+
[`& .${E.leftPanelButton}`]: {
|
|
558
579
|
marginRight: e.spacing(2),
|
|
559
580
|
flexGrow: 0
|
|
560
581
|
},
|
|
561
|
-
[`& .${
|
|
582
|
+
[`& .${E.titleText}`]: {
|
|
562
583
|
flexGrow: 1
|
|
563
584
|
},
|
|
564
|
-
[`& .${
|
|
585
|
+
[`& .${E.rightPanelButton}`]: {
|
|
565
586
|
flexGrow: 0
|
|
566
587
|
}
|
|
567
588
|
}, (t == null ? void 0 : t.open) && {
|
|
@@ -569,29 +590,29 @@ const xo = ({
|
|
|
569
590
|
easing: e.transitions.easing.easeOut,
|
|
570
591
|
duration: e.transitions.duration.enteringScreen
|
|
571
592
|
}),
|
|
572
|
-
marginLeft: `${(
|
|
593
|
+
marginLeft: `${(r = t == null ? void 0 : t.width) != null ? r : 0}px`
|
|
573
594
|
}), (n == null ? void 0 : n.open) && {
|
|
574
595
|
transition: e.transitions.create("margin", {
|
|
575
596
|
easing: e.transitions.easing.easeOut,
|
|
576
597
|
duration: e.transitions.duration.enteringScreen
|
|
577
598
|
}),
|
|
578
|
-
marginRight: `${(
|
|
599
|
+
marginRight: `${(s = n == null ? void 0 : n.width) != null ? s : 0}px`
|
|
579
600
|
})
|
|
580
601
|
};
|
|
581
602
|
});
|
|
582
|
-
function
|
|
603
|
+
function gn({
|
|
583
604
|
titleText: e = "",
|
|
584
605
|
leftPanel: t,
|
|
585
606
|
rightPanel: n,
|
|
586
|
-
"data-testid":
|
|
607
|
+
"data-testid": r
|
|
587
608
|
}) {
|
|
588
|
-
return /* @__PURE__ */
|
|
589
|
-
/* @__PURE__ */ o("div", { className:
|
|
590
|
-
/* @__PURE__ */ o("div", { className:
|
|
591
|
-
t !== void 0 && !t.open && t.showOpenArrow && /* @__PURE__ */
|
|
609
|
+
return /* @__PURE__ */ f(hn, { leftPanel: t, rightPanel: n, "data-testid": r, children: [
|
|
610
|
+
/* @__PURE__ */ o("div", { className: E.topStripe }),
|
|
611
|
+
/* @__PURE__ */ o("div", { className: E.titleBar, children: /* @__PURE__ */ f(D, { className: E.titleSlider, children: [
|
|
612
|
+
t !== void 0 && !t.open && t.showOpenArrow && /* @__PURE__ */ f(
|
|
592
613
|
Q,
|
|
593
614
|
{
|
|
594
|
-
className:
|
|
615
|
+
className: E.leftPanelButton,
|
|
595
616
|
color: "inherit",
|
|
596
617
|
"aria-label": "Open left side panel",
|
|
597
618
|
onClick: t == null ? void 0 : t.onOpen,
|
|
@@ -599,15 +620,15 @@ function mn({
|
|
|
599
620
|
size: "large",
|
|
600
621
|
children: [
|
|
601
622
|
" ",
|
|
602
|
-
/* @__PURE__ */ o(
|
|
623
|
+
/* @__PURE__ */ o(ot, {})
|
|
603
624
|
]
|
|
604
625
|
}
|
|
605
626
|
),
|
|
606
|
-
/* @__PURE__ */ o(
|
|
607
|
-
n !== void 0 && !n.open && n.showOpenArrow && /* @__PURE__ */
|
|
627
|
+
/* @__PURE__ */ o(T, { className: E.titleText, variant: "h6", noWrap: !0, children: e }),
|
|
628
|
+
n !== void 0 && !n.open && n.showOpenArrow && /* @__PURE__ */ f(
|
|
608
629
|
Q,
|
|
609
630
|
{
|
|
610
|
-
className:
|
|
631
|
+
className: E.rightPanelButton,
|
|
611
632
|
color: "inherit",
|
|
612
633
|
"aria-label": "Open right side panel",
|
|
613
634
|
onClick: n == null ? void 0 : n.onOpen,
|
|
@@ -615,14 +636,14 @@ function mn({
|
|
|
615
636
|
size: "large",
|
|
616
637
|
children: [
|
|
617
638
|
" ",
|
|
618
|
-
/* @__PURE__ */ o(
|
|
639
|
+
/* @__PURE__ */ o(rt, {})
|
|
619
640
|
]
|
|
620
641
|
}
|
|
621
642
|
)
|
|
622
643
|
] }) })
|
|
623
644
|
] });
|
|
624
645
|
}
|
|
625
|
-
const
|
|
646
|
+
const ut = 400, fn = Oe(Ae, {
|
|
626
647
|
shouldForwardProp: (e) => (
|
|
627
648
|
// Note we do want anchor to be forwarded to the Drawer component
|
|
628
649
|
![
|
|
@@ -636,9 +657,9 @@ const lt = 400, Cn = be(Ce, {
|
|
|
636
657
|
),
|
|
637
658
|
name: "SidePanelDrawer"
|
|
638
659
|
})(
|
|
639
|
-
({ width: e, debugOpacity: t = !1, anchor: n, navBarOpen:
|
|
660
|
+
({ width: e, debugOpacity: t = !1, anchor: n, navBarOpen: r, navBarWidthOpen: s, navBarWidthClosed: l }) => ({
|
|
640
661
|
width: e,
|
|
641
|
-
"& .MuiDrawer-paper":
|
|
662
|
+
"& .MuiDrawer-paper": i(i({
|
|
642
663
|
position: "absolute",
|
|
643
664
|
width: e,
|
|
644
665
|
boxSizing: "border-box",
|
|
@@ -646,15 +667,15 @@ const lt = 400, Cn = be(Ce, {
|
|
|
646
667
|
boxShadow: "0px 4px 5px rgba(0, 0, 0, 0.14), 0px 1px 10px rgba(0, 0, 0, 0.12), 0px 2px 4px rgba(0, 0, 0, 0.2)"
|
|
647
668
|
}, t && {
|
|
648
669
|
opacity: "50%"
|
|
649
|
-
}), n === "left" &&
|
|
670
|
+
}), n === "left" && i({
|
|
671
|
+
marginLeft: `${l}px`
|
|
672
|
+
}, r && {
|
|
650
673
|
marginLeft: `${s}px`
|
|
651
|
-
}, i && {
|
|
652
|
-
marginLeft: `${a}px`
|
|
653
674
|
}))
|
|
654
675
|
})
|
|
655
|
-
),
|
|
676
|
+
), mn = Oe(D, {
|
|
656
677
|
shouldForwardProp: (e) => !["anchor"].includes(e)
|
|
657
|
-
})(({ theme: e, anchor: t }) =>
|
|
678
|
+
})(({ theme: e, anchor: t }) => S(i({
|
|
658
679
|
display: "flex",
|
|
659
680
|
alignItems: "center",
|
|
660
681
|
padding: e.spacing(2)
|
|
@@ -672,65 +693,65 @@ const lt = 400, Cn = be(Ce, {
|
|
|
672
693
|
marginRight: t === "right" ? e.spacing(2) : 0
|
|
673
694
|
}
|
|
674
695
|
}));
|
|
675
|
-
function
|
|
696
|
+
function ze({
|
|
676
697
|
children: e,
|
|
677
698
|
anchor: t = "left",
|
|
678
699
|
open: n,
|
|
679
|
-
onClose:
|
|
700
|
+
onClose: r = () => {
|
|
680
701
|
},
|
|
681
|
-
titleText:
|
|
682
|
-
width:
|
|
683
|
-
showCloseArrow:
|
|
684
|
-
debugOpacity:
|
|
685
|
-
headerBoxProps:
|
|
686
|
-
onOpened:
|
|
702
|
+
titleText: s = "",
|
|
703
|
+
width: l = ut,
|
|
704
|
+
showCloseArrow: d = !0,
|
|
705
|
+
debugOpacity: h = !1,
|
|
706
|
+
headerBoxProps: p = {},
|
|
707
|
+
onOpened: u,
|
|
687
708
|
onClosed: w,
|
|
688
709
|
"data-testid": b,
|
|
689
|
-
navBarOpen:
|
|
710
|
+
navBarOpen: A = !1,
|
|
690
711
|
navBarWidthOpen: C = 0,
|
|
691
|
-
navBarWidthClosed:
|
|
712
|
+
navBarWidthClosed: k = 0
|
|
692
713
|
}) {
|
|
693
|
-
return /* @__PURE__ */
|
|
694
|
-
|
|
714
|
+
return /* @__PURE__ */ f(
|
|
715
|
+
fn,
|
|
695
716
|
{
|
|
696
717
|
SlideProps: {
|
|
697
|
-
onEntered: () =>
|
|
718
|
+
onEntered: () => u == null ? void 0 : u(),
|
|
698
719
|
onExited: () => w == null ? void 0 : w()
|
|
699
720
|
},
|
|
700
721
|
variant: "persistent",
|
|
701
722
|
anchor: t,
|
|
702
723
|
open: n,
|
|
703
|
-
width:
|
|
704
|
-
debugOpacity:
|
|
724
|
+
width: l,
|
|
725
|
+
debugOpacity: h,
|
|
705
726
|
"data-testid": b,
|
|
706
|
-
navBarOpen:
|
|
727
|
+
navBarOpen: A,
|
|
707
728
|
navBarWidthOpen: C,
|
|
708
|
-
navBarWidthClosed:
|
|
729
|
+
navBarWidthClosed: k,
|
|
709
730
|
children: [
|
|
710
|
-
/* @__PURE__ */ o(
|
|
711
|
-
/* @__PURE__ */ o(
|
|
712
|
-
|
|
713
|
-
/* @__PURE__ */ o(
|
|
731
|
+
/* @__PURE__ */ o(mn, S(i({ anchor: t }, p), { children: t === "left" ? /* @__PURE__ */ f(L, { children: [
|
|
732
|
+
/* @__PURE__ */ o(T, { variant: "h6", color: "inherit", component: "div", children: s }),
|
|
733
|
+
d && /* @__PURE__ */ f(Q, { onClick: r, size: "large", "aria-label": "Close left side panel", children: [
|
|
734
|
+
/* @__PURE__ */ o(rt, { "data-testid": "arrowbackicon" }),
|
|
714
735
|
" "
|
|
715
736
|
] })
|
|
716
|
-
] }) : /* @__PURE__ */
|
|
717
|
-
|
|
718
|
-
/* @__PURE__ */ o(
|
|
737
|
+
] }) : /* @__PURE__ */ f(L, { children: [
|
|
738
|
+
d && /* @__PURE__ */ f(Q, { onClick: r, size: "large", "aria-label": "Close right side panel", children: [
|
|
739
|
+
/* @__PURE__ */ o(ot, {}),
|
|
719
740
|
" "
|
|
720
741
|
] }),
|
|
721
|
-
/* @__PURE__ */ o(
|
|
742
|
+
/* @__PURE__ */ o(T, { variant: "h6", color: "inherit", component: "div", children: s })
|
|
722
743
|
] }) })),
|
|
723
744
|
e
|
|
724
745
|
]
|
|
725
746
|
}
|
|
726
747
|
);
|
|
727
748
|
}
|
|
728
|
-
const
|
|
749
|
+
const Cn = M(D, {
|
|
729
750
|
shouldForwardProp: (e) => !["leftPanel", "rightPanel"].includes(e),
|
|
730
751
|
name: "PanelAwareMargins"
|
|
731
752
|
})(({ theme: e, leftPanel: t, rightPanel: n }) => {
|
|
732
|
-
var
|
|
733
|
-
return
|
|
753
|
+
var r, s;
|
|
754
|
+
return i(i({
|
|
734
755
|
transition: e.transitions.create("margin", {
|
|
735
756
|
easing: e.transitions.easing.sharp,
|
|
736
757
|
duration: e.transitions.duration.leavingScreen
|
|
@@ -740,25 +761,25 @@ const xn = M(k, {
|
|
|
740
761
|
easing: e.transitions.easing.easeOut,
|
|
741
762
|
duration: e.transitions.duration.enteringScreen
|
|
742
763
|
}),
|
|
743
|
-
marginLeft: `${(
|
|
764
|
+
marginLeft: `${(r = t == null ? void 0 : t.width) != null ? r : 0}px`
|
|
744
765
|
}), (n == null ? void 0 : n.open) && {
|
|
745
766
|
transition: e.transitions.create("margin", {
|
|
746
767
|
easing: e.transitions.easing.easeOut,
|
|
747
768
|
duration: e.transitions.duration.enteringScreen
|
|
748
769
|
}),
|
|
749
|
-
marginRight: `${(
|
|
770
|
+
marginRight: `${(s = n == null ? void 0 : n.width) != null ? s : 0}px`
|
|
750
771
|
});
|
|
751
|
-
}),
|
|
772
|
+
}), vn = M(et, {
|
|
752
773
|
name: "PageContainer"
|
|
753
774
|
})(({ theme: e }) => ({
|
|
754
775
|
// Horizontal padding comes from the Container's gutter
|
|
755
776
|
paddingTop: e.spacing(3),
|
|
756
777
|
paddingBottom: e.spacing(3)
|
|
757
778
|
// TODO: Remove max width
|
|
758
|
-
})),
|
|
779
|
+
})), Ce = !1, ve = !1, te = {
|
|
759
780
|
titleText: "",
|
|
760
781
|
flavour: "push",
|
|
761
|
-
width:
|
|
782
|
+
width: ut,
|
|
762
783
|
arrowButtons: "both",
|
|
763
784
|
startOpen: !1,
|
|
764
785
|
open: void 0,
|
|
@@ -768,159 +789,159 @@ const xn = M(k, {
|
|
|
768
789
|
onClosed: void 0,
|
|
769
790
|
dataTestId: void 0
|
|
770
791
|
};
|
|
771
|
-
function
|
|
792
|
+
function Co({
|
|
772
793
|
children: e,
|
|
773
794
|
titleText: t = "",
|
|
774
795
|
leftPanel: n,
|
|
775
|
-
rightPanel:
|
|
776
|
-
sidePanelsAreMutuallyExclusive:
|
|
777
|
-
debugOpacity:
|
|
778
|
-
pageContainerProps:
|
|
779
|
-
pageContentDataTestId:
|
|
780
|
-
topBarDataTestId:
|
|
781
|
-
navBarOpen:
|
|
796
|
+
rightPanel: r,
|
|
797
|
+
sidePanelsAreMutuallyExclusive: s = !0,
|
|
798
|
+
debugOpacity: l = !1,
|
|
799
|
+
pageContainerProps: d,
|
|
800
|
+
pageContentDataTestId: h,
|
|
801
|
+
topBarDataTestId: p,
|
|
802
|
+
navBarOpen: u,
|
|
782
803
|
navBarWidthOpen: w,
|
|
783
804
|
navBarWidthClosed: b
|
|
784
805
|
}) {
|
|
785
|
-
const [
|
|
786
|
-
titleText:
|
|
787
|
-
content:
|
|
788
|
-
flavour:
|
|
789
|
-
open:
|
|
790
|
-
onChangeOpen:
|
|
791
|
-
width:
|
|
792
|
-
arrowButtons:
|
|
793
|
-
startOpen:
|
|
794
|
-
onOpened:
|
|
795
|
-
onClosed:
|
|
796
|
-
dataTestId:
|
|
797
|
-
} = n ?
|
|
798
|
-
titleText:
|
|
806
|
+
const [A, C] = O(Ce), [k, v] = O(ve), [$, g] = O(Ce), [m, _] = O(ve), F = n !== void 0, y = r !== void 0, {
|
|
807
|
+
titleText: I,
|
|
808
|
+
content: H,
|
|
809
|
+
flavour: P,
|
|
810
|
+
open: R,
|
|
811
|
+
onChangeOpen: W,
|
|
812
|
+
width: a,
|
|
813
|
+
arrowButtons: c,
|
|
814
|
+
startOpen: x,
|
|
815
|
+
onOpened: X,
|
|
816
|
+
onClosed: le,
|
|
817
|
+
dataTestId: J
|
|
818
|
+
} = n ? i(i({}, te), n) : i({}, te), {
|
|
819
|
+
titleText: ce,
|
|
799
820
|
content: At,
|
|
800
|
-
flavour:
|
|
801
|
-
open:
|
|
802
|
-
onChangeOpen:
|
|
803
|
-
width:
|
|
804
|
-
arrowButtons:
|
|
805
|
-
startOpen:
|
|
821
|
+
flavour: Ie,
|
|
822
|
+
open: de,
|
|
823
|
+
onChangeOpen: Ee,
|
|
824
|
+
width: pe,
|
|
825
|
+
arrowButtons: Y,
|
|
826
|
+
startOpen: Z,
|
|
806
827
|
onOpened: St,
|
|
807
828
|
onClosed: Dt,
|
|
808
829
|
dataTestId: kt
|
|
809
|
-
} =
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
}, [
|
|
813
|
-
|
|
814
|
-
}, [
|
|
815
|
-
const
|
|
816
|
-
|
|
817
|
-
},
|
|
818
|
-
|
|
830
|
+
} = r ? i(i({}, te), r) : i({}, te);
|
|
831
|
+
re(() => {
|
|
832
|
+
x !== Ce && (C(x), g(x));
|
|
833
|
+
}, [x]), re(() => {
|
|
834
|
+
Z !== ve && (v(Z), _(Z));
|
|
835
|
+
}, [Z]);
|
|
836
|
+
const ue = R === void 0 ? A : R, he = de === void 0 ? k : de, Te = (z) => {
|
|
837
|
+
R === void 0 && (C(z), s && y && (z ? (v(!1), _(k)) : v(m))), W && W(z);
|
|
838
|
+
}, Fe = (z) => {
|
|
839
|
+
de === void 0 && (v(z), s && F && (z ? (C(!1), g(A)) : C($))), Ee && Ee(z);
|
|
819
840
|
};
|
|
820
|
-
return /* @__PURE__ */
|
|
841
|
+
return /* @__PURE__ */ f(D, { children: [
|
|
821
842
|
F && /* @__PURE__ */ o(
|
|
822
|
-
|
|
843
|
+
ze,
|
|
823
844
|
{
|
|
824
|
-
"data-testid":
|
|
845
|
+
"data-testid": J,
|
|
825
846
|
anchor: "left",
|
|
826
|
-
open:
|
|
827
|
-
onClose: () =>
|
|
828
|
-
width:
|
|
829
|
-
titleText:
|
|
830
|
-
debugOpacity:
|
|
831
|
-
showCloseArrow:
|
|
832
|
-
onOpened:
|
|
833
|
-
onClosed:
|
|
834
|
-
navBarOpen:
|
|
847
|
+
open: ue,
|
|
848
|
+
onClose: () => Te(!1),
|
|
849
|
+
width: a,
|
|
850
|
+
titleText: I,
|
|
851
|
+
debugOpacity: l,
|
|
852
|
+
showCloseArrow: c === "both" || c === "close",
|
|
853
|
+
onOpened: X,
|
|
854
|
+
onClosed: le,
|
|
855
|
+
navBarOpen: u,
|
|
835
856
|
navBarWidthOpen: w,
|
|
836
857
|
navBarWidthClosed: b,
|
|
837
|
-
children:
|
|
858
|
+
children: H
|
|
838
859
|
}
|
|
839
860
|
),
|
|
840
|
-
|
|
841
|
-
|
|
861
|
+
y && /* @__PURE__ */ o(
|
|
862
|
+
ze,
|
|
842
863
|
{
|
|
843
864
|
"data-testid": kt,
|
|
844
865
|
anchor: "right",
|
|
845
|
-
open:
|
|
846
|
-
onClose: () =>
|
|
847
|
-
width:
|
|
848
|
-
titleText:
|
|
849
|
-
debugOpacity:
|
|
850
|
-
showCloseArrow:
|
|
866
|
+
open: he,
|
|
867
|
+
onClose: () => Fe(!1),
|
|
868
|
+
width: pe,
|
|
869
|
+
titleText: ce,
|
|
870
|
+
debugOpacity: l,
|
|
871
|
+
showCloseArrow: Y === "both" || Y === "close",
|
|
851
872
|
onOpened: St,
|
|
852
873
|
onClosed: Dt,
|
|
853
|
-
navBarOpen:
|
|
874
|
+
navBarOpen: u,
|
|
854
875
|
navBarWidthOpen: w,
|
|
855
876
|
navBarWidthClosed: b,
|
|
856
877
|
children: At
|
|
857
878
|
}
|
|
858
879
|
),
|
|
859
880
|
/* @__PURE__ */ o(
|
|
860
|
-
|
|
861
|
-
|
|
881
|
+
gn,
|
|
882
|
+
i(i({
|
|
862
883
|
titleText: t,
|
|
863
|
-
"data-testid":
|
|
864
|
-
}, F &&
|
|
884
|
+
"data-testid": p
|
|
885
|
+
}, F && P === "push" ? {
|
|
865
886
|
leftPanel: {
|
|
866
|
-
open:
|
|
867
|
-
width:
|
|
868
|
-
onOpen: () =>
|
|
869
|
-
showOpenArrow:
|
|
887
|
+
open: ue,
|
|
888
|
+
width: a,
|
|
889
|
+
onOpen: () => Te(!0),
|
|
890
|
+
showOpenArrow: c === "both" || c === "open"
|
|
870
891
|
}
|
|
871
|
-
} : {}),
|
|
892
|
+
} : {}), y && Ie === "push" ? {
|
|
872
893
|
rightPanel: {
|
|
873
|
-
open:
|
|
874
|
-
width:
|
|
875
|
-
onOpen: () =>
|
|
876
|
-
showOpenArrow:
|
|
894
|
+
open: he,
|
|
895
|
+
width: pe,
|
|
896
|
+
onOpen: () => Fe(!0),
|
|
897
|
+
showOpenArrow: Y === "both" || Y === "open"
|
|
877
898
|
}
|
|
878
899
|
} : {})
|
|
879
900
|
),
|
|
880
901
|
/* @__PURE__ */ o(
|
|
881
|
-
|
|
882
|
-
|
|
902
|
+
Cn,
|
|
903
|
+
S(i(i({}, P === "push" ? {
|
|
883
904
|
leftPanel: {
|
|
884
|
-
open:
|
|
885
|
-
width:
|
|
905
|
+
open: ue,
|
|
906
|
+
width: a
|
|
886
907
|
}
|
|
887
|
-
} : {}),
|
|
908
|
+
} : {}), Ie === "push" ? {
|
|
888
909
|
rightPanel: {
|
|
889
|
-
open:
|
|
890
|
-
width:
|
|
910
|
+
open: he,
|
|
911
|
+
width: pe
|
|
891
912
|
}
|
|
892
913
|
} : {}), {
|
|
893
|
-
children: /* @__PURE__ */ o(
|
|
914
|
+
children: /* @__PURE__ */ o(vn, S(i({ "data-testid": h }, d), { children: e }))
|
|
894
915
|
})
|
|
895
916
|
)
|
|
896
917
|
] });
|
|
897
918
|
}
|
|
898
|
-
const
|
|
899
|
-
const e =
|
|
900
|
-
return
|
|
901
|
-
},
|
|
902
|
-
function
|
|
919
|
+
const ht = () => {
|
|
920
|
+
const e = ae();
|
|
921
|
+
return Mt(e.breakpoints.down("sm"));
|
|
922
|
+
}, xn = 64, wn = 64, bn = 256, K = N(!0), gt = N(bn), ft = N(wn), be = N(""), An = N(void 0), mt = N(xn), Ct = N(void 0);
|
|
923
|
+
function Sn({ links: e }) {
|
|
903
924
|
return /* @__PURE__ */ o("div", { children: "LinksMenu not implemented yet" });
|
|
904
925
|
}
|
|
905
|
-
const
|
|
906
|
-
root: `${
|
|
907
|
-
menuButton: `${
|
|
908
|
-
hide: `${
|
|
909
|
-
content: `${
|
|
926
|
+
const ne = "Navbar", j = {
|
|
927
|
+
root: `${ne}-root`,
|
|
928
|
+
menuButton: `${ne}-menuButton`,
|
|
929
|
+
hide: `${ne}-hide`,
|
|
930
|
+
content: `${ne}-content`
|
|
910
931
|
// userInfoHolder: `${PREFIX}-userInfoHolder`,
|
|
911
932
|
// settings: `${PREFIX}-settings`,
|
|
912
933
|
// pieChartIcon: `${PREFIX}-pieChartIcon`,
|
|
913
|
-
},
|
|
914
|
-
[`&.${
|
|
934
|
+
}, Dn = M(D, { name: "NavBar" })(({ theme: e }) => ({
|
|
935
|
+
[`&.${j.root}`]: {
|
|
915
936
|
display: "flex"
|
|
916
937
|
},
|
|
917
|
-
[`& .${
|
|
938
|
+
[`& .${j.menuButton}`]: {
|
|
918
939
|
marginRight: 36
|
|
919
940
|
},
|
|
920
|
-
[`& .${
|
|
941
|
+
[`& .${j.hide}`]: {
|
|
921
942
|
display: "none"
|
|
922
943
|
},
|
|
923
|
-
[`& .${
|
|
944
|
+
[`& .${j.content}`]: {
|
|
924
945
|
flexGrow: 1,
|
|
925
946
|
padding: e.spacing(3)
|
|
926
947
|
}
|
|
@@ -929,14 +950,14 @@ const te = "Navbar", X = {
|
|
|
929
950
|
// marginTop: '64px',
|
|
930
951
|
// marginBottom: '16px',
|
|
931
952
|
// },
|
|
932
|
-
})),
|
|
953
|
+
})), ie = (e, t, n) => e.transitions.create(t, {
|
|
933
954
|
easing: e.transitions.easing.sharp,
|
|
934
955
|
duration: n === "leaving" ? e.transitions.duration.leavingScreen : e.transitions.duration.enteringScreen
|
|
935
|
-
}),
|
|
936
|
-
const t =
|
|
956
|
+
}), kn = (e) => {
|
|
957
|
+
const t = ae();
|
|
937
958
|
return /* @__PURE__ */ o(
|
|
938
|
-
|
|
939
|
-
|
|
959
|
+
_t,
|
|
960
|
+
i({
|
|
940
961
|
easing: t.transitions.easing.sharp,
|
|
941
962
|
timeout: {
|
|
942
963
|
enter: t.transitions.duration.enteringScreen,
|
|
@@ -944,7 +965,7 @@ const te = "Navbar", X = {
|
|
|
944
965
|
}
|
|
945
966
|
}, e)
|
|
946
967
|
);
|
|
947
|
-
},
|
|
968
|
+
}, vt = (e) => {
|
|
948
969
|
var t, n;
|
|
949
970
|
return {
|
|
950
971
|
overflowX: "hidden",
|
|
@@ -952,40 +973,40 @@ const te = "Navbar", X = {
|
|
|
952
973
|
backgroundColor: (n = (t = e == null ? void 0 : e.navBar) == null ? void 0 : t.backgroundColor) != null ? n : "white"
|
|
953
974
|
// Provide default so tests don't need to wrap theme provider
|
|
954
975
|
};
|
|
955
|
-
},
|
|
976
|
+
}, Ge = (e, t) => i({
|
|
956
977
|
width: t,
|
|
957
|
-
transition:
|
|
958
|
-
},
|
|
978
|
+
transition: ie(e, "width", "entering")
|
|
979
|
+
}, vt(e)), Ue = (e, t) => i({
|
|
959
980
|
width: t,
|
|
960
|
-
transition:
|
|
961
|
-
},
|
|
981
|
+
transition: ie(e, "width", "leaving")
|
|
982
|
+
}, vt(e)), On = M(Ae, {
|
|
962
983
|
shouldForwardProp: (e) => !["widthOpen", "widthClosed", "isSmallScreen"].includes(e)
|
|
963
|
-
})(({ theme: e, open: t, widthOpen: n, widthClosed:
|
|
984
|
+
})(({ theme: e, open: t, widthOpen: n, widthClosed: r, isSmallScreen: s }) => i(i({
|
|
964
985
|
flexShrink: 0,
|
|
965
986
|
whiteSpace: "nowrap",
|
|
966
987
|
boxSizing: "border-box",
|
|
967
988
|
display: "flex",
|
|
968
989
|
flexDirection: "column"
|
|
969
|
-
}, t &&
|
|
990
|
+
}, t && S(i({}, Ge(e, n)), {
|
|
970
991
|
backgroundColor: "",
|
|
971
|
-
"& .MuiDrawer-paper":
|
|
972
|
-
})), !t &&
|
|
992
|
+
"& .MuiDrawer-paper": Ge(e, n)
|
|
993
|
+
})), !t && S(i({}, Ue(e, s ? n : r)), {
|
|
973
994
|
backgroundColor: "",
|
|
974
|
-
"& .MuiDrawer-paper":
|
|
995
|
+
"& .MuiDrawer-paper": Ue(e, s ? n : r)
|
|
975
996
|
})));
|
|
976
|
-
function
|
|
997
|
+
function $n(e) {
|
|
977
998
|
let t = 0;
|
|
978
|
-
for (let n = 0,
|
|
979
|
-
const
|
|
980
|
-
t = (t << 5) - t +
|
|
999
|
+
for (let n = 0, r = e.length; n < r; n++) {
|
|
1000
|
+
const s = e.charCodeAt(n);
|
|
1001
|
+
t = (t << 5) - t + s, t |= 0;
|
|
981
1002
|
}
|
|
982
1003
|
return t;
|
|
983
1004
|
}
|
|
984
|
-
const
|
|
1005
|
+
const Ve = ["#A62A21", "#7e3794", "#0B51C1", "#3A6024", "#A81563", "#B3003C"], In = (e) => e.split(/\s/).map((t) => t.substring(0, 1).toUpperCase()).filter((t) => !!t).slice(0, 2).join("").toUpperCase();
|
|
985
1006
|
function En({ user: e, domainCode: t, open: n }) {
|
|
986
|
-
const
|
|
987
|
-
return /* @__PURE__ */
|
|
988
|
-
|
|
1007
|
+
const r = ae();
|
|
1008
|
+
return /* @__PURE__ */ f(
|
|
1009
|
+
D,
|
|
989
1010
|
{
|
|
990
1011
|
sx: {
|
|
991
1012
|
paddingTop: 3,
|
|
@@ -996,85 +1017,85 @@ function En({ user: e, domainCode: t, open: n }) {
|
|
|
996
1017
|
},
|
|
997
1018
|
children: [
|
|
998
1019
|
/* @__PURE__ */ o(
|
|
999
|
-
|
|
1020
|
+
D,
|
|
1000
1021
|
{
|
|
1001
1022
|
sx: {
|
|
1002
1023
|
width: n ? "5rem" : "2rem",
|
|
1003
|
-
transition: n ?
|
|
1024
|
+
transition: n ? ie(r, ["width", "height"], "entering") : ie(r, ["width", "height"], "leaving"),
|
|
1004
1025
|
aspectRatio: 1
|
|
1005
1026
|
},
|
|
1006
1027
|
children: e != null && e.name ? /* @__PURE__ */ o(
|
|
1007
|
-
|
|
1028
|
+
Le,
|
|
1008
1029
|
{
|
|
1009
1030
|
src: e == null ? void 0 : e.picture,
|
|
1010
1031
|
sx: {
|
|
1011
1032
|
width: "100%",
|
|
1012
1033
|
height: "100%",
|
|
1013
|
-
bgcolor:
|
|
1034
|
+
bgcolor: Ve[Math.abs($n(e.name)) % Ve.length]
|
|
1014
1035
|
},
|
|
1015
|
-
children:
|
|
1036
|
+
children: In(e.name)
|
|
1016
1037
|
}
|
|
1017
|
-
) : /* @__PURE__ */ o(
|
|
1038
|
+
) : /* @__PURE__ */ o(Le, { sx: { width: "100%", height: "100%" } })
|
|
1018
1039
|
}
|
|
1019
1040
|
),
|
|
1020
|
-
/* @__PURE__ */ o(
|
|
1021
|
-
e != null && e.name ? /* @__PURE__ */ o(
|
|
1022
|
-
t ? /* @__PURE__ */ o(
|
|
1041
|
+
/* @__PURE__ */ o(kn, { sx: { width: "100%" }, in: n, children: /* @__PURE__ */ o(Ht, { in: n, children: /* @__PURE__ */ f(D, { width: "100%", display: "flex", flexDirection: "column", alignItems: "center", children: [
|
|
1042
|
+
e != null && e.name ? /* @__PURE__ */ o(T, { children: e.name }) : /* @__PURE__ */ o(Me, { animation: !1, width: "50%" }),
|
|
1043
|
+
t ? /* @__PURE__ */ o(T, { children: t.toUpperCase() }) : /* @__PURE__ */ o(Me, { animation: !1, width: "25%" })
|
|
1023
1044
|
] }) }) })
|
|
1024
1045
|
]
|
|
1025
1046
|
}
|
|
1026
1047
|
);
|
|
1027
1048
|
}
|
|
1028
|
-
function
|
|
1049
|
+
function Tn({
|
|
1029
1050
|
open: e,
|
|
1030
1051
|
widthClosed: t,
|
|
1031
1052
|
widthOpen: n,
|
|
1032
|
-
"data-testid":
|
|
1033
|
-
top:
|
|
1034
|
-
middle:
|
|
1035
|
-
bottom:
|
|
1036
|
-
user:
|
|
1037
|
-
domainCode:
|
|
1053
|
+
"data-testid": r,
|
|
1054
|
+
top: s,
|
|
1055
|
+
middle: l,
|
|
1056
|
+
bottom: d,
|
|
1057
|
+
user: h,
|
|
1058
|
+
domainCode: p
|
|
1038
1059
|
}) {
|
|
1039
|
-
const
|
|
1040
|
-
return /* @__PURE__ */ o(
|
|
1041
|
-
|
|
1060
|
+
const u = ht(), w = it(K);
|
|
1061
|
+
return /* @__PURE__ */ o(Dn, { className: j.root, "data-testid": r, children: /* @__PURE__ */ f(
|
|
1062
|
+
On,
|
|
1042
1063
|
{
|
|
1043
1064
|
open: e,
|
|
1044
1065
|
widthOpen: n,
|
|
1045
1066
|
widthClosed: t,
|
|
1046
1067
|
anchor: "left",
|
|
1047
|
-
variant:
|
|
1068
|
+
variant: u ? "temporary" : "permanent",
|
|
1048
1069
|
PaperProps: {
|
|
1049
1070
|
component: "nav"
|
|
1050
1071
|
},
|
|
1051
1072
|
onClose: () => {
|
|
1052
1073
|
w(!1);
|
|
1053
1074
|
},
|
|
1054
|
-
isSmallScreen:
|
|
1075
|
+
isSmallScreen: u,
|
|
1055
1076
|
children: [
|
|
1056
|
-
!
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
/* @__PURE__ */ o(
|
|
1077
|
+
!u && /* @__PURE__ */ o(Rt, {}),
|
|
1078
|
+
s && /* @__PURE__ */ f(D, { flexGrow: "0", children: [
|
|
1079
|
+
s,
|
|
1080
|
+
/* @__PURE__ */ o(_e, { variant: "middle" })
|
|
1060
1081
|
] }),
|
|
1061
|
-
/* @__PURE__ */ o(
|
|
1062
|
-
/* @__PURE__ */
|
|
1063
|
-
/* @__PURE__ */ o(
|
|
1064
|
-
/* @__PURE__ */ o(En, { user:
|
|
1065
|
-
|
|
1082
|
+
/* @__PURE__ */ o(D, { flexGrow: "1", children: Array.isArray(l) ? /* @__PURE__ */ o(Sn, { links: l }) : l }),
|
|
1083
|
+
/* @__PURE__ */ f(D, { flexGrow: "0", children: [
|
|
1084
|
+
/* @__PURE__ */ o(_e, { variant: "middle" }),
|
|
1085
|
+
/* @__PURE__ */ o(En, { user: h, domainCode: p, open: e }),
|
|
1086
|
+
d && /* @__PURE__ */ o(L, { children: d })
|
|
1066
1087
|
] })
|
|
1067
1088
|
]
|
|
1068
1089
|
}
|
|
1069
1090
|
) });
|
|
1070
1091
|
}
|
|
1071
|
-
function
|
|
1092
|
+
function Fn({
|
|
1072
1093
|
children: e,
|
|
1073
1094
|
topBarHeight: t,
|
|
1074
1095
|
maxWidth: n = !1
|
|
1075
1096
|
}) {
|
|
1076
1097
|
return /* @__PURE__ */ o(
|
|
1077
|
-
|
|
1098
|
+
D,
|
|
1078
1099
|
{
|
|
1079
1100
|
sx: {
|
|
1080
1101
|
overflow: "auto",
|
|
@@ -1084,7 +1105,7 @@ function Nn({
|
|
|
1084
1105
|
flexGrow: 1
|
|
1085
1106
|
},
|
|
1086
1107
|
children: /* @__PURE__ */ o(
|
|
1087
|
-
|
|
1108
|
+
et,
|
|
1088
1109
|
{
|
|
1089
1110
|
component: "main",
|
|
1090
1111
|
id: "main-content",
|
|
@@ -1096,18 +1117,18 @@ function Nn({
|
|
|
1096
1117
|
}
|
|
1097
1118
|
);
|
|
1098
1119
|
}
|
|
1099
|
-
const
|
|
1100
|
-
titleText: `${
|
|
1120
|
+
const yn = "TopBar", Nn = {
|
|
1121
|
+
titleText: `${yn}-titleText`
|
|
1101
1122
|
};
|
|
1102
|
-
function
|
|
1123
|
+
function Pn({
|
|
1103
1124
|
titleText: e = "",
|
|
1104
1125
|
height: t,
|
|
1105
1126
|
"data-testid": n,
|
|
1106
|
-
middle:
|
|
1127
|
+
middle: r
|
|
1107
1128
|
}) {
|
|
1108
|
-
const
|
|
1109
|
-
return /* @__PURE__ */ o("header", { "data-testid": n, children: /* @__PURE__ */
|
|
1110
|
-
|
|
1129
|
+
const s = it(K), l = () => s((p) => !p), d = ae(), h = ht();
|
|
1130
|
+
return /* @__PURE__ */ o("header", { "data-testid": n, children: /* @__PURE__ */ f(
|
|
1131
|
+
Ze,
|
|
1111
1132
|
{
|
|
1112
1133
|
square: !0,
|
|
1113
1134
|
elevation: 0,
|
|
@@ -1121,189 +1142,189 @@ function Ln({
|
|
|
1121
1142
|
gap: 2,
|
|
1122
1143
|
flexShrink: 0,
|
|
1123
1144
|
height: t,
|
|
1124
|
-
zIndex:
|
|
1145
|
+
zIndex: h ? 0 : d.zIndex.drawer + 1
|
|
1125
1146
|
},
|
|
1126
1147
|
children: [
|
|
1127
|
-
/* @__PURE__ */ o(Q, { size: "medium", color: "inherit", sx: { padding: 1.5 }, onClick:
|
|
1128
|
-
/* @__PURE__ */ o(
|
|
1129
|
-
|
|
1148
|
+
/* @__PURE__ */ o(Q, { size: "medium", color: "inherit", sx: { padding: 1.5 }, onClick: l, children: /* @__PURE__ */ o(Kt, { fontSize: "medium" }) }),
|
|
1149
|
+
/* @__PURE__ */ o(T, { className: Nn.titleText, variant: "h6", children: e }),
|
|
1150
|
+
r
|
|
1130
1151
|
]
|
|
1131
1152
|
}
|
|
1132
1153
|
) });
|
|
1133
1154
|
}
|
|
1134
|
-
function
|
|
1155
|
+
function vo({
|
|
1135
1156
|
children: e,
|
|
1136
1157
|
initialTitleText: t,
|
|
1137
1158
|
initialNavBarOpen: n,
|
|
1138
|
-
pageContainerProps:
|
|
1139
|
-
pageContentDataTestId:
|
|
1140
|
-
topBarDataTestId:
|
|
1141
|
-
navBarDataTestId:
|
|
1142
|
-
navBarMiddle:
|
|
1143
|
-
navBarBottom:
|
|
1144
|
-
user:
|
|
1159
|
+
pageContainerProps: r,
|
|
1160
|
+
pageContentDataTestId: s,
|
|
1161
|
+
topBarDataTestId: l,
|
|
1162
|
+
navBarDataTestId: d,
|
|
1163
|
+
navBarMiddle: h,
|
|
1164
|
+
navBarBottom: p,
|
|
1165
|
+
user: u,
|
|
1145
1166
|
domainCode: w
|
|
1146
1167
|
}) {
|
|
1147
|
-
|
|
1148
|
-
[
|
|
1149
|
-
[
|
|
1168
|
+
st([
|
|
1169
|
+
[K, n != null ? n : !0],
|
|
1170
|
+
[be, t != null ? t : ""]
|
|
1150
1171
|
]);
|
|
1151
|
-
const b =
|
|
1152
|
-
return /* @__PURE__ */
|
|
1153
|
-
/* @__PURE__ */ o(
|
|
1172
|
+
const b = He(K), [A] = V(gt), [C] = V(ft), k = He(be), [v] = V(mt), [$] = V(An), [g] = V(Ct);
|
|
1173
|
+
return /* @__PURE__ */ f(D, { children: [
|
|
1174
|
+
/* @__PURE__ */ o(Wt, {}),
|
|
1154
1175
|
/* @__PURE__ */ o(
|
|
1155
|
-
|
|
1176
|
+
Pn,
|
|
1156
1177
|
{
|
|
1157
|
-
titleText:
|
|
1158
|
-
"data-testid":
|
|
1159
|
-
height:
|
|
1160
|
-
middle:
|
|
1178
|
+
titleText: k,
|
|
1179
|
+
"data-testid": l,
|
|
1180
|
+
height: v,
|
|
1181
|
+
middle: $
|
|
1161
1182
|
}
|
|
1162
1183
|
),
|
|
1163
|
-
/* @__PURE__ */
|
|
1184
|
+
/* @__PURE__ */ f(D, { sx: { display: "flex" }, children: [
|
|
1164
1185
|
/* @__PURE__ */ o(
|
|
1165
|
-
|
|
1186
|
+
Tn,
|
|
1166
1187
|
{
|
|
1167
1188
|
open: b,
|
|
1168
|
-
top:
|
|
1169
|
-
middle:
|
|
1170
|
-
bottom:
|
|
1171
|
-
user:
|
|
1189
|
+
top: g,
|
|
1190
|
+
middle: h,
|
|
1191
|
+
bottom: p,
|
|
1192
|
+
user: u,
|
|
1172
1193
|
domainCode: w,
|
|
1173
|
-
widthOpen:
|
|
1194
|
+
widthOpen: A,
|
|
1174
1195
|
widthClosed: C,
|
|
1175
|
-
offsetTop:
|
|
1176
|
-
"data-testid":
|
|
1196
|
+
offsetTop: v,
|
|
1197
|
+
"data-testid": d
|
|
1177
1198
|
}
|
|
1178
1199
|
),
|
|
1179
1200
|
/* @__PURE__ */ o(
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
"data-testid":
|
|
1183
|
-
topBarHeight:
|
|
1184
|
-
},
|
|
1201
|
+
Fn,
|
|
1202
|
+
S(i({
|
|
1203
|
+
"data-testid": s,
|
|
1204
|
+
topBarHeight: v
|
|
1205
|
+
}, r), {
|
|
1185
1206
|
children: e
|
|
1186
1207
|
})
|
|
1187
1208
|
)
|
|
1188
1209
|
] })
|
|
1189
1210
|
] });
|
|
1190
1211
|
}
|
|
1191
|
-
const
|
|
1212
|
+
const Bn = {
|
|
1192
1213
|
autoHideDuration: 6e3,
|
|
1193
1214
|
anchorOrigin: { vertical: "top", horizontal: "center" },
|
|
1194
1215
|
// The default is false. If we prefer timer to continue when window loses
|
|
1195
1216
|
// focus, change to true
|
|
1196
1217
|
disableWindowBlurListener: !1
|
|
1197
|
-
},
|
|
1218
|
+
}, Ln = {
|
|
1198
1219
|
shouldClose: (e, t) => t !== "clickaway"
|
|
1199
|
-
},
|
|
1220
|
+
}, qe = {
|
|
1200
1221
|
message: "",
|
|
1201
1222
|
severity: "info",
|
|
1202
1223
|
variant: "standard",
|
|
1203
1224
|
progressIndicator: void 0
|
|
1204
1225
|
// Can use 'circular' or 'linear'
|
|
1205
|
-
},
|
|
1226
|
+
}, Xe = 100, je = 2e3, Mn = 2e3, _n = (() => {
|
|
1206
1227
|
let e = 0;
|
|
1207
1228
|
return () => (e += 1, e);
|
|
1208
|
-
})(),
|
|
1229
|
+
})(), Hn = {
|
|
1209
1230
|
borderBottomLeftRadius: "0px",
|
|
1210
1231
|
borderBottomRightRadius: "0px"
|
|
1211
|
-
},
|
|
1212
|
-
function
|
|
1213
|
-
var
|
|
1214
|
-
overrideState: e =
|
|
1215
|
-
overrideActions: t =
|
|
1216
|
-
shouldClose: n =
|
|
1217
|
-
children:
|
|
1218
|
-
} =
|
|
1232
|
+
}, Rn = {}, Wn = {}, xt = Je(null);
|
|
1233
|
+
function zn(l) {
|
|
1234
|
+
var d = l, {
|
|
1235
|
+
overrideState: e = Rn,
|
|
1236
|
+
overrideActions: t = Wn,
|
|
1237
|
+
shouldClose: n = Ln.shouldClose,
|
|
1238
|
+
children: r
|
|
1239
|
+
} = d, s = Pe(d, [
|
|
1219
1240
|
"overrideState",
|
|
1220
1241
|
"overrideActions",
|
|
1221
1242
|
"shouldClose",
|
|
1222
1243
|
"children"
|
|
1223
1244
|
]);
|
|
1224
|
-
var
|
|
1225
|
-
const [{ open:
|
|
1226
|
-
|
|
1227
|
-
}, []), C =
|
|
1228
|
-
b.current += 1,
|
|
1229
|
-
`SaladBarProvider: MAX_QUEUE_LENGTH (${
|
|
1245
|
+
var W;
|
|
1246
|
+
const [{ open: h }, p] = O({ open: !1 }), u = fe([]), w = fe(Date.now()), b = fe(0), A = oe((a) => {
|
|
1247
|
+
p({ open: a });
|
|
1248
|
+
}, []), C = oe((a = {}) => {
|
|
1249
|
+
b.current += 1, u.current.length >= Xe && Date.now() - w.current >= je && (w.current = Date.now(), console.error(
|
|
1250
|
+
`SaladBarProvider: MAX_QUEUE_LENGTH (${Xe}) hit ${b.current} times in last ${je}ms)`
|
|
1230
1251
|
), b.current = 0);
|
|
1231
|
-
const
|
|
1232
|
-
key:
|
|
1233
|
-
}),
|
|
1234
|
-
return
|
|
1235
|
-
}, []),
|
|
1236
|
-
const
|
|
1237
|
-
if (
|
|
1238
|
-
return
|
|
1239
|
-
}, _ = (
|
|
1240
|
-
n(
|
|
1252
|
+
const c = i(S(i({}, qe), {
|
|
1253
|
+
key: _n()
|
|
1254
|
+
}), a);
|
|
1255
|
+
return u.current.push(c), u.current.length === 1 && p({ open: !0 }), c.key;
|
|
1256
|
+
}, []), k = (a = "", c = {}) => C(i({ message: a, severity: "success" }, c)), v = (a = "", c = {}) => C(i({ message: a, severity: "info" }, c)), $ = (a = "", c = {}) => C(i({ message: a, severity: "warning" }, c)), g = (a = "", c = {}) => C(i({ message: a, severity: "error" }, c)), m = (a) => {
|
|
1257
|
+
const c = u.current.findIndex((x) => x.key === a);
|
|
1258
|
+
if (c !== -1)
|
|
1259
|
+
return c === 0 ? (p({ open: !1 }), u.current[0]) : u.current.splice(c, 1);
|
|
1260
|
+
}, _ = (a, c) => {
|
|
1261
|
+
n(a, c) && p({ open: !1 });
|
|
1241
1262
|
}, F = () => {
|
|
1242
|
-
},
|
|
1243
|
-
|
|
1244
|
-
},
|
|
1245
|
-
"autoHideDuration" in
|
|
1246
|
-
const
|
|
1247
|
-
open:
|
|
1248
|
-
setOpen:
|
|
1263
|
+
}, y = () => {
|
|
1264
|
+
u.current.shift(), u.current.length > 0 && p({ open: !0 });
|
|
1265
|
+
}, I = (W = u.current[0]) != null ? W : i({}, qe), H = {};
|
|
1266
|
+
"autoHideDuration" in I && (H.autoHideDuration = I.autoHideDuration);
|
|
1267
|
+
const P = i(i({}, Bn), s), R = i(i({
|
|
1268
|
+
open: h,
|
|
1269
|
+
setOpen: A,
|
|
1249
1270
|
enqueueNotification: C,
|
|
1250
|
-
enqueueSuccessNotification:
|
|
1251
|
-
enqueueInfoNotification:
|
|
1252
|
-
enqueueWarningNotification:
|
|
1253
|
-
enqueueErrorNotification:
|
|
1254
|
-
removeNotification:
|
|
1271
|
+
enqueueSuccessNotification: k,
|
|
1272
|
+
enqueueInfoNotification: v,
|
|
1273
|
+
enqueueWarningNotification: $,
|
|
1274
|
+
enqueueErrorNotification: g,
|
|
1275
|
+
removeNotification: m
|
|
1255
1276
|
}, e), t);
|
|
1256
|
-
return /* @__PURE__ */
|
|
1257
|
-
|
|
1277
|
+
return /* @__PURE__ */ f(xt.Provider, { value: R, children: [
|
|
1278
|
+
r,
|
|
1258
1279
|
/* @__PURE__ */ o(
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
open:
|
|
1280
|
+
zt,
|
|
1281
|
+
S(i(i({}, P), H), {
|
|
1282
|
+
open: h,
|
|
1262
1283
|
onClose: _,
|
|
1263
1284
|
TransitionProps: {
|
|
1264
|
-
onExited:
|
|
1285
|
+
onExited: y,
|
|
1265
1286
|
onExit: F
|
|
1266
1287
|
},
|
|
1267
|
-
sx: { zIndex:
|
|
1268
|
-
children: /* @__PURE__ */
|
|
1288
|
+
sx: { zIndex: Mn },
|
|
1289
|
+
children: /* @__PURE__ */ f("div", { children: [
|
|
1269
1290
|
/* @__PURE__ */ o(
|
|
1270
|
-
|
|
1291
|
+
Gt,
|
|
1271
1292
|
{
|
|
1272
|
-
onClose: (
|
|
1273
|
-
severity:
|
|
1293
|
+
onClose: (a) => _(a, "closeAlert"),
|
|
1294
|
+
severity: I.severity,
|
|
1274
1295
|
variant: "filled",
|
|
1275
|
-
icon:
|
|
1276
|
-
style:
|
|
1277
|
-
children:
|
|
1296
|
+
icon: I.progressIndicator === "circular" ? /* @__PURE__ */ o(ke, { size: "1em" }) : void 0,
|
|
1297
|
+
style: I.progressIndicator === "linear" ? Hn : void 0,
|
|
1298
|
+
children: I.message
|
|
1278
1299
|
}
|
|
1279
1300
|
),
|
|
1280
|
-
|
|
1301
|
+
I.progressIndicator === "linear" && /* @__PURE__ */ o(Ut, { color: "primary" })
|
|
1281
1302
|
] })
|
|
1282
1303
|
})
|
|
1283
1304
|
)
|
|
1284
1305
|
] });
|
|
1285
1306
|
}
|
|
1286
|
-
function
|
|
1287
|
-
const e =
|
|
1307
|
+
function Gn() {
|
|
1308
|
+
const e = Ye(xt);
|
|
1288
1309
|
if (e === null)
|
|
1289
|
-
throw new
|
|
1310
|
+
throw new $e("Error: Tried to useSaladBar outside of a <SaladBarProvider>");
|
|
1290
1311
|
return e;
|
|
1291
1312
|
}
|
|
1292
|
-
const
|
|
1293
|
-
(e = { autoHideDuration: 1 }, t = {}, n = {}) => ({ children:
|
|
1294
|
-
),
|
|
1313
|
+
const xo = se(
|
|
1314
|
+
(e = { autoHideDuration: 1 }, t = {}, n = {}) => ({ children: r }) => /* @__PURE__ */ o(zn, S(i({}, e), { overrideState: t, overrideActions: n, children: r }))
|
|
1315
|
+
), Un = Zt(), wo = ({
|
|
1295
1316
|
children: e,
|
|
1296
1317
|
store: t
|
|
1297
|
-
}) => /* @__PURE__ */ o(
|
|
1298
|
-
var
|
|
1299
|
-
const
|
|
1300
|
-
JSON.parse((
|
|
1301
|
-
),
|
|
1302
|
-
(e) => e(
|
|
1318
|
+
}) => /* @__PURE__ */ o(at, { store: t != null ? t : Un, children: e }), wt = "domainCode";
|
|
1319
|
+
var Ke;
|
|
1320
|
+
const Qe = N(
|
|
1321
|
+
JSON.parse((Ke = localStorage.getItem(wt)) != null ? Ke : '{"domainCode": ""}').domainCode
|
|
1322
|
+
), bt = N(
|
|
1323
|
+
(e) => e(Qe),
|
|
1303
1324
|
(e, t, n) => {
|
|
1304
|
-
t(
|
|
1325
|
+
t(Qe, n), localStorage.setItem(wt, JSON.stringify({ domainCode: n }));
|
|
1305
1326
|
}
|
|
1306
|
-
),
|
|
1327
|
+
), Vn = {
|
|
1307
1328
|
act: "ACT",
|
|
1308
1329
|
nsw: "NSW",
|
|
1309
1330
|
nt: "NT",
|
|
@@ -1315,76 +1336,76 @@ const qe = P(
|
|
|
1315
1336
|
ag: "AG",
|
|
1316
1337
|
fedmps: "Fedmps",
|
|
1317
1338
|
"": ""
|
|
1318
|
-
},
|
|
1339
|
+
}, qn = (e) => {
|
|
1319
1340
|
var t;
|
|
1320
|
-
return e === null ? "N/A" : (t =
|
|
1321
|
-
},
|
|
1341
|
+
return e === null ? "N/A" : (t = Vn[e]) != null ? t : "";
|
|
1342
|
+
}, bo = ({
|
|
1322
1343
|
isLoading: e,
|
|
1323
1344
|
isOpen: t,
|
|
1324
1345
|
onClose: n,
|
|
1325
|
-
domainOptions:
|
|
1326
|
-
applicationName:
|
|
1327
|
-
handleLogout:
|
|
1346
|
+
domainOptions: r,
|
|
1347
|
+
applicationName: s,
|
|
1348
|
+
handleLogout: l
|
|
1328
1349
|
}) => {
|
|
1329
|
-
const [
|
|
1330
|
-
|
|
1331
|
-
}),
|
|
1332
|
-
|
|
1350
|
+
const [d, h] = V(bt), [p, u] = O(d), { enqueueSuccessNotification: w } = Gn(), b = r.length === 0, A = !!d && !r.includes(d) && !r.includes(p), C = !d || b || A, k = () => B(void 0, null, function* () {
|
|
1351
|
+
p ? (h(p), w(`Set domain to ${p}`), n()) : h("");
|
|
1352
|
+
}), v = () => B(void 0, null, function* () {
|
|
1353
|
+
d && !b && !A ? (u(d), n()) : C && l();
|
|
1333
1354
|
});
|
|
1334
|
-
let
|
|
1335
|
-
return b ?
|
|
1336
|
-
|
|
1355
|
+
let $;
|
|
1356
|
+
return b ? $ = "Unable to retrieve your active organisations. Try logging in again." : A && ($ = "You no longer have any roles in your chosen organisation. Please choose another."), /* @__PURE__ */ f(
|
|
1357
|
+
dn,
|
|
1337
1358
|
{
|
|
1338
1359
|
isOpen: t,
|
|
1339
1360
|
dialogTitle: "Select an organisation",
|
|
1340
1361
|
primaryButton: {
|
|
1341
1362
|
text: "Confirm",
|
|
1342
|
-
onClick:
|
|
1343
|
-
disabled: !
|
|
1363
|
+
onClick: k,
|
|
1364
|
+
disabled: !p || b || A,
|
|
1344
1365
|
buttonColor: "primary"
|
|
1345
1366
|
},
|
|
1346
1367
|
secondaryButton: {
|
|
1347
1368
|
text: C ? "Logout" : "Cancel",
|
|
1348
|
-
onClick:
|
|
1369
|
+
onClick: v
|
|
1349
1370
|
},
|
|
1350
1371
|
onClose: C ? () => {
|
|
1351
1372
|
} : n,
|
|
1352
1373
|
children: [
|
|
1353
|
-
/* @__PURE__ */
|
|
1374
|
+
/* @__PURE__ */ f(T, { marginBottom: 2, children: [
|
|
1354
1375
|
"Select the default organisation that you want to use with the ",
|
|
1355
|
-
|
|
1376
|
+
s,
|
|
1356
1377
|
"."
|
|
1357
1378
|
] }),
|
|
1358
1379
|
/* @__PURE__ */ o(
|
|
1359
|
-
|
|
1380
|
+
Se,
|
|
1360
1381
|
{
|
|
1361
1382
|
loading: e,
|
|
1362
1383
|
multiple: !1,
|
|
1363
1384
|
disableClearable: !1,
|
|
1364
|
-
value:
|
|
1365
|
-
onChange: (
|
|
1366
|
-
getOptionLabel:
|
|
1367
|
-
options: [...
|
|
1368
|
-
renderInput: (
|
|
1369
|
-
|
|
1370
|
-
|
|
1385
|
+
value: p !== "" ? p : null,
|
|
1386
|
+
onChange: (g, m) => u(m != null ? m : ""),
|
|
1387
|
+
getOptionLabel: qn,
|
|
1388
|
+
options: [...r],
|
|
1389
|
+
renderInput: (g) => /* @__PURE__ */ o(
|
|
1390
|
+
De,
|
|
1391
|
+
S(i({}, g), {
|
|
1371
1392
|
variant: "filled",
|
|
1372
1393
|
label: "Select organisation",
|
|
1373
|
-
InputProps:
|
|
1374
|
-
endAdornment: /* @__PURE__ */
|
|
1375
|
-
e ? /* @__PURE__ */ o(
|
|
1376
|
-
|
|
1394
|
+
InputProps: S(i({}, g.InputProps), {
|
|
1395
|
+
endAdornment: /* @__PURE__ */ f(L, { children: [
|
|
1396
|
+
e ? /* @__PURE__ */ o(ke, { color: "inherit", size: 20, sx: { marginTop: "-20px" } }) : null,
|
|
1397
|
+
g.InputProps.endAdornment
|
|
1377
1398
|
] })
|
|
1378
1399
|
})
|
|
1379
1400
|
})
|
|
1380
1401
|
)
|
|
1381
1402
|
}
|
|
1382
1403
|
),
|
|
1383
|
-
|
|
1404
|
+
$ && /* @__PURE__ */ o(Vt, { error: !0, children: $ })
|
|
1384
1405
|
]
|
|
1385
1406
|
}
|
|
1386
1407
|
);
|
|
1387
|
-
},
|
|
1408
|
+
}, Ao = tt({
|
|
1388
1409
|
palette: {
|
|
1389
1410
|
primary: {
|
|
1390
1411
|
dark: "#00A651",
|
|
@@ -1435,7 +1456,7 @@ const qe = P(
|
|
|
1435
1456
|
navBar: {
|
|
1436
1457
|
backgroundColor: "#E8E8E8"
|
|
1437
1458
|
}
|
|
1438
|
-
}),
|
|
1459
|
+
}), So = tt({
|
|
1439
1460
|
palette: {
|
|
1440
1461
|
primary: {
|
|
1441
1462
|
main: "#007236",
|
|
@@ -1489,18 +1510,18 @@ const qe = P(
|
|
|
1489
1510
|
styleOverrides: {
|
|
1490
1511
|
root: ({ theme: e }) => ({
|
|
1491
1512
|
"&.Mui-selected": {
|
|
1492
|
-
backgroundColor:
|
|
1513
|
+
backgroundColor: me(
|
|
1493
1514
|
e.palette.secondary.main,
|
|
1494
1515
|
e.palette.action.selectedOpacity
|
|
1495
1516
|
),
|
|
1496
1517
|
"&:hover": {
|
|
1497
|
-
backgroundColor:
|
|
1518
|
+
backgroundColor: me(
|
|
1498
1519
|
e.palette.secondary.main,
|
|
1499
1520
|
e.palette.action.selectedOpacity
|
|
1500
1521
|
)
|
|
1501
1522
|
},
|
|
1502
1523
|
"&.Mui-focusVisible": {
|
|
1503
|
-
backgroundColor:
|
|
1524
|
+
backgroundColor: me(
|
|
1504
1525
|
e.palette.secondary.main,
|
|
1505
1526
|
e.palette.action.focusOpacity
|
|
1506
1527
|
)
|
|
@@ -1526,72 +1547,68 @@ const qe = P(
|
|
|
1526
1547
|
navBar: {
|
|
1527
1548
|
backgroundColor: "#E8E8E8"
|
|
1528
1549
|
}
|
|
1529
|
-
}),
|
|
1530
|
-
domainCode:
|
|
1531
|
-
navBarOpen:
|
|
1532
|
-
navBarWidthOpen:
|
|
1533
|
-
navBarWidthClosed:
|
|
1534
|
-
titleText:
|
|
1535
|
-
topBarHeight:
|
|
1536
|
-
navBarTop:
|
|
1537
|
-
},
|
|
1550
|
+
}), Xn = {
|
|
1551
|
+
domainCode: bt,
|
|
1552
|
+
navBarOpen: K,
|
|
1553
|
+
navBarWidthOpen: gt,
|
|
1554
|
+
navBarWidthClosed: ft,
|
|
1555
|
+
titleText: be,
|
|
1556
|
+
topBarHeight: mt,
|
|
1557
|
+
navBarTop: Ct
|
|
1558
|
+
}, Do = se(() => ({ children: e }) => /* @__PURE__ */ o(at, { children: e })), jn = ({
|
|
1538
1559
|
initialValues: e,
|
|
1539
1560
|
children: t
|
|
1540
|
-
}) => (
|
|
1561
|
+
}) => (st(e), /* @__PURE__ */ o(L, { children: t })), ko = se(
|
|
1541
1562
|
(e) => ({ children: t }) => /* @__PURE__ */ o(
|
|
1542
|
-
|
|
1563
|
+
jn,
|
|
1543
1564
|
{
|
|
1544
1565
|
initialValues: Object.entries(e).map(
|
|
1545
|
-
([n,
|
|
1546
|
-
|
|
1547
|
-
|
|
1566
|
+
([n, r]) => [
|
|
1567
|
+
Xn[n],
|
|
1568
|
+
r
|
|
1548
1569
|
]
|
|
1549
1570
|
),
|
|
1550
1571
|
children: t
|
|
1551
1572
|
}
|
|
1552
1573
|
)
|
|
1553
|
-
)
|
|
1554
|
-
const t = new Zt();
|
|
1555
|
-
return /* @__PURE__ */ o(en, { client: t, children: e });
|
|
1556
|
-
});
|
|
1574
|
+
);
|
|
1557
1575
|
export {
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
Ao as withSaladBarProvider
|
|
1576
|
+
dn as AgDialog,
|
|
1577
|
+
vo as AppLayout,
|
|
1578
|
+
wo as AtomProvider,
|
|
1579
|
+
xt as Context,
|
|
1580
|
+
$e as ContextError,
|
|
1581
|
+
bo as DomainCodeDialog,
|
|
1582
|
+
co as ExampleComponent,
|
|
1583
|
+
fo as FetchAutocomplete,
|
|
1584
|
+
jn as HydrateAtoms,
|
|
1585
|
+
ct as NAVBAR_WIDTH_CLOSED,
|
|
1586
|
+
lt as NAVBAR_WIDTH_OPENED,
|
|
1587
|
+
go as NavBar,
|
|
1588
|
+
uo as NavBarDarkStyledList,
|
|
1589
|
+
ho as NavBarLightStyledList,
|
|
1590
|
+
sn as NavBarProvider,
|
|
1591
|
+
Co as PageLayout,
|
|
1592
|
+
zn as SaladBarProvider,
|
|
1593
|
+
mo as SingleAutocomplete,
|
|
1594
|
+
Un as atomStore,
|
|
1595
|
+
cn as buildNavBarState,
|
|
1596
|
+
bt as domainCodeAtom,
|
|
1597
|
+
Ao as fed21Theme,
|
|
1598
|
+
So as internalAgSystemsTheme,
|
|
1599
|
+
q as navBarClasses,
|
|
1600
|
+
K as navBarOpenAtom,
|
|
1601
|
+
Ct as navBarTopAtom,
|
|
1602
|
+
ft as navBarWidthClosedAtom,
|
|
1603
|
+
gt as navBarWidthOpenAtom,
|
|
1604
|
+
be as titleTextAtom,
|
|
1605
|
+
mt as topBarHeightAtom,
|
|
1606
|
+
An as topBarMiddleAtom,
|
|
1607
|
+
ln as useNavBar,
|
|
1608
|
+
Gn as useSaladBar,
|
|
1609
|
+
Do as withAtomProvider,
|
|
1610
|
+
po as withNavBarProvider,
|
|
1611
|
+
ko as withOverrideDefaults,
|
|
1612
|
+
xo as withSaladBarProvider
|
|
1596
1613
|
};
|
|
1597
1614
|
//# sourceMappingURL=index.js.map
|