@australiangreens/ag-internal-components 0.0.65 → 0.0.66

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.
@@ -13,12 +13,13 @@ export type AgDialogProps = PropsWithChildren<{
13
13
  maxWidth?: false | Breakpoint;
14
14
  primaryButton?: AgDialogButtonConfig;
15
15
  secondaryButton?: AgDialogButtonConfig;
16
+ 'data-testid'?: string;
16
17
  onClose: () => void;
17
18
  }>;
18
19
  /**
19
20
  * Standard dialog that will auto disable it's buttons while the primaryButton onClick function is pending.
20
21
  *
21
22
  */
22
- declare const AgDialog: ({ isOpen, dialogTitle, children, maxWidth, primaryButton, secondaryButton, onClose: handleClose, }: AgDialogProps) => JSX.Element;
23
+ declare const AgDialog: ({ isOpen, dialogTitle, children, maxWidth, primaryButton, secondaryButton, onClose: handleClose, "data-testid": dataTestId, }: AgDialogProps) => JSX.Element;
23
24
  export default AgDialog;
24
25
  //# sourceMappingURL=AgDialog.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AgDialog.d.ts","sourceRoot":"","sources":["../../../src/components/AgDialog/AgDialog.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAM3C,OAAO,EAAE,iBAAiB,EAAY,MAAM,OAAO,CAAC;AAEpD,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,WAAW,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,CAAC;CAC9F,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG,iBAAiB,CAAC;IAC5C,MAAM,EAAE,OAAO,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,KAAK,GAAG,UAAU,CAAC;IAC9B,aAAa,CAAC,EAAE,oBAAoB,CAAC;IACrC,eAAe,CAAC,EAAE,oBAAoB,CAAC;IACvC,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC,CAAC;AAEH;;;GAGG;AACH,QAAA,MAAM,QAAQ,uGAQX,aAAa,gBAyCf,CAAC;AAEF,eAAe,QAAQ,CAAC"}
