@australiangreens/ag-internal-components 0.0.52 → 0.0.54-experiment1

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