@australiangreens/ag-internal-components 0.0.54-experiment1 → 0.0.55
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/cjs/index.cjs +1 -1
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.js +522 -533
- package/dist/esm/index.js.map +1 -1
- package/dist/layouts/AppLayout/NavBar/NavBar.d.ts +1 -1
- package/dist/layouts/AppLayout/NavBar/NavBar.d.ts.map +1 -1
- package/dist/layouts/AppLayout/NavBar/Styling.d.ts +2 -0
- package/dist/layouts/AppLayout/NavBar/Styling.d.ts.map +1 -1
- package/dist/layouts/AppLayout/NavBar/UserInfo.d.ts +1 -6
- package/dist/layouts/AppLayout/NavBar/UserInfo.d.ts.map +1 -1
- package/package.json +21 -19
- package/dist/.gitignore +0 -0
package/dist/esm/index.js
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var xt = Object.defineProperty, Ct = Object.defineProperties;
|
|
2
|
+
var wt = Object.getOwnPropertyDescriptors;
|
|
3
3
|
var Y = Object.getOwnPropertySymbols;
|
|
4
|
-
var
|
|
5
|
-
var
|
|
6
|
-
for (var n in
|
|
7
|
-
|
|
4
|
+
var be = Object.prototype.hasOwnProperty, Ae = Object.prototype.propertyIsEnumerable;
|
|
5
|
+
var le = (e, t, n) => t in e ? xt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, r = (e, t) => {
|
|
6
|
+
for (var n in t || (t = {}))
|
|
7
|
+
be.call(t, n) && le(e, n, t[n]);
|
|
8
8
|
if (Y)
|
|
9
|
-
for (var n of Y(
|
|
10
|
-
|
|
11
|
-
return
|
|
12
|
-
}, w = (
|
|
13
|
-
var
|
|
9
|
+
for (var n of Y(t))
|
|
10
|
+
Ae.call(t, n) && le(e, n, t[n]);
|
|
11
|
+
return e;
|
|
12
|
+
}, w = (e, t) => Ct(e, wt(t));
|
|
13
|
+
var Se = (e, t) => {
|
|
14
14
|
var n = {};
|
|
15
|
-
for (var i in
|
|
16
|
-
|
|
17
|
-
if (
|
|
18
|
-
for (var i of Y(
|
|
19
|
-
|
|
15
|
+
for (var i in e)
|
|
16
|
+
be.call(e, i) && t.indexOf(i) < 0 && (n[i] = e[i]);
|
|
17
|
+
if (e != null && Y)
|
|
18
|
+
for (var i of Y(e))
|
|
19
|
+
t.indexOf(i) < 0 && Ae.call(e, i) && (n[i] = e[i]);
|
|
20
20
|
return n;
|
|
21
21
|
};
|
|
22
|
-
var
|
|
23
|
-
var J = (
|
|
22
|
+
var Te = (e, t, n) => (le(e, typeof t != "symbol" ? t + "" : t, n), n);
|
|
23
|
+
var J = (e, t, n) => new Promise((i, a) => {
|
|
24
24
|
var l = (s) => {
|
|
25
25
|
try {
|
|
26
26
|
u(n.next(s));
|
|
@@ -34,31 +34,31 @@ var J = (t, e, n) => new Promise((i, a) => {
|
|
|
34
34
|
a(d);
|
|
35
35
|
}
|
|
36
36
|
}, u = (s) => s.done ? i(s.value) : Promise.resolve(s.value).then(l, p);
|
|
37
|
-
u((n = n.apply(
|
|
37
|
+
u((n = n.apply(e, t)).next());
|
|
38
38
|
});
|
|
39
|
-
import { jsxs as c, Fragment as
|
|
40
|
-
import { useState as
|
|
41
|
-
import { Typography as
|
|
42
|
-
import
|
|
43
|
-
import { styled as
|
|
44
|
-
import { AgError as
|
|
45
|
-
import { createHelper as
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import { ArrowForward as
|
|
53
|
-
import { atom as E, useSetAtom as
|
|
54
|
-
import { useHydrateAtoms as
|
|
55
|
-
function
|
|
56
|
-
const [
|
|
57
|
-
return /* @__PURE__ */ c(
|
|
58
|
-
/* @__PURE__ */ o(
|
|
59
|
-
/* @__PURE__ */ o(
|
|
39
|
+
import { jsxs as c, Fragment as y, jsx as o } from "react/jsx-runtime";
|
|
40
|
+
import { useState as k, createContext as Re, useCallback as ee, useContext as We, useEffect as te, useRef as de } from "react";
|
|
41
|
+
import { Typography as B, Button as bt, Paper as ze, Box as x, Drawer as he, styled as ge, IconButton as V, Container as Ge, useTheme as At, Avatar as Ie, Collapse as St, Skeleton as Oe, Divider as De, CssBaseline as Tt, Snackbar as It, Alert as Ot, CircularProgress as Ue, LinearProgress as Dt, Autocomplete as kt, TextField as Bt, FormHelperText as $t } from "@mui/material";
|
|
42
|
+
import Et from "@mui/material/CssBaseline";
|
|
43
|
+
import { styled as $, createTheme as Ve, alpha as ce } from "@mui/material/styles";
|
|
44
|
+
import { AgError as Nt } from "@australiangreens/ag-error";
|
|
45
|
+
import { createHelper as oe } from "souvlaki";
|
|
46
|
+
import Xe from "@mui/material/List";
|
|
47
|
+
import ke from "@mui/material/Button";
|
|
48
|
+
import Ft from "@mui/material/Dialog";
|
|
49
|
+
import Pt from "@mui/material/DialogActions";
|
|
50
|
+
import Lt from "@mui/material/DialogContent";
|
|
51
|
+
import yt from "@mui/material/DialogTitle";
|
|
52
|
+
import { ArrowForward as qe, ArrowBack as je, ViewHeadline as Mt } from "@mui/icons-material";
|
|
53
|
+
import { atom as E, useSetAtom as _t, useAtom as P, getDefaultStore as Ht, Provider as Qe } from "jotai";
|
|
54
|
+
import { useHydrateAtoms as Rt } from "jotai/utils";
|
|
55
|
+
function Jn({ text: e }) {
|
|
56
|
+
const [t, n] = k(0);
|
|
57
|
+
return /* @__PURE__ */ c(y, { children: [
|
|
58
|
+
/* @__PURE__ */ o(B, { variant: "h6", color: "inherit", component: "div", sx: { fontSize: "22px" }, children: "Hello world" }),
|
|
59
|
+
/* @__PURE__ */ o(B, { variant: "caption", display: "block", children: /* @__PURE__ */ o("span", { children: "Just ensuring MUI is working as planned as a peer dependency. v0.0.11" }) }),
|
|
60
60
|
/* @__PURE__ */ o(
|
|
61
|
-
|
|
61
|
+
bt,
|
|
62
62
|
{
|
|
63
63
|
variant: "outlined",
|
|
64
64
|
onClick: () => n((i) => i + 1),
|
|
@@ -68,25 +68,25 @@ function jn({ text: t }) {
|
|
|
68
68
|
),
|
|
69
69
|
/* @__PURE__ */ c("p", { children: [
|
|
70
70
|
"This is some text: ",
|
|
71
|
-
/* @__PURE__ */ o("span", { children:
|
|
71
|
+
/* @__PURE__ */ o("span", { children: e })
|
|
72
72
|
] }),
|
|
73
|
-
/* @__PURE__ */ c(
|
|
73
|
+
/* @__PURE__ */ c(ze, { children: [
|
|
74
74
|
"This number will incremember when button pressed: ",
|
|
75
|
-
|
|
75
|
+
t
|
|
76
76
|
] })
|
|
77
77
|
] });
|
|
78
78
|
}
|
|
79
|
-
const
|
|
80
|
-
root: `${
|
|
81
|
-
menuButton: `${
|
|
82
|
-
hide: `${
|
|
83
|
-
content: `${
|
|
84
|
-
userInfoHolder: `${
|
|
85
|
-
settings: `${
|
|
86
|
-
pieChartIcon: `${
|
|
87
|
-
},
|
|
79
|
+
const Ye = 330, Je = 73, F = "Navbar", _ = {
|
|
80
|
+
root: `${F}-root`,
|
|
81
|
+
menuButton: `${F}-menuButton`,
|
|
82
|
+
hide: `${F}-hide`,
|
|
83
|
+
content: `${F}-content`,
|
|
84
|
+
userInfoHolder: `${F}-userInfoHolder`,
|
|
85
|
+
settings: `${F}-settings`,
|
|
86
|
+
pieChartIcon: `${F}-pieChartIcon`
|
|
87
|
+
}, Wt = $(x, {
|
|
88
88
|
name: "NavBar"
|
|
89
|
-
})(({ theme:
|
|
89
|
+
})(({ theme: e }) => ({
|
|
90
90
|
[`&.${_.root}`]: {
|
|
91
91
|
display: "flex"
|
|
92
92
|
},
|
|
@@ -98,14 +98,14 @@ const Jt = 330, Kt = 73, P = "Navbar", _ = {
|
|
|
98
98
|
},
|
|
99
99
|
[`& .${_.content}`]: {
|
|
100
100
|
flexGrow: 1,
|
|
101
|
-
padding:
|
|
101
|
+
padding: e.spacing(3)
|
|
102
102
|
},
|
|
103
103
|
[`& .${_.userInfoHolder}`]: {
|
|
104
104
|
height: "148px",
|
|
105
105
|
marginTop: "64px",
|
|
106
106
|
marginBottom: "16px"
|
|
107
107
|
}
|
|
108
|
-
})),
|
|
108
|
+
})), Ke = () => ({
|
|
109
109
|
position: "absolute",
|
|
110
110
|
height: "100%",
|
|
111
111
|
overflowX: "hidden",
|
|
@@ -113,51 +113,51 @@ const Jt = 330, Kt = 73, P = "Navbar", _ = {
|
|
|
113
113
|
color: "white",
|
|
114
114
|
backgroundColor: "black"
|
|
115
115
|
// backgroundColor: '#e8e8e8',
|
|
116
|
-
}),
|
|
117
|
-
width:
|
|
118
|
-
},
|
|
119
|
-
width:
|
|
120
|
-
},
|
|
121
|
-
shouldForwardProp: (
|
|
122
|
-
})(({ theme:
|
|
123
|
-
width:
|
|
116
|
+
}), zt = () => r({
|
|
117
|
+
width: Ye
|
|
118
|
+
}, Ke()), Gt = () => r({
|
|
119
|
+
width: Je
|
|
120
|
+
}, Ke()), Ut = $(he, {
|
|
121
|
+
shouldForwardProp: (e) => e !== "open"
|
|
122
|
+
})(({ theme: e, open: t }) => r(r({
|
|
123
|
+
width: t ? Ye : Je,
|
|
124
124
|
flexShrink: 0,
|
|
125
125
|
whiteSpace: "nowrap",
|
|
126
126
|
boxSizing: "border-box",
|
|
127
|
-
zIndex:
|
|
128
|
-
},
|
|
129
|
-
"& .MuiDrawer-paper":
|
|
130
|
-
}), !
|
|
131
|
-
"& .MuiDrawer-paper":
|
|
127
|
+
zIndex: e.zIndex.drawer + 100
|
|
128
|
+
}, t && {
|
|
129
|
+
"& .MuiDrawer-paper": zt()
|
|
130
|
+
}), !t && {
|
|
131
|
+
"& .MuiDrawer-paper": Gt()
|
|
132
132
|
}));
|
|
133
|
-
class
|
|
133
|
+
class fe extends Nt {
|
|
134
134
|
}
|
|
135
|
-
|
|
136
|
-
const
|
|
137
|
-
overrideState:
|
|
138
|
-
overrideActions:
|
|
135
|
+
Te(fe, "errorName", "ContextError");
|
|
136
|
+
const Ze = Re(null), Vt = {}, Xt = {}, qt = ({
|
|
137
|
+
overrideState: e = Vt,
|
|
138
|
+
overrideActions: t = Xt,
|
|
139
139
|
children: n
|
|
140
140
|
}) => {
|
|
141
|
-
const [{ open: i }, a] =
|
|
141
|
+
const [{ open: i }, a] = k({ open: !0 }), l = ee((s) => {
|
|
142
142
|
a({ open: s });
|
|
143
|
-
}, []), p =
|
|
143
|
+
}, []), p = ee(() => {
|
|
144
144
|
a((s) => w(r({}, s), { open: !s.open }));
|
|
145
145
|
}, []), u = r(r({
|
|
146
146
|
open: i,
|
|
147
147
|
setOpen: l,
|
|
148
148
|
toggleOpen: p
|
|
149
|
-
},
|
|
150
|
-
return /* @__PURE__ */ o(
|
|
151
|
-
},
|
|
152
|
-
const
|
|
153
|
-
if (
|
|
154
|
-
throw new
|
|
155
|
-
return
|
|
156
|
-
},
|
|
149
|
+
}, e), t);
|
|
150
|
+
return /* @__PURE__ */ o(Ze.Provider, { value: u, children: n });
|
|
151
|
+
}, jt = () => {
|
|
152
|
+
const e = We(Ze);
|
|
153
|
+
if (e === null)
|
|
154
|
+
throw new fe("Error: Tried to useNavBar outside of a <NavBarProvider>");
|
|
155
|
+
return e;
|
|
156
|
+
}, Qt = (e = {}) => r({
|
|
157
157
|
open: !0
|
|
158
|
-
},
|
|
159
|
-
(
|
|
160
|
-
),
|
|
158
|
+
}, e), Kn = oe(
|
|
159
|
+
(e = Qt(), t = {}) => ({ children: n }) => /* @__PURE__ */ o(qt, { overrideState: e, overrideActions: t, children: n })
|
|
160
|
+
), Be = 7, Zn = $(Xe)(({ theme: e }) => ({
|
|
161
161
|
backgroundColor: "black",
|
|
162
162
|
color: "white",
|
|
163
163
|
"& .MuiListItem-root": {
|
|
@@ -166,36 +166,36 @@ const te = Wt(null), Ge = {}, Ve = {}, Xe = ({
|
|
|
166
166
|
"& .MuiListItemButton-root": {
|
|
167
167
|
" .MuiListItemIcon-root": {
|
|
168
168
|
color: "white",
|
|
169
|
-
padding: `${
|
|
169
|
+
padding: `${Be}px`
|
|
170
170
|
},
|
|
171
171
|
// Focus state
|
|
172
172
|
"&.Mui-focusVisible": {
|
|
173
|
-
backgroundColor:
|
|
173
|
+
backgroundColor: e.palette.grey[700]
|
|
174
174
|
},
|
|
175
175
|
// Selected state
|
|
176
176
|
"&.Mui-selected": {
|
|
177
177
|
borderLeftStyle: "solid",
|
|
178
178
|
borderLeftWidth: "7px",
|
|
179
|
-
borderLeftColor:
|
|
180
|
-
paddingLeft: `calc(${
|
|
179
|
+
borderLeftColor: e.palette.primary.main,
|
|
180
|
+
paddingLeft: `calc(${e.spacing(2)} - ${Be}px)`
|
|
181
181
|
},
|
|
182
182
|
// Hover state
|
|
183
183
|
"&:hover": {
|
|
184
|
-
backgroundColor:
|
|
184
|
+
backgroundColor: e.palette.primary.dark
|
|
185
185
|
},
|
|
186
186
|
// Focus+Selected state
|
|
187
187
|
"&.Mui-selected.Mui-focusVisible": {
|
|
188
|
-
backgroundColor:
|
|
188
|
+
backgroundColor: e.palette.grey[700]
|
|
189
189
|
},
|
|
190
190
|
// Hover+Selected state
|
|
191
191
|
"&.Mui-selected:hover": {
|
|
192
|
-
backgroundColor:
|
|
192
|
+
backgroundColor: e.palette.primary.dark
|
|
193
193
|
}
|
|
194
194
|
// Focus+Hover+Selected state doesn't need to be specified
|
|
195
195
|
// '&.Mui-selected.Mui-focusVisible:hover': {
|
|
196
196
|
// },
|
|
197
197
|
}
|
|
198
|
-
})),
|
|
198
|
+
})), $e = 7, eo = $(Xe)(({ theme: e }) => ({
|
|
199
199
|
backgroundColor: "#e8e8e8",
|
|
200
200
|
color: "inherit",
|
|
201
201
|
"& .MuiListItem-root": {
|
|
@@ -204,91 +204,91 @@ const te = Wt(null), Ge = {}, Ve = {}, Xe = ({
|
|
|
204
204
|
"& .MuiListItemButton-root": {
|
|
205
205
|
" .MuiListItemIcon-root": {
|
|
206
206
|
color: "inherit",
|
|
207
|
-
padding: `${
|
|
207
|
+
padding: `${$e}px`
|
|
208
208
|
},
|
|
209
209
|
// Focus state
|
|
210
210
|
"&.Mui-focusVisible": {
|
|
211
|
-
backgroundColor:
|
|
211
|
+
backgroundColor: e.palette.grey[700]
|
|
212
212
|
},
|
|
213
213
|
// Selected state
|
|
214
214
|
"&.Mui-selected": {
|
|
215
215
|
borderLeftStyle: "solid",
|
|
216
216
|
borderLeftWidth: "7px",
|
|
217
|
-
borderLeftColor:
|
|
218
|
-
paddingLeft: `calc(${
|
|
217
|
+
borderLeftColor: e.palette.primary.main,
|
|
218
|
+
paddingLeft: `calc(${e.spacing(2)} - ${$e}px)`
|
|
219
219
|
},
|
|
220
220
|
// Hover state
|
|
221
221
|
"&:hover": {
|
|
222
|
-
backgroundColor:
|
|
222
|
+
backgroundColor: e.palette.primary.dark
|
|
223
223
|
},
|
|
224
224
|
// Focus+Selected state
|
|
225
225
|
"&.Mui-selected.Mui-focusVisible": {
|
|
226
|
-
backgroundColor:
|
|
226
|
+
backgroundColor: e.palette.grey[700]
|
|
227
227
|
},
|
|
228
228
|
// Hover+Selected state
|
|
229
229
|
"&.Mui-selected:hover": {
|
|
230
|
-
backgroundColor:
|
|
230
|
+
backgroundColor: e.palette.primary.dark
|
|
231
231
|
}
|
|
232
232
|
// Focus+Hover+Selected state doesn't need to be specified
|
|
233
233
|
// '&.Mui-selected.Mui-focusVisible:hover': {
|
|
234
234
|
// },
|
|
235
235
|
}
|
|
236
236
|
}));
|
|
237
|
-
function
|
|
238
|
-
"data-testid":
|
|
239
|
-
children:
|
|
237
|
+
function to({
|
|
238
|
+
"data-testid": e,
|
|
239
|
+
children: t
|
|
240
240
|
}) {
|
|
241
|
-
const { open: n } =
|
|
242
|
-
return /* @__PURE__ */ c(
|
|
243
|
-
/* @__PURE__ */ o(
|
|
241
|
+
const { open: n } = jt();
|
|
242
|
+
return /* @__PURE__ */ c(Wt, { className: _.root, "data-testid": e, children: [
|
|
243
|
+
/* @__PURE__ */ o(Et, {}),
|
|
244
244
|
/* @__PURE__ */ o(
|
|
245
|
-
|
|
245
|
+
Ut,
|
|
246
246
|
{
|
|
247
247
|
variant: "permanent",
|
|
248
248
|
anchor: "left",
|
|
249
249
|
transitionDuration: null,
|
|
250
250
|
open: n,
|
|
251
|
-
children:
|
|
251
|
+
children: t
|
|
252
252
|
}
|
|
253
253
|
)
|
|
254
254
|
] });
|
|
255
255
|
}
|
|
256
|
-
const
|
|
257
|
-
isOpen:
|
|
258
|
-
dialogTitle:
|
|
256
|
+
const Yt = ({
|
|
257
|
+
isOpen: e,
|
|
258
|
+
dialogTitle: t,
|
|
259
259
|
children: n,
|
|
260
260
|
maxWidth: i,
|
|
261
261
|
primaryButton: a,
|
|
262
262
|
secondaryButton: l,
|
|
263
263
|
onClose: p
|
|
264
264
|
}) => {
|
|
265
|
-
var d,
|
|
266
|
-
const [u, s] =
|
|
265
|
+
var d, v;
|
|
266
|
+
const [u, s] = k(!1);
|
|
267
267
|
return /* @__PURE__ */ c(
|
|
268
|
-
|
|
268
|
+
Ft,
|
|
269
269
|
{
|
|
270
|
-
open:
|
|
270
|
+
open: e,
|
|
271
271
|
onClose: () => {
|
|
272
272
|
u || p();
|
|
273
273
|
},
|
|
274
274
|
fullWidth: !0,
|
|
275
275
|
maxWidth: i != null ? i : "xs",
|
|
276
276
|
children: [
|
|
277
|
-
/* @__PURE__ */ o(
|
|
278
|
-
/* @__PURE__ */ o(
|
|
279
|
-
/* @__PURE__ */ c(
|
|
277
|
+
/* @__PURE__ */ o(yt, { children: t }),
|
|
278
|
+
/* @__PURE__ */ o(Lt, { sx: { "& > :last-child": { marginBottom: 0 } }, children: n }),
|
|
279
|
+
/* @__PURE__ */ c(Pt, { children: [
|
|
280
280
|
/* @__PURE__ */ o(
|
|
281
|
-
|
|
281
|
+
ke,
|
|
282
282
|
{
|
|
283
283
|
onClick: (d = l == null ? void 0 : l.onClick) != null ? d : p,
|
|
284
284
|
"data-testid": l == null ? void 0 : l.testId,
|
|
285
285
|
disabled: (l == null ? void 0 : l.disabled) || u,
|
|
286
286
|
color: l == null ? void 0 : l.buttonColor,
|
|
287
|
-
children: (
|
|
287
|
+
children: (v = l == null ? void 0 : l.text) != null ? v : "Cancel"
|
|
288
288
|
}
|
|
289
289
|
),
|
|
290
290
|
a && /* @__PURE__ */ o(
|
|
291
|
-
|
|
291
|
+
ke,
|
|
292
292
|
{
|
|
293
293
|
onClick: () => J(void 0, null, function* () {
|
|
294
294
|
var f;
|
|
@@ -304,29 +304,29 @@ const Qe = ({
|
|
|
304
304
|
]
|
|
305
305
|
}
|
|
306
306
|
);
|
|
307
|
-
},
|
|
308
|
-
topStripe: `${
|
|
309
|
-
titleBar: `${
|
|
310
|
-
titleSlider: `${
|
|
311
|
-
titleText: `${
|
|
312
|
-
leftPanelButton: `${
|
|
313
|
-
rightPanelButton: `${
|
|
314
|
-
},
|
|
315
|
-
shouldForwardProp: (
|
|
316
|
-
name:
|
|
317
|
-
})(({ theme:
|
|
307
|
+
}, Jt = 24, Kt = 64, L = "TopBar", A = {
|
|
308
|
+
topStripe: `${L}-topStripe`,
|
|
309
|
+
titleBar: `${L}-titleBar`,
|
|
310
|
+
titleSlider: `${L}-titleSlider`,
|
|
311
|
+
titleText: `${L}-titleText`,
|
|
312
|
+
leftPanelButton: `${L}-leftPanelButton`,
|
|
313
|
+
rightPanelButton: `${L}-leftPanelButton`
|
|
314
|
+
}, Zt = ge("div", {
|
|
315
|
+
shouldForwardProp: (e) => !["leftPanel", "rightPanel"].includes(e),
|
|
316
|
+
name: L
|
|
317
|
+
})(({ theme: e, leftPanel: t, rightPanel: n }) => {
|
|
318
318
|
var i, a;
|
|
319
319
|
return {
|
|
320
320
|
width: "100%",
|
|
321
321
|
[`& .${A.topStripe}`]: {
|
|
322
322
|
width: "100%",
|
|
323
|
-
height: `${
|
|
324
|
-
backgroundColor:
|
|
323
|
+
height: `${Jt}px`,
|
|
324
|
+
backgroundColor: e.palette.primary.main
|
|
325
325
|
},
|
|
326
326
|
[`& .${A.titleBar}`]: {
|
|
327
|
-
backgroundColor:
|
|
328
|
-
height: `${
|
|
329
|
-
padding:
|
|
327
|
+
backgroundColor: e.palette.primary.light,
|
|
328
|
+
height: `${Kt}px`,
|
|
329
|
+
padding: e.spacing(0, 3),
|
|
330
330
|
width: "100%"
|
|
331
331
|
},
|
|
332
332
|
[`& .${A.titleSlider}`]: r(r({
|
|
@@ -334,12 +334,12 @@ const Qe = ({
|
|
|
334
334
|
display: "flex",
|
|
335
335
|
alignItems: "center",
|
|
336
336
|
color: "white",
|
|
337
|
-
transition:
|
|
338
|
-
easing:
|
|
339
|
-
duration:
|
|
337
|
+
transition: e.transitions.create("margin", {
|
|
338
|
+
easing: e.transitions.easing.sharp,
|
|
339
|
+
duration: e.transitions.duration.leavingScreen
|
|
340
340
|
}),
|
|
341
341
|
[`& .${A.leftPanelButton}`]: {
|
|
342
|
-
marginRight:
|
|
342
|
+
marginRight: e.spacing(2),
|
|
343
343
|
flexGrow: 0
|
|
344
344
|
},
|
|
345
345
|
[`& .${A.titleText}`]: {
|
|
@@ -348,46 +348,46 @@ const Qe = ({
|
|
|
348
348
|
[`& .${A.rightPanelButton}`]: {
|
|
349
349
|
flexGrow: 0
|
|
350
350
|
}
|
|
351
|
-
}, (
|
|
352
|
-
transition:
|
|
353
|
-
easing:
|
|
354
|
-
duration:
|
|
351
|
+
}, (t == null ? void 0 : t.open) && {
|
|
352
|
+
transition: e.transitions.create("margin", {
|
|
353
|
+
easing: e.transitions.easing.easeOut,
|
|
354
|
+
duration: e.transitions.duration.enteringScreen
|
|
355
355
|
}),
|
|
356
|
-
marginLeft: `${(i =
|
|
356
|
+
marginLeft: `${(i = t == null ? void 0 : t.width) != null ? i : 0}px`
|
|
357
357
|
}), (n == null ? void 0 : n.open) && {
|
|
358
|
-
transition:
|
|
359
|
-
easing:
|
|
360
|
-
duration:
|
|
358
|
+
transition: e.transitions.create("margin", {
|
|
359
|
+
easing: e.transitions.easing.easeOut,
|
|
360
|
+
duration: e.transitions.duration.enteringScreen
|
|
361
361
|
}),
|
|
362
362
|
marginRight: `${(a = n == null ? void 0 : n.width) != null ? a : 0}px`
|
|
363
363
|
})
|
|
364
364
|
};
|
|
365
365
|
});
|
|
366
|
-
function
|
|
367
|
-
titleText:
|
|
368
|
-
leftPanel:
|
|
366
|
+
function en({
|
|
367
|
+
titleText: e = "",
|
|
368
|
+
leftPanel: t,
|
|
369
369
|
rightPanel: n,
|
|
370
370
|
"data-testid": i
|
|
371
371
|
}) {
|
|
372
|
-
return /* @__PURE__ */ c(
|
|
372
|
+
return /* @__PURE__ */ c(Zt, { leftPanel: t, rightPanel: n, "data-testid": i, children: [
|
|
373
373
|
/* @__PURE__ */ o("div", { className: A.topStripe }),
|
|
374
|
-
/* @__PURE__ */ o("div", { className: A.titleBar, children: /* @__PURE__ */ c(
|
|
375
|
-
|
|
374
|
+
/* @__PURE__ */ o("div", { className: A.titleBar, children: /* @__PURE__ */ c(x, { className: A.titleSlider, children: [
|
|
375
|
+
t !== void 0 && !t.open && t.showOpenArrow && /* @__PURE__ */ c(
|
|
376
376
|
V,
|
|
377
377
|
{
|
|
378
378
|
className: A.leftPanelButton,
|
|
379
379
|
color: "inherit",
|
|
380
380
|
"aria-label": "Open left side panel",
|
|
381
|
-
onClick:
|
|
381
|
+
onClick: t == null ? void 0 : t.onOpen,
|
|
382
382
|
edge: "start",
|
|
383
383
|
size: "large",
|
|
384
384
|
children: [
|
|
385
385
|
" ",
|
|
386
|
-
/* @__PURE__ */ o(
|
|
386
|
+
/* @__PURE__ */ o(qe, {})
|
|
387
387
|
]
|
|
388
388
|
}
|
|
389
389
|
),
|
|
390
|
-
/* @__PURE__ */ o(
|
|
390
|
+
/* @__PURE__ */ o(B, { className: A.titleText, variant: "h6", noWrap: !0, children: e }),
|
|
391
391
|
n !== void 0 && !n.open && n.showOpenArrow && /* @__PURE__ */ c(
|
|
392
392
|
V,
|
|
393
393
|
{
|
|
@@ -399,15 +399,15 @@ function Ze({
|
|
|
399
399
|
size: "large",
|
|
400
400
|
children: [
|
|
401
401
|
" ",
|
|
402
|
-
/* @__PURE__ */ o(
|
|
402
|
+
/* @__PURE__ */ o(je, {})
|
|
403
403
|
]
|
|
404
404
|
}
|
|
405
405
|
)
|
|
406
406
|
] }) })
|
|
407
407
|
] });
|
|
408
408
|
}
|
|
409
|
-
const
|
|
410
|
-
shouldForwardProp: (
|
|
409
|
+
const et = 400, tn = ge(he, {
|
|
410
|
+
shouldForwardProp: (e) => (
|
|
411
411
|
// Note we do want anchor to be forwarded to the Drawer component
|
|
412
412
|
![
|
|
413
413
|
"width",
|
|
@@ -416,19 +416,19 @@ const ee = 400, tn = ft(gt, {
|
|
|
416
416
|
"navBarOpen",
|
|
417
417
|
"navBarWidthOpen",
|
|
418
418
|
"navBarWidthClosed"
|
|
419
|
-
].includes(
|
|
419
|
+
].includes(e)
|
|
420
420
|
),
|
|
421
421
|
name: "SidePanelDrawer"
|
|
422
422
|
})(
|
|
423
|
-
({ width:
|
|
424
|
-
width:
|
|
423
|
+
({ width: e, debugOpacity: t = !1, anchor: n, navBarOpen: i, navBarWidthOpen: a, navBarWidthClosed: l }) => ({
|
|
424
|
+
width: e,
|
|
425
425
|
"& .MuiDrawer-paper": r(r({
|
|
426
426
|
position: "absolute",
|
|
427
|
-
width:
|
|
427
|
+
width: e,
|
|
428
428
|
boxSizing: "border-box",
|
|
429
429
|
border: "unset",
|
|
430
430
|
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)"
|
|
431
|
-
},
|
|
431
|
+
}, t && {
|
|
432
432
|
opacity: "50%"
|
|
433
433
|
}), n === "left" && r({
|
|
434
434
|
marginLeft: `${l}px`
|
|
@@ -436,15 +436,15 @@ const ee = 400, tn = ft(gt, {
|
|
|
436
436
|
marginLeft: `${a}px`
|
|
437
437
|
}))
|
|
438
438
|
})
|
|
439
|
-
),
|
|
440
|
-
shouldForwardProp: (
|
|
441
|
-
})(({ theme:
|
|
439
|
+
), nn = ge(x, {
|
|
440
|
+
shouldForwardProp: (e) => !["anchor"].includes(e)
|
|
441
|
+
})(({ theme: e, anchor: t }) => w(r({
|
|
442
442
|
display: "flex",
|
|
443
443
|
alignItems: "center",
|
|
444
|
-
padding:
|
|
445
|
-
},
|
|
446
|
-
justifyContent:
|
|
447
|
-
backgroundColor:
|
|
444
|
+
padding: e.spacing(2)
|
|
445
|
+
}, e.mixins.toolbar), {
|
|
446
|
+
justifyContent: t === "left" ? "space-between" : "flex-start",
|
|
447
|
+
backgroundColor: e.palette.primary.light,
|
|
448
448
|
height: "88px",
|
|
449
449
|
"&,*": {
|
|
450
450
|
color: "white"
|
|
@@ -453,22 +453,22 @@ const ee = 400, tn = ft(gt, {
|
|
|
453
453
|
fontSize: "22px"
|
|
454
454
|
},
|
|
455
455
|
" .MuiButtonBase-root": {
|
|
456
|
-
marginRight:
|
|
456
|
+
marginRight: t === "right" ? e.spacing(2) : 0
|
|
457
457
|
}
|
|
458
458
|
}));
|
|
459
|
-
function
|
|
460
|
-
children:
|
|
461
|
-
anchor:
|
|
459
|
+
function Ee({
|
|
460
|
+
children: e,
|
|
461
|
+
anchor: t = "left",
|
|
462
462
|
open: n,
|
|
463
463
|
onClose: i = () => {
|
|
464
464
|
},
|
|
465
465
|
titleText: a = "",
|
|
466
|
-
width: l =
|
|
466
|
+
width: l = et,
|
|
467
467
|
showCloseArrow: p = !0,
|
|
468
468
|
debugOpacity: u = !1,
|
|
469
469
|
headerBoxProps: s = {},
|
|
470
470
|
onOpened: d,
|
|
471
|
-
onClosed:
|
|
471
|
+
onClosed: v,
|
|
472
472
|
"data-testid": f,
|
|
473
473
|
navBarOpen: C = !1,
|
|
474
474
|
navBarWidthOpen: m = 0,
|
|
@@ -479,10 +479,10 @@ function Nt({
|
|
|
479
479
|
{
|
|
480
480
|
SlideProps: {
|
|
481
481
|
onEntered: () => d == null ? void 0 : d(),
|
|
482
|
-
onExited: () =>
|
|
482
|
+
onExited: () => v == null ? void 0 : v()
|
|
483
483
|
},
|
|
484
484
|
variant: "persistent",
|
|
485
|
-
anchor:
|
|
485
|
+
anchor: t,
|
|
486
486
|
open: n,
|
|
487
487
|
width: l,
|
|
488
488
|
debugOpacity: u,
|
|
@@ -491,69 +491,69 @@ function Nt({
|
|
|
491
491
|
navBarWidthOpen: m,
|
|
492
492
|
navBarWidthClosed: T,
|
|
493
493
|
children: [
|
|
494
|
-
/* @__PURE__ */ o(
|
|
495
|
-
/* @__PURE__ */ o(
|
|
494
|
+
/* @__PURE__ */ o(nn, w(r({ anchor: t }, s), { children: t === "left" ? /* @__PURE__ */ c(y, { children: [
|
|
495
|
+
/* @__PURE__ */ o(B, { variant: "h6", color: "inherit", component: "div", children: a }),
|
|
496
496
|
p && /* @__PURE__ */ c(V, { onClick: i, size: "large", "aria-label": "Close left side panel", children: [
|
|
497
|
-
/* @__PURE__ */ o(
|
|
497
|
+
/* @__PURE__ */ o(je, { "data-testid": "arrowbackicon" }),
|
|
498
498
|
" "
|
|
499
499
|
] })
|
|
500
|
-
] }) : /* @__PURE__ */ c(
|
|
500
|
+
] }) : /* @__PURE__ */ c(y, { children: [
|
|
501
501
|
p && /* @__PURE__ */ c(V, { onClick: i, size: "large", "aria-label": "Close right side panel", children: [
|
|
502
|
-
/* @__PURE__ */ o(
|
|
502
|
+
/* @__PURE__ */ o(qe, {}),
|
|
503
503
|
" "
|
|
504
504
|
] }),
|
|
505
|
-
/* @__PURE__ */ o(
|
|
505
|
+
/* @__PURE__ */ o(B, { variant: "h6", color: "inherit", component: "div", children: a })
|
|
506
506
|
] }) })),
|
|
507
|
-
|
|
507
|
+
e
|
|
508
508
|
]
|
|
509
509
|
}
|
|
510
510
|
);
|
|
511
511
|
}
|
|
512
|
-
const
|
|
513
|
-
shouldForwardProp: (
|
|
512
|
+
const on = $(x, {
|
|
513
|
+
shouldForwardProp: (e) => !["leftPanel", "rightPanel"].includes(e),
|
|
514
514
|
name: "PanelAwareMargins"
|
|
515
|
-
})(({ theme:
|
|
515
|
+
})(({ theme: e, leftPanel: t, rightPanel: n }) => {
|
|
516
516
|
var i, a;
|
|
517
517
|
return r(r({
|
|
518
|
-
transition:
|
|
519
|
-
easing:
|
|
520
|
-
duration:
|
|
518
|
+
transition: e.transitions.create("margin", {
|
|
519
|
+
easing: e.transitions.easing.sharp,
|
|
520
|
+
duration: e.transitions.duration.leavingScreen
|
|
521
521
|
})
|
|
522
|
-
}, (
|
|
523
|
-
transition:
|
|
524
|
-
easing:
|
|
525
|
-
duration:
|
|
522
|
+
}, (t == null ? void 0 : t.open) && {
|
|
523
|
+
transition: e.transitions.create("margin", {
|
|
524
|
+
easing: e.transitions.easing.easeOut,
|
|
525
|
+
duration: e.transitions.duration.enteringScreen
|
|
526
526
|
}),
|
|
527
|
-
marginLeft: `${(i =
|
|
527
|
+
marginLeft: `${(i = t == null ? void 0 : t.width) != null ? i : 0}px`
|
|
528
528
|
}), (n == null ? void 0 : n.open) && {
|
|
529
|
-
transition:
|
|
530
|
-
easing:
|
|
531
|
-
duration:
|
|
529
|
+
transition: e.transitions.create("margin", {
|
|
530
|
+
easing: e.transitions.easing.easeOut,
|
|
531
|
+
duration: e.transitions.duration.enteringScreen
|
|
532
532
|
}),
|
|
533
533
|
marginRight: `${(a = n == null ? void 0 : n.width) != null ? a : 0}px`
|
|
534
534
|
});
|
|
535
|
-
}),
|
|
535
|
+
}), rn = $(Ge, {
|
|
536
536
|
name: "PageContainer"
|
|
537
|
-
})(({ theme:
|
|
537
|
+
})(({ theme: e }) => ({
|
|
538
538
|
// Horizontal padding comes from the Container's gutter
|
|
539
|
-
paddingTop:
|
|
540
|
-
paddingBottom:
|
|
541
|
-
})),
|
|
539
|
+
paddingTop: e.spacing(3),
|
|
540
|
+
paddingBottom: e.spacing(3)
|
|
541
|
+
})), pe = !1, ue = !1, K = {
|
|
542
542
|
titleText: "",
|
|
543
543
|
flavour: "push",
|
|
544
|
-
width:
|
|
544
|
+
width: et,
|
|
545
545
|
arrowButtons: "both",
|
|
546
546
|
startOpen: !1,
|
|
547
547
|
open: void 0,
|
|
548
548
|
onChangeOpen: void 0,
|
|
549
|
-
content: /* @__PURE__ */ o(
|
|
549
|
+
content: /* @__PURE__ */ o(y, {}),
|
|
550
550
|
onOpened: void 0,
|
|
551
551
|
onClosed: void 0,
|
|
552
552
|
dataTestId: void 0
|
|
553
553
|
};
|
|
554
|
-
function
|
|
555
|
-
children:
|
|
556
|
-
titleText:
|
|
554
|
+
function no({
|
|
555
|
+
children: e,
|
|
556
|
+
titleText: t = "",
|
|
557
557
|
leftPanel: n,
|
|
558
558
|
rightPanel: i,
|
|
559
559
|
sidePanelsAreMutuallyExclusive: a = !0,
|
|
@@ -562,256 +562,254 @@ function Zn({
|
|
|
562
562
|
pageContentDataTestId: u,
|
|
563
563
|
topBarDataTestId: s,
|
|
564
564
|
navBarOpen: d,
|
|
565
|
-
navBarWidthOpen:
|
|
565
|
+
navBarWidthOpen: v,
|
|
566
566
|
navBarWidthClosed: f
|
|
567
567
|
}) {
|
|
568
|
-
const [C, m] =
|
|
568
|
+
const [C, m] = k(pe), [T, I] = k(ue), [S, b] = k(pe), [O, H] = k(ue), R = n !== void 0, W = i !== void 0, {
|
|
569
569
|
titleText: D,
|
|
570
570
|
content: X,
|
|
571
571
|
flavour: q,
|
|
572
572
|
open: z,
|
|
573
|
-
onChangeOpen:
|
|
573
|
+
onChangeOpen: G,
|
|
574
574
|
width: h,
|
|
575
575
|
arrowButtons: g,
|
|
576
576
|
startOpen: M,
|
|
577
|
-
onOpened:
|
|
578
|
-
onClosed:
|
|
579
|
-
dataTestId:
|
|
580
|
-
} = n ? r(r({},
|
|
581
|
-
titleText:
|
|
582
|
-
content:
|
|
583
|
-
flavour:
|
|
584
|
-
open:
|
|
585
|
-
onChangeOpen:
|
|
586
|
-
width:
|
|
577
|
+
onOpened: ct,
|
|
578
|
+
onClosed: pt,
|
|
579
|
+
dataTestId: ut
|
|
580
|
+
} = n ? r(r({}, K), n) : r({}, K), {
|
|
581
|
+
titleText: ht,
|
|
582
|
+
content: gt,
|
|
583
|
+
flavour: ve,
|
|
584
|
+
open: ie,
|
|
585
|
+
onChangeOpen: xe,
|
|
586
|
+
width: re,
|
|
587
587
|
arrowButtons: j,
|
|
588
588
|
startOpen: Q,
|
|
589
|
-
onOpened:
|
|
590
|
-
onClosed:
|
|
591
|
-
dataTestId:
|
|
592
|
-
} = i ? r(r({},
|
|
593
|
-
|
|
594
|
-
M !==
|
|
595
|
-
}, [M]),
|
|
596
|
-
Q !==
|
|
589
|
+
onOpened: ft,
|
|
590
|
+
onClosed: mt,
|
|
591
|
+
dataTestId: vt
|
|
592
|
+
} = i ? r(r({}, K), i) : r({}, K);
|
|
593
|
+
te(() => {
|
|
594
|
+
M !== pe && (m(M), b(M));
|
|
595
|
+
}, [M]), te(() => {
|
|
596
|
+
Q !== ue && (I(Q), H(Q));
|
|
597
597
|
}, [Q]);
|
|
598
|
-
const
|
|
599
|
-
z === void 0 && (m(
|
|
600
|
-
},
|
|
601
|
-
|
|
598
|
+
const ae = z === void 0 ? C : z, se = ie === void 0 ? T : ie, Ce = (N) => {
|
|
599
|
+
z === void 0 && (m(N), a && W && (N ? (I(!1), H(T)) : I(O))), G && G(N);
|
|
600
|
+
}, we = (N) => {
|
|
601
|
+
ie === void 0 && (I(N), a && R && (N ? (m(!1), b(C)) : m(S))), xe && xe(N);
|
|
602
602
|
};
|
|
603
|
-
return /* @__PURE__ */ c(
|
|
603
|
+
return /* @__PURE__ */ c(x, { children: [
|
|
604
604
|
R && /* @__PURE__ */ o(
|
|
605
|
-
|
|
605
|
+
Ee,
|
|
606
606
|
{
|
|
607
|
-
"data-testid":
|
|
607
|
+
"data-testid": ut,
|
|
608
608
|
anchor: "left",
|
|
609
|
-
open:
|
|
610
|
-
onClose: () =>
|
|
609
|
+
open: ae,
|
|
610
|
+
onClose: () => Ce(!1),
|
|
611
611
|
width: h,
|
|
612
612
|
titleText: D,
|
|
613
613
|
debugOpacity: l,
|
|
614
614
|
showCloseArrow: g === "both" || g === "close",
|
|
615
|
-
onOpened:
|
|
616
|
-
onClosed:
|
|
615
|
+
onOpened: ct,
|
|
616
|
+
onClosed: pt,
|
|
617
617
|
navBarOpen: d,
|
|
618
|
-
navBarWidthOpen:
|
|
618
|
+
navBarWidthOpen: v,
|
|
619
619
|
navBarWidthClosed: f,
|
|
620
620
|
children: X
|
|
621
621
|
}
|
|
622
622
|
),
|
|
623
623
|
W && /* @__PURE__ */ o(
|
|
624
|
-
|
|
624
|
+
Ee,
|
|
625
625
|
{
|
|
626
|
-
"data-testid":
|
|
626
|
+
"data-testid": vt,
|
|
627
627
|
anchor: "right",
|
|
628
|
-
open:
|
|
629
|
-
onClose: () =>
|
|
630
|
-
width:
|
|
631
|
-
titleText:
|
|
628
|
+
open: se,
|
|
629
|
+
onClose: () => we(!1),
|
|
630
|
+
width: re,
|
|
631
|
+
titleText: ht,
|
|
632
632
|
debugOpacity: l,
|
|
633
633
|
showCloseArrow: j === "both" || j === "close",
|
|
634
|
-
onOpened:
|
|
635
|
-
onClosed:
|
|
634
|
+
onOpened: ft,
|
|
635
|
+
onClosed: mt,
|
|
636
636
|
navBarOpen: d,
|
|
637
|
-
navBarWidthOpen:
|
|
637
|
+
navBarWidthOpen: v,
|
|
638
638
|
navBarWidthClosed: f,
|
|
639
|
-
children:
|
|
639
|
+
children: gt
|
|
640
640
|
}
|
|
641
641
|
),
|
|
642
642
|
/* @__PURE__ */ o(
|
|
643
|
-
|
|
643
|
+
en,
|
|
644
644
|
r(r({
|
|
645
|
-
titleText:
|
|
645
|
+
titleText: t,
|
|
646
646
|
"data-testid": s
|
|
647
647
|
}, R && q === "push" ? {
|
|
648
648
|
leftPanel: {
|
|
649
|
-
open:
|
|
649
|
+
open: ae,
|
|
650
650
|
width: h,
|
|
651
|
-
onOpen: () =>
|
|
651
|
+
onOpen: () => Ce(!0),
|
|
652
652
|
showOpenArrow: g === "both" || g === "open"
|
|
653
653
|
}
|
|
654
|
-
} : {}), W &&
|
|
654
|
+
} : {}), W && ve === "push" ? {
|
|
655
655
|
rightPanel: {
|
|
656
|
-
open:
|
|
657
|
-
width:
|
|
658
|
-
onOpen: () =>
|
|
656
|
+
open: se,
|
|
657
|
+
width: re,
|
|
658
|
+
onOpen: () => we(!0),
|
|
659
659
|
showOpenArrow: j === "both" || j === "open"
|
|
660
660
|
}
|
|
661
661
|
} : {})
|
|
662
662
|
),
|
|
663
663
|
/* @__PURE__ */ o(
|
|
664
|
-
|
|
664
|
+
on,
|
|
665
665
|
w(r(r({}, q === "push" ? {
|
|
666
666
|
leftPanel: {
|
|
667
|
-
open:
|
|
667
|
+
open: ae,
|
|
668
668
|
width: h
|
|
669
669
|
}
|
|
670
|
-
} : {}),
|
|
670
|
+
} : {}), ve === "push" ? {
|
|
671
671
|
rightPanel: {
|
|
672
|
-
open:
|
|
673
|
-
width:
|
|
672
|
+
open: se,
|
|
673
|
+
width: re
|
|
674
674
|
}
|
|
675
675
|
} : {}), {
|
|
676
|
-
children: /* @__PURE__ */ o(
|
|
676
|
+
children: /* @__PURE__ */ o(rn, w(r({ "data-testid": u }, p), { children: e }))
|
|
677
677
|
})
|
|
678
678
|
)
|
|
679
679
|
] });
|
|
680
680
|
}
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
681
|
+
function an({ links: e }) {
|
|
682
|
+
return /* @__PURE__ */ o("div", { children: "LinksMenu not implemented yet" });
|
|
683
|
+
}
|
|
684
|
+
const Z = "Navbar", U = {
|
|
685
|
+
root: `${Z}-root`,
|
|
686
|
+
menuButton: `${Z}-menuButton`,
|
|
687
|
+
hide: `${Z}-hide`,
|
|
688
|
+
content: `${Z}-content`
|
|
686
689
|
// userInfoHolder: `${PREFIX}-userInfoHolder`,
|
|
687
690
|
// settings: `${PREFIX}-settings`,
|
|
688
691
|
// pieChartIcon: `${PREFIX}-pieChartIcon`,
|
|
689
|
-
},
|
|
690
|
-
[`&.${
|
|
692
|
+
}, sn = $(x, { name: "NavBar" })(({ theme: e }) => ({
|
|
693
|
+
[`&.${U.root}`]: {
|
|
691
694
|
display: "flex"
|
|
692
695
|
},
|
|
693
|
-
[`& .${
|
|
696
|
+
[`& .${U.menuButton}`]: {
|
|
694
697
|
marginRight: 36
|
|
695
698
|
},
|
|
696
|
-
[`& .${
|
|
699
|
+
[`& .${U.hide}`]: {
|
|
697
700
|
display: "none"
|
|
698
701
|
},
|
|
699
|
-
[`& .${
|
|
702
|
+
[`& .${U.content}`]: {
|
|
700
703
|
flexGrow: 1,
|
|
701
|
-
padding:
|
|
704
|
+
padding: e.spacing(3)
|
|
702
705
|
}
|
|
703
706
|
// [`& .${classes.userInfoHolder}`]: {
|
|
704
707
|
// height: '148px',
|
|
705
708
|
// marginTop: '64px',
|
|
706
709
|
// marginBottom: '16px',
|
|
707
710
|
// },
|
|
708
|
-
})), ne = (t,
|
|
711
|
+
})), ne = (e, t, n) => e.transitions.create(t, {
|
|
712
|
+
easing: e.transitions.easing.sharp,
|
|
713
|
+
duration: n === "leaving" ? e.transitions.duration.leavingScreen : e.transitions.duration.enteringScreen
|
|
714
|
+
}), tt = (e, t) => {
|
|
709
715
|
var n, i;
|
|
710
716
|
return {
|
|
711
|
-
height: `calc(100vh - ${
|
|
712
|
-
top:
|
|
717
|
+
height: `calc(100vh - ${t}px)`,
|
|
718
|
+
top: t,
|
|
713
719
|
overflowX: "hidden",
|
|
714
720
|
overflowY: "hidden",
|
|
715
721
|
color: "inherit",
|
|
716
|
-
backgroundColor: (i = (n =
|
|
722
|
+
backgroundColor: (i = (n = e == null ? void 0 : e.navBar) == null ? void 0 : n.backgroundColor) != null ? i : "white"
|
|
717
723
|
// Provide default so tests don't need to wrap theme provider
|
|
718
724
|
};
|
|
719
|
-
},
|
|
720
|
-
width:
|
|
721
|
-
transition:
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
}, ne(t, n)), Ft = (t, e, n) => r({
|
|
726
|
-
width: e,
|
|
727
|
-
transition: t.transitions.create("width", {
|
|
728
|
-
easing: t.transitions.easing.sharp,
|
|
729
|
-
duration: t.transitions.duration.leavingScreen
|
|
730
|
-
}),
|
|
725
|
+
}, Ne = (e, t, n) => r({
|
|
726
|
+
width: t,
|
|
727
|
+
transition: ne(e, "width", "entering")
|
|
728
|
+
}, tt(e, n)), Fe = (e, t, n) => r({
|
|
729
|
+
width: t,
|
|
730
|
+
transition: ne(e, "width", "leaving"),
|
|
731
731
|
overflowX: "hidden"
|
|
732
|
-
},
|
|
733
|
-
shouldForwardProp: (
|
|
734
|
-
})(({ theme:
|
|
732
|
+
}, tt(e, n)), ln = $(he, {
|
|
733
|
+
shouldForwardProp: (e) => !["open", "widthOpen", "widthClosed", "offsetTop"].includes(e)
|
|
734
|
+
})(({ theme: e, open: t, widthOpen: n, widthClosed: i, offsetTop: a }) => r(r({
|
|
735
735
|
flexShrink: 0,
|
|
736
736
|
whiteSpace: "nowrap",
|
|
737
737
|
boxSizing: "border-box",
|
|
738
738
|
display: "flex",
|
|
739
739
|
flexDirection: "column"
|
|
740
|
-
},
|
|
741
|
-
"& .MuiDrawer-paper":
|
|
742
|
-
})), !
|
|
743
|
-
"& .MuiDrawer-paper":
|
|
740
|
+
}, t && w(r({}, Ne(e, n, a)), {
|
|
741
|
+
"& .MuiDrawer-paper": Ne(e, n, a)
|
|
742
|
+
})), !t && w(r({}, Fe(e, i, a)), {
|
|
743
|
+
"& .MuiDrawer-paper": Fe(e, i, a)
|
|
744
744
|
})));
|
|
745
|
-
function
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
for (let n = 0, i = t.length; n < i; n++) {
|
|
751
|
-
const a = t.charCodeAt(n);
|
|
752
|
-
e = (e << 5) - e + a, e |= 0;
|
|
745
|
+
function dn(e) {
|
|
746
|
+
let t = 0;
|
|
747
|
+
for (let n = 0, i = e.length; n < i; n++) {
|
|
748
|
+
const a = e.charCodeAt(n);
|
|
749
|
+
t = (t << 5) - t + a, t |= 0;
|
|
753
750
|
}
|
|
754
|
-
return
|
|
751
|
+
return t;
|
|
755
752
|
}
|
|
756
|
-
const
|
|
757
|
-
function
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
navBarWidthClosed: i,
|
|
762
|
-
navBarWidthOpen: a
|
|
763
|
-
}) {
|
|
764
|
-
return /* @__PURE__ */ o(v, { sx: { paddingTop: 3 }, children: /* @__PURE__ */ o(
|
|
765
|
-
v,
|
|
753
|
+
const Pe = ["#A62A21", "#7e3794", "#0B51C1", "#3A6024", "#A81563", "#B3003C"], cn = (e) => e.split(/\s/).map((t) => t.substring(0, 1).toUpperCase()).filter((t) => !!t).slice(0, 2).join("").toUpperCase();
|
|
754
|
+
function pn({ user: e, domainCode: t, open: n }) {
|
|
755
|
+
const i = At();
|
|
756
|
+
return /* @__PURE__ */ c(
|
|
757
|
+
x,
|
|
766
758
|
{
|
|
767
759
|
sx: {
|
|
760
|
+
paddingTop: 3,
|
|
768
761
|
display: "flex",
|
|
769
762
|
alignItems: "center",
|
|
770
|
-
flexDirection: "column"
|
|
763
|
+
flexDirection: "column",
|
|
764
|
+
gap: "8px"
|
|
771
765
|
},
|
|
772
|
-
children:
|
|
766
|
+
children: [
|
|
773
767
|
/* @__PURE__ */ o(
|
|
774
|
-
|
|
768
|
+
x,
|
|
775
769
|
{
|
|
776
770
|
sx: {
|
|
777
|
-
width:
|
|
778
|
-
|
|
779
|
-
|
|
771
|
+
width: n ? "5rem" : "2rem",
|
|
772
|
+
transition: n ? ne(i, ["width", "height"], "entering") : ne(i, ["width", "height"], "leaving"),
|
|
773
|
+
aspectRatio: 1
|
|
780
774
|
},
|
|
781
|
-
children:
|
|
782
|
-
|
|
775
|
+
children: e != null && e.name ? /* @__PURE__ */ o(
|
|
776
|
+
Ie,
|
|
783
777
|
{
|
|
784
|
-
src:
|
|
778
|
+
src: e == null ? void 0 : e.picture,
|
|
785
779
|
sx: {
|
|
786
780
|
width: "100%",
|
|
787
781
|
height: "100%",
|
|
788
|
-
bgcolor:
|
|
782
|
+
bgcolor: Pe[Math.abs(dn(e.name)) % Pe.length]
|
|
789
783
|
},
|
|
790
|
-
children:
|
|
784
|
+
children: cn(e.name)
|
|
791
785
|
}
|
|
792
|
-
) : /* @__PURE__ */ o(
|
|
786
|
+
) : /* @__PURE__ */ o(Ie, { sx: { width: "100%", height: "100%" } })
|
|
793
787
|
}
|
|
794
788
|
),
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
789
|
+
/* @__PURE__ */ o(
|
|
790
|
+
St,
|
|
791
|
+
{
|
|
792
|
+
sx: { width: "100%" },
|
|
793
|
+
easing: i.transitions.easing.sharp,
|
|
794
|
+
timeout: {
|
|
795
|
+
enter: i.transitions.duration.enteringScreen,
|
|
796
|
+
exit: i.transitions.duration.leavingScreen - 37
|
|
797
|
+
},
|
|
798
|
+
in: n,
|
|
799
|
+
unmountOnExit: !0,
|
|
800
|
+
children: /* @__PURE__ */ c(x, { width: "100%", display: "flex", flexDirection: "column", alignItems: "center", children: [
|
|
801
|
+
e != null && e.name ? /* @__PURE__ */ o(B, { children: e.name }) : /* @__PURE__ */ o(Oe, { animation: !1, width: "50%" }),
|
|
802
|
+
t ? /* @__PURE__ */ o(B, { children: t.toUpperCase() }) : /* @__PURE__ */ o(Oe, { animation: !1, width: "25%" })
|
|
803
|
+
] })
|
|
804
|
+
}
|
|
805
|
+
)
|
|
806
|
+
]
|
|
809
807
|
}
|
|
810
|
-
)
|
|
808
|
+
);
|
|
811
809
|
}
|
|
812
|
-
function
|
|
813
|
-
open:
|
|
814
|
-
offsetTop:
|
|
810
|
+
function un({
|
|
811
|
+
open: e,
|
|
812
|
+
offsetTop: t = 0,
|
|
815
813
|
widthOpen: n,
|
|
816
814
|
widthClosed: i,
|
|
817
815
|
"data-testid": a,
|
|
@@ -821,72 +819,63 @@ function dn({
|
|
|
821
819
|
user: s,
|
|
822
820
|
domainCode: d
|
|
823
821
|
}) {
|
|
824
|
-
return /* @__PURE__ */ o(
|
|
825
|
-
|
|
822
|
+
return /* @__PURE__ */ o(sn, { className: U.root, "data-testid": a, children: /* @__PURE__ */ c(
|
|
823
|
+
ln,
|
|
826
824
|
{
|
|
827
825
|
variant: "permanent",
|
|
828
826
|
anchor: "left",
|
|
829
|
-
open:
|
|
827
|
+
open: e,
|
|
830
828
|
widthOpen: n,
|
|
831
829
|
widthClosed: i,
|
|
832
|
-
offsetTop:
|
|
830
|
+
offsetTop: t,
|
|
833
831
|
PaperProps: {
|
|
834
832
|
component: "nav"
|
|
835
833
|
},
|
|
836
834
|
children: [
|
|
837
|
-
l && /* @__PURE__ */ c(
|
|
835
|
+
l && /* @__PURE__ */ c(x, { flexGrow: "0", children: [
|
|
838
836
|
l,
|
|
839
|
-
/* @__PURE__ */ o(
|
|
837
|
+
/* @__PURE__ */ o(De, { variant: "middle" })
|
|
840
838
|
] }),
|
|
841
|
-
/* @__PURE__ */ o(
|
|
842
|
-
/* @__PURE__ */ c(
|
|
843
|
-
/* @__PURE__ */ o(
|
|
844
|
-
/* @__PURE__ */ o(
|
|
845
|
-
|
|
846
|
-
{
|
|
847
|
-
user: s,
|
|
848
|
-
domainCode: d,
|
|
849
|
-
open: t,
|
|
850
|
-
navBarWidthClosed: i,
|
|
851
|
-
navBarWidthOpen: n
|
|
852
|
-
}
|
|
853
|
-
),
|
|
854
|
-
u && /* @__PURE__ */ o(k, { children: u })
|
|
839
|
+
/* @__PURE__ */ o(x, { flexGrow: "1", children: Array.isArray(p) ? /* @__PURE__ */ o(an, { links: p }) : p }),
|
|
840
|
+
/* @__PURE__ */ c(x, { flexGrow: "0", children: [
|
|
841
|
+
/* @__PURE__ */ o(De, { variant: "middle" }),
|
|
842
|
+
/* @__PURE__ */ o(pn, { user: s, domainCode: d, open: e }),
|
|
843
|
+
u && /* @__PURE__ */ o(y, { children: u })
|
|
855
844
|
] })
|
|
856
845
|
]
|
|
857
846
|
}
|
|
858
847
|
) });
|
|
859
848
|
}
|
|
860
|
-
function
|
|
849
|
+
function hn({ children: e, topBarHeight: t }) {
|
|
861
850
|
return /* @__PURE__ */ o(
|
|
862
|
-
|
|
851
|
+
x,
|
|
863
852
|
{
|
|
864
853
|
sx: {
|
|
865
854
|
overflow: "auto",
|
|
866
|
-
height: `calc(100vh - ${
|
|
855
|
+
height: `calc(100vh - ${t}px)`,
|
|
867
856
|
scrollbarGutter: "stable",
|
|
868
857
|
// scrollbarGutter: 'stable both-edges',
|
|
869
858
|
flexGrow: 1
|
|
870
859
|
},
|
|
871
860
|
children: /* @__PURE__ */ o(
|
|
872
|
-
|
|
861
|
+
Ge,
|
|
873
862
|
{
|
|
874
863
|
component: "main",
|
|
875
864
|
id: "main-content",
|
|
876
865
|
sx: { paddingTop: 3, paddingBottom: 3, flexGrow: 1 },
|
|
877
|
-
children:
|
|
866
|
+
children: e
|
|
878
867
|
}
|
|
879
868
|
)
|
|
880
869
|
}
|
|
881
870
|
);
|
|
882
871
|
}
|
|
883
|
-
const
|
|
884
|
-
titleText: `${
|
|
872
|
+
const gn = 64, fn = 64, mn = 256, me = E(!0), nt = E(mn), ot = E(fn), it = E(""), rt = E(gn), at = E(void 0), vn = "TopBar", xn = {
|
|
873
|
+
titleText: `${vn}-titleText`
|
|
885
874
|
};
|
|
886
|
-
function
|
|
887
|
-
const i =
|
|
875
|
+
function Cn({ titleText: e = "", height: t, "data-testid": n }) {
|
|
876
|
+
const i = _t(me);
|
|
888
877
|
return /* @__PURE__ */ o("header", { "data-testid": n, children: /* @__PURE__ */ c(
|
|
889
|
-
|
|
878
|
+
ze,
|
|
890
879
|
{
|
|
891
880
|
square: !0,
|
|
892
881
|
elevation: 0,
|
|
@@ -899,18 +888,18 @@ function mn({ titleText: t = "", height: e, "data-testid": n }) {
|
|
|
899
888
|
alignItems: "center",
|
|
900
889
|
gap: 2,
|
|
901
890
|
flexShrink: 0,
|
|
902
|
-
height:
|
|
891
|
+
height: t
|
|
903
892
|
},
|
|
904
893
|
children: [
|
|
905
|
-
/* @__PURE__ */ o(V, { size: "medium", color: "inherit", sx: { padding: 1.5 }, onClick: () => i((l) => !l), children: /* @__PURE__ */ o(
|
|
906
|
-
/* @__PURE__ */ o(
|
|
894
|
+
/* @__PURE__ */ o(V, { size: "medium", color: "inherit", sx: { padding: 1.5 }, onClick: () => i((l) => !l), children: /* @__PURE__ */ o(Mt, { fontSize: "medium" }) }),
|
|
895
|
+
/* @__PURE__ */ o(B, { className: xn.titleText, variant: "h6", children: e })
|
|
907
896
|
]
|
|
908
897
|
}
|
|
909
898
|
) });
|
|
910
899
|
}
|
|
911
|
-
function
|
|
912
|
-
children:
|
|
913
|
-
initialTitleText:
|
|
900
|
+
function oo({
|
|
901
|
+
children: e,
|
|
902
|
+
initialTitleText: t,
|
|
914
903
|
initialNavBarOpen: n,
|
|
915
904
|
pageContainerProps: i,
|
|
916
905
|
pageContentDataTestId: a,
|
|
@@ -919,26 +908,26 @@ function to({
|
|
|
919
908
|
navBarMiddle: u,
|
|
920
909
|
navBarBottom: s,
|
|
921
910
|
user: d,
|
|
922
|
-
domainCode:
|
|
911
|
+
domainCode: v
|
|
923
912
|
}) {
|
|
924
|
-
const [f, C] =
|
|
925
|
-
return
|
|
926
|
-
|
|
927
|
-
}, [
|
|
913
|
+
const [f, C] = P(me), [m] = P(nt), [T] = P(ot), [I, S] = P(it), [b] = P(rt), [O] = P(at);
|
|
914
|
+
return te(() => {
|
|
915
|
+
t !== void 0 && S(t);
|
|
916
|
+
}, [t, S]), te(() => {
|
|
928
917
|
n !== void 0 && C(n);
|
|
929
|
-
}, [n, C]), /* @__PURE__ */ c(
|
|
930
|
-
/* @__PURE__ */ o(
|
|
931
|
-
/* @__PURE__ */ o(
|
|
932
|
-
/* @__PURE__ */ c(
|
|
918
|
+
}, [n, C]), /* @__PURE__ */ c(x, { children: [
|
|
919
|
+
/* @__PURE__ */ o(Tt, {}),
|
|
920
|
+
/* @__PURE__ */ o(Cn, { titleText: I, "data-testid": l, height: b }),
|
|
921
|
+
/* @__PURE__ */ c(x, { sx: { display: "flex" }, children: [
|
|
933
922
|
/* @__PURE__ */ o(
|
|
934
|
-
|
|
923
|
+
un,
|
|
935
924
|
{
|
|
936
925
|
open: f,
|
|
937
926
|
top: O,
|
|
938
927
|
middle: u,
|
|
939
928
|
bottom: s,
|
|
940
929
|
user: d,
|
|
941
|
-
domainCode:
|
|
930
|
+
domainCode: v,
|
|
942
931
|
widthOpen: m,
|
|
943
932
|
widthClosed: T,
|
|
944
933
|
offsetTop: b,
|
|
@@ -946,59 +935,59 @@ function to({
|
|
|
946
935
|
}
|
|
947
936
|
),
|
|
948
937
|
/* @__PURE__ */ o(
|
|
949
|
-
|
|
938
|
+
hn,
|
|
950
939
|
w(r({
|
|
951
940
|
"data-testid": a,
|
|
952
941
|
topBarHeight: b
|
|
953
942
|
}, i), {
|
|
954
|
-
children:
|
|
943
|
+
children: e
|
|
955
944
|
})
|
|
956
945
|
)
|
|
957
946
|
] })
|
|
958
947
|
] });
|
|
959
948
|
}
|
|
960
|
-
const
|
|
949
|
+
const wn = {
|
|
961
950
|
autoHideDuration: 6e3,
|
|
962
951
|
anchorOrigin: { vertical: "top", horizontal: "center" },
|
|
963
952
|
// The default is false. If we prefer timer to continue when window loses
|
|
964
953
|
// focus, change to true
|
|
965
954
|
disableWindowBlurListener: !1
|
|
966
|
-
},
|
|
967
|
-
shouldClose: (
|
|
968
|
-
},
|
|
955
|
+
}, bn = {
|
|
956
|
+
shouldClose: (e, t) => t !== "clickaway"
|
|
957
|
+
}, Le = {
|
|
969
958
|
message: "",
|
|
970
959
|
severity: "info",
|
|
971
960
|
variant: "standard",
|
|
972
961
|
progressIndicator: void 0
|
|
973
962
|
// Can use 'circular' or 'linear'
|
|
974
|
-
},
|
|
975
|
-
let
|
|
976
|
-
return () => (
|
|
977
|
-
})(),
|
|
963
|
+
}, ye = 100, Me = 2e3, An = 2e3, Sn = (() => {
|
|
964
|
+
let e = 0;
|
|
965
|
+
return () => (e += 1, e);
|
|
966
|
+
})(), Tn = {
|
|
978
967
|
borderBottomLeftRadius: "0px",
|
|
979
968
|
borderBottomRightRadius: "0px"
|
|
980
|
-
},
|
|
981
|
-
function
|
|
969
|
+
}, In = {}, On = {}, st = Re(null);
|
|
970
|
+
function Dn(l) {
|
|
982
971
|
var p = l, {
|
|
983
|
-
overrideState:
|
|
984
|
-
overrideActions:
|
|
985
|
-
shouldClose: n =
|
|
972
|
+
overrideState: e = In,
|
|
973
|
+
overrideActions: t = On,
|
|
974
|
+
shouldClose: n = bn.shouldClose,
|
|
986
975
|
children: i
|
|
987
|
-
} = p, a =
|
|
976
|
+
} = p, a = Se(p, [
|
|
988
977
|
"overrideState",
|
|
989
978
|
"overrideActions",
|
|
990
979
|
"shouldClose",
|
|
991
980
|
"children"
|
|
992
981
|
]);
|
|
993
|
-
var
|
|
994
|
-
const [{ open: u }, s] =
|
|
982
|
+
var G;
|
|
983
|
+
const [{ open: u }, s] = k({ open: !1 }), d = de([]), v = de(Date.now()), f = de(0), C = ee((h) => {
|
|
995
984
|
s({ open: h });
|
|
996
|
-
}, []), m =
|
|
997
|
-
f.current += 1, d.current.length >=
|
|
998
|
-
`SaladBarProvider: MAX_QUEUE_LENGTH (${
|
|
985
|
+
}, []), m = ee((h = {}) => {
|
|
986
|
+
f.current += 1, d.current.length >= ye && Date.now() - v.current >= Me && (v.current = Date.now(), console.error(
|
|
987
|
+
`SaladBarProvider: MAX_QUEUE_LENGTH (${ye}) hit ${f.current} times in last ${Me}ms)`
|
|
999
988
|
), f.current = 0);
|
|
1000
|
-
const g = r(w(r({},
|
|
1001
|
-
key:
|
|
989
|
+
const g = r(w(r({}, Le), {
|
|
990
|
+
key: Sn()
|
|
1002
991
|
}), h);
|
|
1003
992
|
return d.current.push(g), d.current.length === 1 && s({ open: !0 }), g.key;
|
|
1004
993
|
}, []), T = (h = "", g = {}) => m(r({ message: h, severity: "success" }, g)), I = (h = "", g = {}) => m(r({ message: h, severity: "info" }, g)), S = (h = "", g = {}) => m(r({ message: h, severity: "warning" }, g)), b = (h = "", g = {}) => m(r({ message: h, severity: "error" }, g)), O = (h) => {
|
|
@@ -1010,9 +999,9 @@ function Tn(l) {
|
|
|
1010
999
|
}, R = () => {
|
|
1011
1000
|
}, W = () => {
|
|
1012
1001
|
d.current.shift(), d.current.length > 0 && s({ open: !0 });
|
|
1013
|
-
}, D = (
|
|
1002
|
+
}, D = (G = d.current[0]) != null ? G : r({}, Le), X = {};
|
|
1014
1003
|
"autoHideDuration" in D && (X.autoHideDuration = D.autoHideDuration);
|
|
1015
|
-
const q = r(r({},
|
|
1004
|
+
const q = r(r({}, wn), a), z = r(r({
|
|
1016
1005
|
open: u,
|
|
1017
1006
|
setOpen: C,
|
|
1018
1007
|
enqueueNotification: m,
|
|
@@ -1021,11 +1010,11 @@ function Tn(l) {
|
|
|
1021
1010
|
enqueueWarningNotification: S,
|
|
1022
1011
|
enqueueErrorNotification: b,
|
|
1023
1012
|
removeNotification: O
|
|
1024
|
-
},
|
|
1025
|
-
return /* @__PURE__ */ c(
|
|
1013
|
+
}, e), t);
|
|
1014
|
+
return /* @__PURE__ */ c(st.Provider, { value: z, children: [
|
|
1026
1015
|
i,
|
|
1027
1016
|
/* @__PURE__ */ o(
|
|
1028
|
-
|
|
1017
|
+
It,
|
|
1029
1018
|
w(r(r({}, q), X), {
|
|
1030
1019
|
open: u,
|
|
1031
1020
|
onClose: H,
|
|
@@ -1033,46 +1022,46 @@ function Tn(l) {
|
|
|
1033
1022
|
onExited: W,
|
|
1034
1023
|
onExit: R
|
|
1035
1024
|
},
|
|
1036
|
-
sx: { zIndex:
|
|
1025
|
+
sx: { zIndex: An },
|
|
1037
1026
|
children: /* @__PURE__ */ c("div", { children: [
|
|
1038
1027
|
/* @__PURE__ */ o(
|
|
1039
|
-
|
|
1028
|
+
Ot,
|
|
1040
1029
|
{
|
|
1041
1030
|
onClose: (h) => H(h, "closeAlert"),
|
|
1042
1031
|
severity: D.severity,
|
|
1043
1032
|
variant: "filled",
|
|
1044
|
-
icon: D.progressIndicator === "circular" ? /* @__PURE__ */ o(
|
|
1045
|
-
style: D.progressIndicator === "linear" ?
|
|
1033
|
+
icon: D.progressIndicator === "circular" ? /* @__PURE__ */ o(Ue, { size: "1em" }) : void 0,
|
|
1034
|
+
style: D.progressIndicator === "linear" ? Tn : void 0,
|
|
1046
1035
|
children: D.message
|
|
1047
1036
|
}
|
|
1048
1037
|
),
|
|
1049
|
-
D.progressIndicator === "linear" && /* @__PURE__ */ o(
|
|
1038
|
+
D.progressIndicator === "linear" && /* @__PURE__ */ o(Dt, { color: "primary" })
|
|
1050
1039
|
] })
|
|
1051
1040
|
})
|
|
1052
1041
|
)
|
|
1053
1042
|
] });
|
|
1054
1043
|
}
|
|
1055
|
-
function
|
|
1056
|
-
const
|
|
1057
|
-
if (
|
|
1058
|
-
throw new
|
|
1059
|
-
return
|
|
1044
|
+
function kn() {
|
|
1045
|
+
const e = We(st);
|
|
1046
|
+
if (e === null)
|
|
1047
|
+
throw new fe("Error: Tried to useSaladBar outside of a <SaladBarProvider>");
|
|
1048
|
+
return e;
|
|
1060
1049
|
}
|
|
1061
|
-
const
|
|
1062
|
-
(
|
|
1063
|
-
),
|
|
1064
|
-
children:
|
|
1065
|
-
store:
|
|
1066
|
-
}) => /* @__PURE__ */ o(
|
|
1067
|
-
var
|
|
1068
|
-
const
|
|
1069
|
-
JSON.parse((
|
|
1070
|
-
),
|
|
1071
|
-
(
|
|
1072
|
-
(
|
|
1073
|
-
|
|
1050
|
+
const io = oe(
|
|
1051
|
+
(e = { autoHideDuration: 1 }, t = {}, n = {}) => ({ children: i }) => /* @__PURE__ */ o(Dn, w(r({}, e), { overrideState: t, overrideActions: n, children: i }))
|
|
1052
|
+
), Bn = Ht(), ro = ({
|
|
1053
|
+
children: e,
|
|
1054
|
+
store: t
|
|
1055
|
+
}) => /* @__PURE__ */ o(Qe, { store: t != null ? t : Bn, children: e }), lt = "domainCode";
|
|
1056
|
+
var He;
|
|
1057
|
+
const _e = E(
|
|
1058
|
+
JSON.parse((He = localStorage.getItem(lt)) != null ? He : '{"domainCode": ""}').domainCode
|
|
1059
|
+
), dt = E(
|
|
1060
|
+
(e) => e(_e),
|
|
1061
|
+
(e, t, n) => {
|
|
1062
|
+
t(_e, n), localStorage.setItem(lt, JSON.stringify({ domainCode: n }));
|
|
1074
1063
|
}
|
|
1075
|
-
),
|
|
1064
|
+
), $n = {
|
|
1076
1065
|
act: "ACT",
|
|
1077
1066
|
nsw: "NSW",
|
|
1078
1067
|
nt: "NT",
|
|
@@ -1084,27 +1073,27 @@ const Ht = E(
|
|
|
1084
1073
|
ag: "AG",
|
|
1085
1074
|
fedmps: "Fedmps",
|
|
1086
1075
|
"": ""
|
|
1087
|
-
},
|
|
1088
|
-
var
|
|
1089
|
-
return
|
|
1090
|
-
},
|
|
1091
|
-
isLoading:
|
|
1092
|
-
isOpen:
|
|
1076
|
+
}, En = (e) => {
|
|
1077
|
+
var t;
|
|
1078
|
+
return e === null ? "N/A" : (t = $n[e]) != null ? t : "";
|
|
1079
|
+
}, ao = ({
|
|
1080
|
+
isLoading: e,
|
|
1081
|
+
isOpen: t,
|
|
1093
1082
|
onClose: n,
|
|
1094
1083
|
domainOptions: i,
|
|
1095
1084
|
applicationName: a,
|
|
1096
1085
|
handleLogout: l
|
|
1097
1086
|
}) => {
|
|
1098
|
-
const [p, u] =
|
|
1099
|
-
s ? (u(s),
|
|
1087
|
+
const [p, u] = P(dt), [s, d] = k(p), { enqueueSuccessNotification: v } = kn(), f = i.length === 0, C = !!p && !i.includes(p) && !i.includes(s), m = !p || f || C, T = () => J(void 0, null, function* () {
|
|
1088
|
+
s ? (u(s), v(`Set domain to ${s}`), n()) : u("");
|
|
1100
1089
|
}), I = () => J(void 0, null, function* () {
|
|
1101
1090
|
p && !f && !C ? (d(p), n()) : m && l();
|
|
1102
1091
|
});
|
|
1103
1092
|
let S;
|
|
1104
1093
|
return f ? S = "Unable to retrieve your active organisations. Try logging in again." : C && (S = "You no longer have any roles in your chosen organisation. Please choose another."), /* @__PURE__ */ c(
|
|
1105
|
-
|
|
1094
|
+
Yt,
|
|
1106
1095
|
{
|
|
1107
|
-
isOpen:
|
|
1096
|
+
isOpen: t,
|
|
1108
1097
|
dialogTitle: "Select an organisation",
|
|
1109
1098
|
primaryButton: {
|
|
1110
1099
|
text: "Confirm",
|
|
@@ -1119,29 +1108,29 @@ const Ht = E(
|
|
|
1119
1108
|
onClose: m ? () => {
|
|
1120
1109
|
} : n,
|
|
1121
1110
|
children: [
|
|
1122
|
-
/* @__PURE__ */ c(
|
|
1111
|
+
/* @__PURE__ */ c(B, { marginBottom: 2, children: [
|
|
1123
1112
|
"Select the default organisation that you want to use with the ",
|
|
1124
1113
|
a,
|
|
1125
1114
|
"."
|
|
1126
1115
|
] }),
|
|
1127
1116
|
/* @__PURE__ */ o(
|
|
1128
|
-
|
|
1117
|
+
kt,
|
|
1129
1118
|
{
|
|
1130
|
-
loading:
|
|
1119
|
+
loading: e,
|
|
1131
1120
|
multiple: !1,
|
|
1132
1121
|
disableClearable: !1,
|
|
1133
1122
|
value: s !== "" ? s : null,
|
|
1134
1123
|
onChange: (b, O) => d(O != null ? O : ""),
|
|
1135
|
-
getOptionLabel:
|
|
1124
|
+
getOptionLabel: En,
|
|
1136
1125
|
options: [...i],
|
|
1137
1126
|
renderInput: (b) => /* @__PURE__ */ o(
|
|
1138
|
-
|
|
1127
|
+
Bt,
|
|
1139
1128
|
w(r({}, b), {
|
|
1140
1129
|
variant: "filled",
|
|
1141
1130
|
label: "Select organisation",
|
|
1142
1131
|
InputProps: w(r({}, b.InputProps), {
|
|
1143
|
-
endAdornment: /* @__PURE__ */ c(
|
|
1144
|
-
|
|
1132
|
+
endAdornment: /* @__PURE__ */ c(y, { children: [
|
|
1133
|
+
e ? /* @__PURE__ */ o(Ue, { color: "inherit", size: 20, sx: { marginTop: "-20px" } }) : null,
|
|
1145
1134
|
b.InputProps.endAdornment
|
|
1146
1135
|
] })
|
|
1147
1136
|
})
|
|
@@ -1149,11 +1138,11 @@ const Ht = E(
|
|
|
1149
1138
|
)
|
|
1150
1139
|
}
|
|
1151
1140
|
),
|
|
1152
|
-
S && /* @__PURE__ */ o($
|
|
1141
|
+
S && /* @__PURE__ */ o($t, { error: !0, children: S })
|
|
1153
1142
|
]
|
|
1154
1143
|
}
|
|
1155
1144
|
);
|
|
1156
|
-
},
|
|
1145
|
+
}, so = Ve({
|
|
1157
1146
|
palette: {
|
|
1158
1147
|
primary: {
|
|
1159
1148
|
dark: "#00A651",
|
|
@@ -1204,7 +1193,7 @@ const Ht = E(
|
|
|
1204
1193
|
navBar: {
|
|
1205
1194
|
backgroundColor: "#E8E8E8"
|
|
1206
1195
|
}
|
|
1207
|
-
}),
|
|
1196
|
+
}), lo = Ve({
|
|
1208
1197
|
palette: {
|
|
1209
1198
|
primary: {
|
|
1210
1199
|
main: "#007236",
|
|
@@ -1256,22 +1245,22 @@ const Ht = E(
|
|
|
1256
1245
|
MuiMenuItem: {
|
|
1257
1246
|
// Setting defaultProps for color on MenuItem does not work, so update manually
|
|
1258
1247
|
styleOverrides: {
|
|
1259
|
-
root: ({ theme:
|
|
1248
|
+
root: ({ theme: e }) => ({
|
|
1260
1249
|
"&.Mui-selected": {
|
|
1261
|
-
backgroundColor:
|
|
1262
|
-
|
|
1263
|
-
|
|
1250
|
+
backgroundColor: ce(
|
|
1251
|
+
e.palette.secondary.main,
|
|
1252
|
+
e.palette.action.selectedOpacity
|
|
1264
1253
|
),
|
|
1265
1254
|
"&:hover": {
|
|
1266
|
-
backgroundColor:
|
|
1267
|
-
|
|
1268
|
-
|
|
1255
|
+
backgroundColor: ce(
|
|
1256
|
+
e.palette.secondary.main,
|
|
1257
|
+
e.palette.action.selectedOpacity
|
|
1269
1258
|
)
|
|
1270
1259
|
},
|
|
1271
1260
|
"&.Mui-focusVisible": {
|
|
1272
|
-
backgroundColor:
|
|
1273
|
-
|
|
1274
|
-
|
|
1261
|
+
backgroundColor: ce(
|
|
1262
|
+
e.palette.secondary.main,
|
|
1263
|
+
e.palette.action.focusOpacity
|
|
1275
1264
|
)
|
|
1276
1265
|
}
|
|
1277
1266
|
}
|
|
@@ -1295,65 +1284,65 @@ const Ht = E(
|
|
|
1295
1284
|
navBar: {
|
|
1296
1285
|
backgroundColor: "#E8E8E8"
|
|
1297
1286
|
}
|
|
1298
|
-
}),
|
|
1299
|
-
domainCode:
|
|
1300
|
-
navBarOpen:
|
|
1301
|
-
navBarWidthOpen:
|
|
1302
|
-
navBarWidthClosed:
|
|
1303
|
-
titleText:
|
|
1304
|
-
topBarHeight:
|
|
1305
|
-
navBarTop:
|
|
1306
|
-
},
|
|
1307
|
-
initialValues:
|
|
1308
|
-
children:
|
|
1309
|
-
}) => (
|
|
1310
|
-
(
|
|
1311
|
-
|
|
1287
|
+
}), Nn = {
|
|
1288
|
+
domainCode: dt,
|
|
1289
|
+
navBarOpen: me,
|
|
1290
|
+
navBarWidthOpen: nt,
|
|
1291
|
+
navBarWidthClosed: ot,
|
|
1292
|
+
titleText: it,
|
|
1293
|
+
topBarHeight: rt,
|
|
1294
|
+
navBarTop: at
|
|
1295
|
+
}, co = oe(() => ({ children: e }) => /* @__PURE__ */ o(Qe, { children: e })), Fn = ({
|
|
1296
|
+
initialValues: e,
|
|
1297
|
+
children: t
|
|
1298
|
+
}) => (Rt(e), /* @__PURE__ */ o(y, { children: t })), po = oe(
|
|
1299
|
+
(e) => ({ children: t }) => /* @__PURE__ */ o(
|
|
1300
|
+
Fn,
|
|
1312
1301
|
{
|
|
1313
|
-
initialValues: Object.entries(
|
|
1302
|
+
initialValues: Object.entries(e).map(
|
|
1314
1303
|
([n, i]) => [
|
|
1315
|
-
|
|
1304
|
+
Nn[n],
|
|
1316
1305
|
i
|
|
1317
1306
|
]
|
|
1318
1307
|
),
|
|
1319
|
-
children:
|
|
1308
|
+
children: t
|
|
1320
1309
|
}
|
|
1321
1310
|
)
|
|
1322
1311
|
);
|
|
1323
1312
|
export {
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1313
|
+
Yt as AgDialog,
|
|
1314
|
+
oo as AppLayout,
|
|
1315
|
+
ro as AtomProvider,
|
|
1316
|
+
st as Context,
|
|
1317
|
+
fe as ContextError,
|
|
1318
|
+
ao as DomainCodeDialog,
|
|
1319
|
+
Jn as ExampleComponent,
|
|
1320
|
+
Fn as HydrateAtoms,
|
|
1321
|
+
Je as NAVBAR_WIDTH_CLOSED,
|
|
1322
|
+
Ye as NAVBAR_WIDTH_OPENED,
|
|
1323
|
+
to as NavBar,
|
|
1324
|
+
Zn as NavBarDarkStyledList,
|
|
1325
|
+
eo as NavBarLightStyledList,
|
|
1326
|
+
qt as NavBarProvider,
|
|
1327
|
+
no as PageLayout,
|
|
1328
|
+
Dn as SaladBarProvider,
|
|
1329
|
+
Bn as atomStore,
|
|
1330
|
+
Qt as buildNavBarState,
|
|
1331
|
+
dt as domainCodeAtom,
|
|
1332
|
+
so as fed21Theme,
|
|
1333
|
+
lo as internalAgSystemsTheme,
|
|
1345
1334
|
_ as navBarClasses,
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1335
|
+
me as navBarOpenAtom,
|
|
1336
|
+
at as navBarTopAtom,
|
|
1337
|
+
ot as navBarWidthClosedAtom,
|
|
1338
|
+
nt as navBarWidthOpenAtom,
|
|
1339
|
+
it as titleTextAtom,
|
|
1340
|
+
rt as topBarHeightAtom,
|
|
1341
|
+
jt as useNavBar,
|
|
1342
|
+
kn as useSaladBar,
|
|
1343
|
+
co as withAtomProvider,
|
|
1344
|
+
Kn as withNavBarProvider,
|
|
1345
|
+
po as withOverrideDefaults,
|
|
1346
|
+
io as withSaladBarProvider
|
|
1358
1347
|
};
|
|
1359
1348
|
//# sourceMappingURL=index.js.map
|