1
+ {"version":3,"file":"AgDialog.d.ts","sourceRoot":"","sources":["../../../src/components/AgDialog/AgDialog.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAM3C,OAAO,EAAE,iBAAiB,EAAY,MAAM,OAAO,CAAC;AAEpD,MAAM,MAAM,oBAAoB,GAAG;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9B,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,SAAS,GAAG,SAAS,GAAG,WAAW,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,CAAC;CAC9F,CAAC;AAEF,MAAM,MAAM,aAAa,GAAG,iBAAiB,CAAC;IAC5C,MAAM,EAAE,OAAO,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,KAAK,GAAG,UAAU,CAAC;IAC9B,aAAa,CAAC,EAAE,oBAAoB,CAAC;IACrC,eAAe,CAAC,EAAE,oBAAoB,CAAC;IACvC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB,CAAC,CAAC;AAEH;;;GAGG;AACH,QAAA,MAAM,QAAQ,kIASX,aAAa,gBA0Cf,CAAC;AAEF,eAAe,QAAQ,CAAC"}
package/dist/esm/index.js CHANGED
@@ -9,7 +9,7 @@ var ge = (e, t, n) => t in e ? $t(e, t, { enumerable: !0, configurable: !0, writ
9
9
  for (var n of ee(t))
10
10
  Be.call(t, n) && ge(e, n, t[n]);
11
11
  return e;
12
- }, A = (e, t) => kt(e, It(t));
12
+ }, S = (e, t) => kt(e, It(t));
13
13
  var Fe = (e, t) => {
14
14
  var n = {};
15
15
  for (var r in e)
@@ -23,18 +23,18 @@ var Pe = (e, t, n) => (ge(e, typeof t != "symbol" ? t + "" : t, n), n);
23
23
  var z = (e, t, n) => new Promise((r, s) => {
24
24
  var c = (p) => {
25
25
  try {
26
- h(n.next(p));
26
+ g(n.next(p));
27
27
  } catch (u) {
28
28
  s(u);
29
29
  }
30
30
  }, d = (p) => {
31
31
  try {
32
- h(n.throw(p));
32
+ g(n.throw(p));
33
33
  } catch (u) {
34
34
  s(u);
35
35
  }
36
- }, h = (p) => p.done ? r(p.value) : Promise.resolve(p.value).then(c, d);
37
- h((n = n.apply(e, t)).next());
36
+ }, g = (p) => p.done ? r(p.value) : Promise.resolve(p.value).then(c, d);
37
+ g((n = n.apply(e, t)).next());
38
38
  });
39
39
  import { jsxs as f, Fragment as P, jsx as o } from "react/jsx-runtime";
40
40
  import { useState as $, createContext as Je, useCallback as oe, useContext as Ye, useEffect as re, useMemo as Et, createElement as xe, useRef as fe } from "react";
@@ -143,13 +143,13 @@ const pt = Je(null), an = {}, sn = {}, ln = ({
143
143
  const [{ open: r }, s] = $({ open: !0 }), c = oe((p) => {
144
144
  s({ open: p });
145
145
  }, []), d = oe(() => {
146
- s((p) => A(i({}, p), { open: !p.open }));
147
- }, []), h = i(i({
146
+ s((p) => S(i({}, p), { open: !p.open }));
147
+ }, []), g = i(i({
148
148
  open: r,
149
149
  setOpen: c,
150
150
  toggleOpen: d
151
151
  }, e), t);
152
- return /* @__PURE__ */ o(pt.Provider, { value: h, children: n });
152
+ return /* @__PURE__ */ o(pt.Provider, { value: g, children: n });
153
153
  }, cn = () => {
154
154
  const e = Ye(pt);
155
155
  if (e === null)
@@ -262,19 +262,21 @@ const pn = ({
262
262
  maxWidth: r,
263
263
  primaryButton: s,
264
264
  secondaryButton: c,
265
- onClose: d
265
+ onClose: d,
266
+ "data-testid": g
266
267
  }) => {
267
- var u, w;
268
- const [h, p] = $(!1);
268
+ var w, b;
269
+ const [p, u] = $(!1);
269
270
  return /* @__PURE__ */ f(
270
271
  Vt,
271
272
  {
272
273
  open: e,
273
274
  onClose: () => {
274
- h || d();
275
+ p || d();
275
276
  },
276
277
  fullWidth: !0,
277
278
  maxWidth: r != null ? r : "xs",
279
+ "data-testid": g,
278
280
  children: [
279
281
  /* @__PURE__ */ o(jt, { children: t }),
280
282
  /* @__PURE__ */ o(Xt, { sx: { "& > :last-child": { marginBottom: 0 } }, children: n }),
@@ -282,22 +284,22 @@ const pn = ({
282
284
  /* @__PURE__ */ o(
283
285
  _e,
284
286
  {
285
- onClick: (u = c == null ? void 0 : c.onClick) != null ? u : d,
287
+ onClick: (w = c == null ? void 0 : c.onClick) != null ? w : d,
286
288
  "data-testid": c == null ? void 0 : c.testId,
287
- disabled: (c == null ? void 0 : c.disabled) || h,
289
+ disabled: (c == null ? void 0 : c.disabled) || p,
288
290
  color: c == null ? void 0 : c.buttonColor,
289
- children: (w = c == null ? void 0 : c.text) != null ? w : "Cancel"
291
+ children: (b = c == null ? void 0 : c.text) != null ? b : "Cancel"
290
292
  }
291
293
  ),
292
294
  s && /* @__PURE__ */ o(
293
295
  _e,
294
296
  {
295
297
  onClick: () => z(void 0, null, function* () {
296
- var b;
297
- p(!0), yield (b = s.onClick) == null ? void 0 : b.call(s), p(!1);
298
+ var A;
299
+ u(!0), yield (A = s.onClick) == null ? void 0 : A.call(s), u(!1);
298
300
  }),
299
301
  "data-testid": s.testId,
300
- disabled: s.disabled || h,
302
+ disabled: s.disabled || p,
301
303
  color: s == null ? void 0 : s.buttonColor,
302
304
  children: s.text
303
305
  }
@@ -316,18 +318,18 @@ function wo({
316
318
  label: s,
317
319
  value: c,
318
320
  "data-testid": d,
319
- sx: h,
321
+ sx: g,
320
322
  textFieldColor: p,
321
323
  textFieldVariant: u = "filled",
322
324
  loadingText: w = "Loading...",
323
325
  noOptionsText: b = "No options",
324
- popupIcon: S = /* @__PURE__ */ o(Kt, {}),
326
+ popupIcon: A = /* @__PURE__ */ o(Kt, {}),
325
327
  error: v = !1,
326
328
  helperText: O = "",
327
329
  preLoadedOptions: C = void 0,
328
330
  disablePortal: m = !1
329
331
  }) {
330
- const [g, T] = $(""), [M, y] = $(C || []), [B, k] = $(!1), [_, F] = $(!1), H = (a, l) => {
332
+ const [h, T] = $(""), [M, y] = $(C || []), [B, k] = $(!1), [_, F] = $(!1), H = (a, l) => {
331
333
  const x = c.filter((q) => q.id !== l);
332
334
  n(x, "delete", a);
333
335
  };
@@ -336,7 +338,7 @@ function wo({
336
338
  const l = () => z(this, null, function* () {
337
339
  a = new AbortController();
338
340
  try {
339
- const x = yield e(g, a.signal);
341
+ const x = yield e(h, a.signal);
340
342
  y(x != null ? x : []), F(!1);
341
343
  } catch (x) {
342
344
  if (x instanceof Error && x.name === "AbortError")
@@ -345,11 +347,11 @@ function wo({
345
347
  throw x;
346
348
  }
347
349
  });
348
- if (g !== "")
349
- return (!r || g.length >= r) && !C ? (F(!0), l()) : F(!1), function() {
350
+ if (h !== "")
351
+ return (!r || h.length >= r) && !C ? (F(!0), l()) : F(!1), function() {
350
352
  a && a.abort();
351
353
  };
352
- }, [g, e, r, C]), re(() => {
354
+ }, [h, e, r, C]), re(() => {
353
355
  !B && !C && y([]), !B && C && y(C);
354
356
  }, [B, C]);
355
357
  const R = Et(() => C ? (a, l) => a.filter(
@@ -359,7 +361,7 @@ function wo({
359
361
  /* @__PURE__ */ o(
360
362
  Ae,
361
363
  {
362
- sx: h,
364
+ sx: g,
363
365
  "data-testid": d ? `${d}:Autocomplete` : void 0,
364
366
  disablePortal: m,
365
367
  multiple: !0,
@@ -378,16 +380,16 @@ function wo({
378
380
  onInputChange: (a, l) => T(l),
379
381
  noOptionsText: b,
380
382
  loadingText: w,
381
- popupIcon: S,
383
+ popupIcon: A,
382
384
  renderInput: (a) => /* @__PURE__ */ o(
383
385
  Se,
384
- A(i({}, a), {
386
+ S(i({}, a), {
385
387
  label: s,
386
388
  fullWidth: !0,
387
389
  variant: u,
388
390
  error: v,
389
391
  helperText: O,
390
- InputProps: A(i({}, a.InputProps), {
392
+ InputProps: S(i({}, a.InputProps), {
391
393
  endAdornment: /* @__PURE__ */ f(P, { children: [
392
394
  _ ? /* @__PURE__ */ o(De, { color: "inherit", size: 20 }) : null,
393
395
  a.InputProps.endAdornment
@@ -410,7 +412,7 @@ function wo({
410
412
  }), le = Yt(l.label, q);
411
413
  return /* @__PURE__ */ xe(
412
414
  "li",
413
- A(i({}, a), {
415
+ S(i({}, a), {
414
416
  key: l.id,
415
417
  "data-testid": d ? `${d}:Autocomplete:option(${l.id.toString()})` : void 0
416
418
  }),
@@ -428,7 +430,7 @@ function wo({
428
430
  } else
429
431
  return /* @__PURE__ */ xe(
430
432
  "li",
431
- A(i({}, a), {
433
+ S(i({}, a), {
432
434
  key: l.id,
433
435
  "data-testid": d ? `${d}:option(${l.id.toString()})` : void 0
434
436
  }),
@@ -484,33 +486,33 @@ const bo = ({
484
486
  sx: s,
485
487
  textFieldColor: c,
486
488
  textFieldVariant: d = "filled",
487
- "data-testid": h,
489
+ "data-testid": g,
488
490
  minLength: p = 3,
489
491
  disablePortal: u = !1
490
492
  }) => {
491
- const [w, b] = $([]), [S, v] = $(!1);
493
+ const [w, b] = $([]), [A, v] = $(!1);
492
494
  let O;
493
495
  const C = (m) => z(void 0, null, function* () {
494
496
  O = new AbortController();
495
497
  try {
496
- const g = yield e(m, O.signal);
497
- b(g != null ? g : []), v(!1);
498
- } catch (g) {
499
- if (g instanceof Error && g.name === "AbortError")
498
+ const h = yield e(m, O.signal);
499
+ b(h != null ? h : []), v(!1);
500
+ } catch (h) {
501
+ if (h instanceof Error && h.name === "AbortError")
500
502
  console.debug("Previous lookup request was cancelled");
501
503
  else
502
- throw g;
504
+ throw h;
503
505
  }
504
506
  });
505
- return /* @__PURE__ */ o("div", { "data-testid": h, children: /* @__PURE__ */ o(Ft, { direction: "row", spacing: 1, children: /* @__PURE__ */ o(
507
+ return /* @__PURE__ */ o("div", { "data-testid": g, children: /* @__PURE__ */ o(Ft, { direction: "row", spacing: 1, children: /* @__PURE__ */ o(
506
508
  Ae,
507
509
  {
508
510
  sx: s,
509
- "data-testid": h ? `${h}:Autocomplete` : void 0,
510
- loading: S,
511
+ "data-testid": g ? `${g}:Autocomplete` : void 0,
512
+ loading: A,
511
513
  options: w,
512
- onChange: (m, g) => {
513
- t(m, g);
514
+ onChange: (m, h) => {
515
+ t(m, h);
514
516
  },
515
517
  disablePortal: u,
516
518
  filterOptions: (m) => m,
@@ -518,25 +520,25 @@ const bo = ({
518
520
  getOptionLabel: (m) => m.label,
519
521
  renderInput: (m) => /* @__PURE__ */ o(
520
522
  Se,
521
- A(i({
522
- "data-testid": h ? `${h}:Autocomplete:TextField` : void 0
523
+ S(i({
524
+ "data-testid": g ? `${g}:Autocomplete:TextField` : void 0
523
525
  }, m), {
524
526
  variant: d,
525
527
  label: n,
526
528
  color: c
527
529
  })
528
530
  ),
529
- isOptionEqualToValue: (m, g) => m.id === g.id,
530
- onInputChange: (m, g) => {
531
- (g == null ? void 0 : g.length) >= p && (v(!0), C(g));
531
+ isOptionEqualToValue: (m, h) => m.id === h.id,
532
+ onInputChange: (m, h) => {
533
+ (h == null ? void 0 : h.length) >= p && (v(!0), C(h));
532
534
  },
533
- renderOption: (m, g) => /* @__PURE__ */ xe(
535
+ renderOption: (m, h) => /* @__PURE__ */ xe(
534
536
  "li",
535
- A(i({}, m), {
536
- key: g.id,
537
- "data-testid": h ? `${h}:Autocomplete:option(${g.id.toString()})` : void 0
537
+ S(i({}, m), {
538
+ key: h.id,
539
+ "data-testid": g ? `${g}:Autocomplete:option(${h.id.toString()})` : void 0
538
540
  }),
539
- g.label
541
+ h.label
540
542
  )
541
543
  }
542
544
  ) }) });
@@ -674,7 +676,7 @@ const ut = 400, mn = Oe(be, {
674
676
  })
675
677
  ), Cn = Oe(D, {
676
678
  shouldForwardProp: (e) => !["anchor"].includes(e)
677
- })(({ theme: e, anchor: t }) => A(i({
679
+ })(({ theme: e, anchor: t }) => S(i({
678
680
  display: "flex",
679
681
  alignItems: "center",
680
682
  padding: e.spacing(2)
@@ -701,12 +703,12 @@ function ze({
701
703
  titleText: s = "",
702
704
  width: c = ut,
703
705
  showCloseArrow: d = !0,
704
- debugOpacity: h = !1,
706
+ debugOpacity: g = !1,
705
707
  headerBoxProps: p = {},
706
708
  onOpened: u,
707
709
  onClosed: w,
708
710
  "data-testid": b,
709
- navBarOpen: S = !1,
711
+ navBarOpen: A = !1,
710
712
  navBarWidthOpen: v = 0,
711
713
  navBarWidthClosed: O = 0
712
714
  }) {
@@ -721,13 +723,13 @@ function ze({
721
723
  anchor: t,
722
724
  open: n,
723
725
  width: c,
724
- debugOpacity: h,
726
+ debugOpacity: g,
725
727
  "data-testid": b,
726
- navBarOpen: S,
728
+ navBarOpen: A,
727
729
  navBarWidthOpen: v,
728
730
  navBarWidthClosed: O,
729
731
  children: [
730
- /* @__PURE__ */ o(Cn, A(i({ anchor: t }, p), { children: t === "left" ? /* @__PURE__ */ f(P, { children: [
732
+ /* @__PURE__ */ o(Cn, S(i({ anchor: t }, p), { children: t === "left" ? /* @__PURE__ */ f(P, { children: [
731
733
  /* @__PURE__ */ o(E, { variant: "h6", color: "inherit", component: "div", children: s }),
732
734
  d && /* @__PURE__ */ f(Q, { onClick: r, size: "large", "aria-label": "Close left side panel", children: [
733
735
  /* @__PURE__ */ o(rt, { "data-testid": "arrowbackicon" }),
@@ -796,13 +798,13 @@ function Ao({
796
798
  sidePanelsAreMutuallyExclusive: s = !0,
797
799
  debugOpacity: c = !1,
798
800
  pageContainerProps: d,
799
- pageContentDataTestId: h,
801
+ pageContentDataTestId: g,
800
802
  topBarDataTestId: p,
801
803
  navBarOpen: u,
802
804
  navBarWidthOpen: w,
803
805
  navBarWidthClosed: b
804
806
  }) {
805
- const [S, v] = $(Ce), [O, C] = $(ve), [m, g] = $(Ce), [T, M] = $(ve), y = n !== void 0, B = r !== void 0, {
807
+ const [A, v] = $(Ce), [O, C] = $(ve), [m, h] = $(Ce), [T, M] = $(ve), y = n !== void 0, B = r !== void 0, {
806
808
  titleText: k,
807
809
  content: _,
808
810
  flavour: F,
@@ -828,14 +830,14 @@ function Ao({
828
830
  dataTestId: Ot
829
831
  } = r ? i(i({}, te), r) : i({}, te);
830
832
  re(() => {
831
- x !== Ce && (v(x), g(x));
833
+ x !== Ce && (v(x), h(x));
832
834
  }, [x]), re(() => {
833
835
  Z !== ve && (C(Z), M(Z));
834
836
  }, [Z]);
835
- const ue = H === void 0 ? S : H, he = de === void 0 ? O : de, Ee = (W) => {
837
+ const ue = H === void 0 ? A : H, he = de === void 0 ? O : de, Ee = (W) => {
836
838
  H === void 0 && (v(W), s && B && (W ? (C(!1), M(O)) : C(T))), R && R(W);
837
839
  }, Te = (W) => {
838
- de === void 0 && (C(W), s && y && (W ? (v(!1), g(S)) : v(m))), Ie && Ie(W);
840
+ de === void 0 && (C(W), s && y && (W ? (v(!1), h(A)) : v(m))), Ie && Ie(W);
839
841
  };
840
842
  return /* @__PURE__ */ f(D, { children: [
841
843
  y && /* @__PURE__ */ o(
@@ -899,7 +901,7 @@ function Ao({
899
901
  ),
900
902
  /* @__PURE__ */ o(
901
903
  vn,
902
- A(i(i({}, F === "push" ? {
904
+ S(i(i({}, F === "push" ? {
903
905
  leftPanel: {
904
906
  open: ue,
905
907
  width: a
@@ -910,7 +912,7 @@ function Ao({
910
912
  width: pe
911
913
  }
912
914
  } : {}), {
913
- children: /* @__PURE__ */ o(xn, A(i({ "data-testid": h }, d), { children: e }))
915
+ children: /* @__PURE__ */ o(xn, S(i({ "data-testid": g }, d), { children: e }))
914
916
  })
915
917
  )
916
918
  ] });
@@ -986,10 +988,10 @@ const ne = "Navbar", j = {
986
988
  boxSizing: "border-box",
987
989
  display: "flex",
988
990
  flexDirection: "column"
989
- }, t && A(i({}, Ge(e, n)), {
991
+ }, t && S(i({}, Ge(e, n)), {
990
992
  backgroundColor: "",
991
993
  "& .MuiDrawer-paper": Ge(e, n)
992
- })), !t && A(i({}, Ue(e, s ? n : r)), {
994
+ })), !t && S(i({}, Ue(e, s ? n : r)), {
993
995
  backgroundColor: "",
994
996
  "& .MuiDrawer-paper": Ue(e, s ? n : r)
995
997
  })));
@@ -1053,7 +1055,7 @@ function Tn({
1053
1055
  top: s,
1054
1056
  middle: c,
1055
1057
  bottom: d,
1056
- user: h,
1058
+ user: g,
1057
1059
  domainCode: p
1058
1060
  }) {
1059
1061
  const u = ht(), w = it(K);
@@ -1081,7 +1083,7 @@ function Tn({
1081
1083
  /* @__PURE__ */ o(D, { flexGrow: "1", children: Array.isArray(c) ? /* @__PURE__ */ o(Sn, { links: c }) : c }),
1082
1084
  /* @__PURE__ */ f(D, { flexGrow: "0", children: [
1083
1085
  /* @__PURE__ */ o(Me, { variant: "middle" }),
1084
- /* @__PURE__ */ o(En, { user: h, domainCode: p, open: e }),
1086
+ /* @__PURE__ */ o(En, { user: g, domainCode: p, open: e }),
1085
1087
  d && /* @__PURE__ */ o(P, { children: d })
1086
1088
  ] })
1087
1089
  ]
@@ -1120,7 +1122,7 @@ const Bn = "TopBar", Fn = {
1120
1122
  titleText: `${Bn}-titleText`
1121
1123
  };
1122
1124
  function Pn({ titleText: e = "", height: t, "data-testid": n }) {
1123
- const r = it(K), s = () => r((h) => !h), c = ae(), d = ht();
1125
+ const r = it(K), s = () => r((g) => !g), c = ae(), d = ht();
1124
1126
  return /* @__PURE__ */ o("header", { "data-testid": n, children: /* @__PURE__ */ f(
1125
1127
  Ze,
1126
1128
  {
@@ -1153,7 +1155,7 @@ function So({
1153
1155
  pageContentDataTestId: s,
1154
1156
  topBarDataTestId: c,
1155
1157
  navBarDataTestId: d,
1156
- navBarMiddle: h,
1158
+ navBarMiddle: g,
1157
1159
  navBarBottom: p,
1158
1160
  user: u,
1159
1161
  domainCode: w
@@ -1162,7 +1164,7 @@ function So({
1162
1164
  [K, n != null ? n : !0],
1163
1165
  [we, t != null ? t : ""]
1164
1166
  ]);
1165
- const b = He(K), [S] = X(gt), [v] = X(ft), O = He(we), [C] = X(mt), [m] = X(Ct);
1167
+ const b = He(K), [A] = X(gt), [v] = X(ft), O = He(we), [C] = X(mt), [m] = X(Ct);
1166
1168
  return /* @__PURE__ */ f(D, { children: [
1167
1169
  /* @__PURE__ */ o(_t, {}),
1168
1170
  /* @__PURE__ */ o(Pn, { titleText: O, "data-testid": c, height: C }),
@@ -1172,11 +1174,11 @@ function So({
1172
1174
  {
1173
1175
  open: b,
1174
1176
  top: m,
1175
- middle: h,
1177
+ middle: g,
1176
1178
  bottom: p,
1177
1179
  user: u,
1178
1180
  domainCode: w,
1179
- widthOpen: S,
1181
+ widthOpen: A,
1180
1182
  widthClosed: v,
1181
1183
  offsetTop: C,
1182
1184
  "data-testid": d
@@ -1184,7 +1186,7 @@ function So({
1184
1186
  ),
1185
1187
  /* @__PURE__ */ o(
1186
1188
  yn,
1187
- A(i({
1189
+ S(i({
1188
1190
  "data-testid": s,
1189
1191
  topBarHeight: C
1190
1192
  }, r), {
@@ -1228,17 +1230,17 @@ function zn(c) {
1228
1230
  "children"
1229
1231
  ]);
1230
1232
  var R;
1231
- const [{ open: h }, p] = $({ open: !1 }), u = fe([]), w = fe(Date.now()), b = fe(0), S = oe((a) => {
1233
+ const [{ open: g }, p] = $({ open: !1 }), u = fe([]), w = fe(Date.now()), b = fe(0), A = oe((a) => {
1232
1234
  p({ open: a });
1233
1235
  }, []), v = oe((a = {}) => {
1234
1236
  b.current += 1, u.current.length >= Xe && Date.now() - w.current >= je && (w.current = Date.now(), console.error(
1235
1237
  `SaladBarProvider: MAX_QUEUE_LENGTH (${Xe}) hit ${b.current} times in last ${je}ms)`
1236
1238
  ), b.current = 0);
1237
- const l = i(A(i({}, qe), {
1239
+ const l = i(S(i({}, qe), {
1238
1240
  key: _n()
1239
1241
  }), a);
1240
1242
  return u.current.push(l), u.current.length === 1 && p({ open: !0 }), l.key;
1241
- }, []), O = (a = "", l = {}) => v(i({ message: a, severity: "success" }, l)), C = (a = "", l = {}) => v(i({ message: a, severity: "info" }, l)), m = (a = "", l = {}) => v(i({ message: a, severity: "warning" }, l)), g = (a = "", l = {}) => v(i({ message: a, severity: "error" }, l)), T = (a) => {
1243
+ }, []), O = (a = "", l = {}) => v(i({ message: a, severity: "success" }, l)), C = (a = "", l = {}) => v(i({ message: a, severity: "info" }, l)), m = (a = "", l = {}) => v(i({ message: a, severity: "warning" }, l)), h = (a = "", l = {}) => v(i({ message: a, severity: "error" }, l)), T = (a) => {
1242
1244
  const l = u.current.findIndex((x) => x.key === a);
1243
1245
  if (l !== -1)
1244
1246
  return l === 0 ? (p({ open: !1 }), u.current[0]) : u.current.splice(l, 1);
@@ -1250,21 +1252,21 @@ function zn(c) {
1250
1252
  }, k = (R = u.current[0]) != null ? R : i({}, qe), _ = {};
1251
1253
  "autoHideDuration" in k && (_.autoHideDuration = k.autoHideDuration);
1252
1254
  const F = i(i({}, Nn), s), H = i(i({
1253
- open: h,
1254
- setOpen: S,
1255
+ open: g,
1256
+ setOpen: A,
1255
1257
  enqueueNotification: v,
1256
1258
  enqueueSuccessNotification: O,
1257
1259
  enqueueInfoNotification: C,
1258
1260
  enqueueWarningNotification: m,
1259
- enqueueErrorNotification: g,
1261
+ enqueueErrorNotification: h,
1260
1262
  removeNotification: T
1261
1263
  }, e), t);
1262
1264
  return /* @__PURE__ */ f(xt.Provider, { value: H, children: [
1263
1265
  r,
1264
1266
  /* @__PURE__ */ o(
1265
1267
  Ht,
1266
- A(i(i({}, F), _), {
1267
- open: h,
1268
+ S(i(i({}, F), _), {
1269
+ open: g,
1268
1270
  onClose: M,
1269
1271
  TransitionProps: {
1270
1272
  onExited: B,
@@ -1296,7 +1298,7 @@ function Gn() {
1296
1298
  return e;
1297
1299
  }
1298
1300
  const Do = se(
1299
- (e = { autoHideDuration: 1 }, t = {}, n = {}) => ({ children: r }) => /* @__PURE__ */ o(zn, A(i({}, e), { overrideState: t, overrideActions: n, children: r }))
1301
+ (e = { autoHideDuration: 1 }, t = {}, n = {}) => ({ children: r }) => /* @__PURE__ */ o(zn, S(i({}, e), { overrideState: t, overrideActions: n, children: r }))
1300
1302
  ), Un = en(), Oo = ({
1301
1303
  children: e,
1302
1304
  store: t
@@ -1332,13 +1334,13 @@ const Qe = L(
1332
1334
  applicationName: s,
1333
1335
  handleLogout: c
1334
1336
  }) => {
1335
- const [d, h] = X(bt), [p, u] = $(d), { enqueueSuccessNotification: w } = Gn(), b = r.length === 0, S = !!d && !r.includes(d) && !r.includes(p), v = !d || b || S, O = () => z(void 0, null, function* () {
1336
- p ? (h(p), w(`Set domain to ${p}`), n()) : h("");
1337
+ const [d, g] = X(bt), [p, u] = $(d), { enqueueSuccessNotification: w } = Gn(), b = r.length === 0, A = !!d && !r.includes(d) && !r.includes(p), v = !d || b || A, O = () => z(void 0, null, function* () {
1338
+ p ? (g(p), w(`Set domain to ${p}`), n()) : g("");
1337
1339
  }), C = () => z(void 0, null, function* () {
1338
- d && !b && !S ? (u(d), n()) : v && c();
1340
+ d && !b && !A ? (u(d), n()) : v && c();
1339
1341
  });
1340
1342
  let m;
1341
- return b ? m = "Unable to retrieve your active organisations. Try logging in again." : S && (m = "You no longer have any roles in your chosen organisation. Please choose another."), /* @__PURE__ */ f(
1343
+ return b ? m = "Unable to retrieve your active organisations. Try logging in again." : A && (m = "You no longer have any roles in your chosen organisation. Please choose another."), /* @__PURE__ */ f(
1342
1344
  pn,
1343
1345
  {
1344
1346
  isOpen: t,
@@ -1346,7 +1348,7 @@ const Qe = L(
1346
1348
  primaryButton: {
1347
1349
  text: "Confirm",
1348
1350
  onClick: O,
1349
- disabled: !p || b || S,
1351
+ disabled: !p || b || A,
1350
1352
  buttonColor: "primary"
1351
1353
  },
1352
1354
  secondaryButton: {
@@ -1368,18 +1370,18 @@ const Qe = L(
1368
1370
  multiple: !1,
1369
1371
  disableClearable: !1,
1370
1372
  value: p !== "" ? p : null,
1371
- onChange: (g, T) => u(T != null ? T : ""),
1373
+ onChange: (h, T) => u(T != null ? T : ""),
1372
1374
  getOptionLabel: qn,
1373
1375
  options: [...r],
1374
- renderInput: (g) => /* @__PURE__ */ o(
1376
+ renderInput: (h) => /* @__PURE__ */ o(
1375
1377
  Se,
1376
- A(i({}, g), {
1378
+ S(i({}, h), {
1377
1379
  variant: "filled",
1378
1380
  label: "Select organisation",
1379
- InputProps: A(i({}, g.InputProps), {
1381
+ InputProps: S(i({}, h.InputProps), {
1380
1382
  endAdornment: /* @__PURE__ */ f(P, { children: [
1381
1383
  e ? /* @__PURE__ */ o(De, { color: "inherit", size: 20, sx: { marginTop: "-20px" } }) : null,
1382
- g.InputProps.endAdornment
1384
+ h.InputProps.endAdornment
1383
1385
  ] })
1384
1386
  })
1385
1387
  })