@firecms/core 3.0.0-canary.78 → 3.0.0-canary.79

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/index.es.js CHANGED
@@ -4,7 +4,7 @@ import S, { useRef as ce, useEffect as z, useContext as $e, useCallback as x, us
4
4
  import { SnackbarProvider as Fa, useSnackbar as Pa } from "notistack";
5
5
  import Ji from "object-hash";
6
6
  import { useCreateFormex as In, Formex as Nn, setIn as ti, Field as Fn, getIn as _t, useFormex as fi } from "@firecms/formex";
7
- import { getColorSchemeForSeed as Pn, CHIP_COLORS as Qa, Tooltip as ke, ErrorIcon as Qn, Typography as Y, CircleIcon as Dn, FunctionsIcon as Da, iconKeys as hi, coolIconKeys as ri, Icon as gi, IconButton as de, ContentCopyIcon as vr, OpenInNewIcon as Zt, DescriptionIcon as Rn, cls as L, Skeleton as Le, Chip as Ai, defaultBorderMixin as Se, KeyboardTabIcon as bi, Checkbox as Xt, Markdown as yi, TextareaAutosize as Ra, MultiSelect as Tn, MultiSelectItem as On, Select as nt, SelectItem as ot, BooleanSwitch as Ta, DateTimeField as Kt, paperMixin as kr, ErrorOutlineIcon as Oa, EditIcon as za, Button as ge, RemoveCircleIcon as Ma, Menu as It, MoreVertIcon as zn, MenuItem as Pe, CircularProgress as xt, SearchBar as wi, Badge as Hi, ArrowUpwardIcon as Gr, Popover as vi, FilterListIcon as Va, AssignmentIcon as Ga, CenteredView as sr, Label as ki, TextField as Et, ClearIcon as Ut, BooleanSwitchWithLabel as _r, useOutsideAlerter as Mn, Dialog as _i, DialogContent as xi, DialogActions as Nt, FileCopyIcon as ja, ArchiveIcon as Ya, DeleteIcon as ii, AddIcon as pt, ExpandablePanel as ft, Card as Ua, ArrowForwardIcon as Vn, cardMixin as La, cardClickableMixin as $a, focusedMixin as ni, StarIcon as Gn, StarBorderIcon as jn, Collapse as Yn, Container as qa, FilterListOffIcon as Wa, SearchIcon as Ja, LoadingButton as Ha, Avatar as Zi, DarkModeIcon as Za, LightModeIcon as Xa, LogoutIcon as Ka, fieldBackgroundHoverMixin as xr, HandleIcon as es, RemoveIcon as Ei, debounce as ts, InfoIcon as rs, CloseIcon as Un, fieldBackgroundMixin as pr, fieldBackgroundDisabledMixin as Ln, ArrowDropDownIcon as $n, useInjectStyles as is, ShortTextIcon as ns, SubjectIcon as os, FormatQuoteIcon as as, HttpIcon as ss, EmailIcon as ls, FlagIcon as cs, ListIcon as ds, ListAltIcon as us, NumbersIcon as ms, FormatListNumberedIcon as Xi, UploadFileIcon as ps, DriveFolderUploadIcon as fs, LinkIcon as hs, AddLinkIcon as gs, ScheduleIcon as As, BallotIcon as Ki, RepeatIcon as en, ViewStreamIcon as bs, Tab as jr, Tabs as ys, Alert as ws, Sheet as qn, useLocaleConfig as vs, MenuIcon as tn, ChevronLeftIcon as ks } from "@firecms/ui";
7
+ import { getColorSchemeForSeed as Pn, CHIP_COLORS as Qa, Tooltip as ke, ErrorIcon as Qn, Typography as U, CircleIcon as Dn, FunctionsIcon as Da, iconKeys as hi, coolIconKeys as ri, Icon as gi, IconButton as de, ContentCopyIcon as vr, OpenInNewIcon as Zt, DescriptionIcon as Rn, cls as L, Skeleton as Le, Chip as Ai, defaultBorderMixin as Se, KeyboardTabIcon as bi, Checkbox as Xt, Markdown as yi, TextareaAutosize as Ra, MultiSelect as Tn, MultiSelectItem as On, Select as nt, SelectItem as ot, BooleanSwitch as Ta, DateTimeField as Kt, paperMixin as kr, ErrorOutlineIcon as Oa, EditIcon as za, Button as ge, RemoveCircleIcon as Ma, Menu as It, MoreVertIcon as zn, MenuItem as Pe, CircularProgress as xt, SearchBar as wi, Badge as Hi, ArrowUpwardIcon as Gr, Popover as vi, FilterListIcon as Va, AssignmentIcon as Ga, CenteredView as sr, Label as ki, TextField as Et, ClearIcon as Ut, BooleanSwitchWithLabel as _r, useOutsideAlerter as Mn, Dialog as _i, DialogContent as xi, DialogActions as Nt, FileCopyIcon as ja, ArchiveIcon as Ya, DeleteIcon as ii, AddIcon as pt, ExpandablePanel as ft, Card as Ua, ArrowForwardIcon as Vn, cardMixin as La, cardClickableMixin as $a, focusedMixin as ni, StarIcon as Gn, StarBorderIcon as jn, Collapse as Yn, Container as qa, FilterListOffIcon as Wa, SearchIcon as Ja, LoadingButton as Ha, Avatar as Zi, DarkModeIcon as Za, LightModeIcon as Xa, LogoutIcon as Ka, fieldBackgroundHoverMixin as xr, HandleIcon as es, RemoveIcon as Ei, debounce as ts, InfoIcon as rs, CloseIcon as Un, fieldBackgroundMixin as pr, fieldBackgroundDisabledMixin as Ln, ArrowDropDownIcon as $n, useInjectStyles as is, ShortTextIcon as ns, SubjectIcon as os, FormatQuoteIcon as as, HttpIcon as ss, EmailIcon as ls, FlagIcon as cs, ListIcon as ds, ListAltIcon as us, NumbersIcon as ms, FormatListNumberedIcon as Xi, UploadFileIcon as ps, DriveFolderUploadIcon as fs, LinkIcon as hs, AddLinkIcon as gs, ScheduleIcon as As, BallotIcon as Ki, RepeatIcon as en, ViewStreamIcon as bs, Tab as jr, Tabs as ys, Alert as ws, Sheet as qn, useLocaleConfig as vs, MenuIcon as tn, ChevronLeftIcon as ks } from "@firecms/ui";
8
8
  import J from "react-fast-compare";
9
9
  import { Link as Er, useNavigate as Ft, useLocation as Cr, UNSAFE_NavigationContext as _s, NavLink as xs, Route as lr, Routes as Es } from "react-router-dom";
10
10
  import { format as Cs } from "date-fns";
@@ -365,14 +365,14 @@ function Ne({
365
365
  /* @__PURE__ */ n(Qn, { size: "small", color: "error" }),
366
366
  /* @__PURE__ */ v("div", { className: "pl-2", children: [
367
367
  e && /* @__PURE__ */ n(
368
- Y,
368
+ U,
369
369
  {
370
370
  variant: "body2",
371
371
  className: "font-medium",
372
372
  children: e
373
373
  }
374
374
  ),
375
- /* @__PURE__ */ n(Y, { variant: "body2", children: i })
375
+ /* @__PURE__ */ n(U, { variant: "body2", children: i })
376
376
  ] })
377
377
  ]
378
378
  }
@@ -3379,7 +3379,7 @@ function bm(e) {
3379
3379
  z(() => {
3380
3380
  oe();
3381
3381
  }, [oe]);
3382
- const U = x((T, ne = !1) => {
3382
+ const Y = x((T, ne = !1) => {
3383
3383
  const K = u.current;
3384
3384
  if (!K)
3385
3385
  return;
@@ -3469,7 +3469,7 @@ function bm(e) {
3469
3469
  basePath: t,
3470
3470
  baseCollectionPath: r,
3471
3471
  initialised: g,
3472
- getCollection: U,
3472
+ getCollection: Y,
3473
3473
  getCollectionFromPaths: X,
3474
3474
  getCollectionFromIds: q,
3475
3475
  isUrlCollectionPath: V,
@@ -3704,51 +3704,43 @@ function yl({
3704
3704
  }
3705
3705
  }
3706
3706
  ),
3707
- navigator && /* @__PURE__ */ n(ke, { title: "Copy url to clipboard", children: /* @__PURE__ */ n(
3708
- "div",
3709
- {
3710
- className: "rounded-full absolute bottom-[-4px] right-8 invisible group-hover:visible",
3711
- children: /* @__PURE__ */ n(
3712
- de,
3713
- {
3714
- variant: "filled",
3715
- size: "small",
3716
- onClick: (a) => (a.stopPropagation(), a.preventDefault(), navigator.clipboard.writeText(t)),
3717
- children: /* @__PURE__ */ n(
3718
- vr,
3719
- {
3720
- className: "text-gray-700 dark:text-gray-300",
3721
- size: "small"
3722
- }
3723
- )
3724
- }
3725
- )
3726
- }
3727
- ) }),
3728
- /* @__PURE__ */ n(ke, { title: "Open image in new tab", children: /* @__PURE__ */ n(
3729
- de,
3730
- {
3731
- variant: "filled",
3732
- component: "a",
3733
- style: {
3734
- position: "absolute",
3735
- bottom: -4,
3736
- right: -4
3737
- },
3738
- href: t,
3739
- rel: "noopener noreferrer",
3740
- target: "_blank",
3741
- size: "small",
3742
- onClick: (a) => a.stopPropagation(),
3743
- children: /* @__PURE__ */ n(
3744
- Zt,
3745
- {
3746
- className: "text-gray-700 dark:text-gray-300 invisible group-hover:visible",
3747
- size: "small"
3748
- }
3749
- )
3750
- }
3751
- ) })
3707
+ /* @__PURE__ */ v("div", { className: "flex flex-row gap-2 absolute bottom-[-4px] right-[-4px] invisible group-hover:visible", children: [
3708
+ navigator && /* @__PURE__ */ n(ke, { title: "Copy url to clipboard", side: "bottom", children: /* @__PURE__ */ n(
3709
+ de,
3710
+ {
3711
+ variant: "filled",
3712
+ size: "small",
3713
+ onClick: (a) => (a.stopPropagation(), a.preventDefault(), navigator.clipboard.writeText(t)),
3714
+ children: /* @__PURE__ */ n(
3715
+ vr,
3716
+ {
3717
+ className: "text-gray-700 dark:text-gray-300",
3718
+ size: "small"
3719
+ }
3720
+ )
3721
+ }
3722
+ ) }),
3723
+ /* @__PURE__ */ n(ke, { title: "Open image in new tab", side: "bottom", children: /* @__PURE__ */ n(
3724
+ de,
3725
+ {
3726
+ className: "invisible group-hover:visible",
3727
+ variant: "filled",
3728
+ component: "a",
3729
+ href: t,
3730
+ rel: "noopener noreferrer",
3731
+ target: "_blank",
3732
+ size: "small",
3733
+ onClick: (a) => a.stopPropagation(),
3734
+ children: /* @__PURE__ */ n(
3735
+ Zt,
3736
+ {
3737
+ className: "text-gray-700 dark:text-gray-300",
3738
+ size: "small"
3739
+ }
3740
+ )
3741
+ }
3742
+ ) })
3743
+ ] })
3752
3744
  ]
3753
3745
  },
3754
3746
  "image_preview_" + t
@@ -3794,7 +3786,7 @@ function Ar({
3794
3786
  children: [
3795
3787
  /* @__PURE__ */ n(Rn, { className: "text-gray-700 dark:text-gray-300" }),
3796
3788
  i && /* @__PURE__ */ n(ke, { title: i, children: /* @__PURE__ */ n(
3797
- Y,
3789
+ U,
3798
3790
  {
3799
3791
  className: "max-w-full truncate rtl text-left",
3800
3792
  variant: "caption",
@@ -4200,7 +4192,7 @@ function Pl({
4200
4192
  ) }),
4201
4193
  /* @__PURE__ */ v("div", { className: "flex flex-col flex-grow w-full m-1", children: [
4202
4194
  s !== "tiny" && l && (d ? /* @__PURE__ */ n("div", { className: `${s !== "medium" ? "block whitespace-nowrap overflow-hidden truncate" : ""}`, children: /* @__PURE__ */ n(
4203
- Y,
4195
+ U,
4204
4196
  {
4205
4197
  variant: "caption",
4206
4198
  color: "disabled",
@@ -4335,7 +4327,7 @@ const vt = kt.memo(To), et = kt.memo(function(t) {
4335
4327
  ));
4336
4328
  }, Ql);
4337
4329
  function Ql(e, t) {
4338
- return e.disabled === t.disabled && e.size === t.size && e.hover === t.hover && e.reference?.id === t.reference?.id && e.reference?.path === t.reference?.path && e.includeEntityLink === t.includeEntityLink;
4330
+ return e.disabled === t.disabled && e.size === t.size && e.hover === t.hover && e.reference?.id === t.reference?.id && e.reference?.path === t.reference?.path && e.includeEntityLink === t.includeEntityLink && e.onClick === t.onClick;
4339
4331
  }
4340
4332
  function Dl({
4341
4333
  disabled: e,
@@ -4668,7 +4660,7 @@ function Vl({
4668
4660
  {
4669
4661
  className: "min-w-[140px] w-[25%] py-1",
4670
4662
  children: /* @__PURE__ */ n(
4671
- Y,
4663
+ U,
4672
4664
  {
4673
4665
  variant: "caption",
4674
4666
  className: "font-mono break-words",
@@ -4733,7 +4725,7 @@ function zo({ value: e }) {
4733
4725
  {
4734
4726
  className: "min-w-[140px] w-[25%] py-1",
4735
4727
  children: /* @__PURE__ */ n(
4736
- Y,
4728
+ U,
4737
4729
  {
4738
4730
  variant: "caption",
4739
4731
  className: "font-mono break-words",
@@ -4748,7 +4740,7 @@ function zo({ value: e }) {
4748
4740
  "div",
4749
4741
  {
4750
4742
  className: "flex-grow max-w-[75%]",
4751
- children: typeof r != "object" && /* @__PURE__ */ n(Y, { children: /* @__PURE__ */ n(pe, { children: r && r.toString() }) })
4743
+ children: typeof r != "object" && /* @__PURE__ */ n(U, { children: /* @__PURE__ */ n(pe, { children: r && r.toString() }) })
4752
4744
  }
4753
4745
  )
4754
4746
  ]
@@ -5377,7 +5369,7 @@ class pe extends S.Component {
5377
5369
  /* @__PURE__ */ n(Qn, { color: "error", size: "small" }),
5378
5370
  /* @__PURE__ */ n("div", { className: "ml-4", children: "Error" })
5379
5371
  ] }),
5380
- /* @__PURE__ */ n(Y, { variant: "caption", children: this.state.error?.message ?? "See the error in the console" })
5372
+ /* @__PURE__ */ n(U, { variant: "caption", children: this.state.error?.message ?? "See the error in the console" })
5381
5373
  ] }) : this.props.children;
5382
5374
  }
5383
5375
  }
@@ -5791,7 +5783,7 @@ function rc({
5791
5783
  });
5792
5784
  }
5793
5785
  }
5794
- ), { ...$ } = B(), oe = d ? "Drag 'n' drop some files here, or click here to edit" : "Drag 'n' drop a file here, or click here edit", U = d ? e.of : e, X = he(() => Ct(y), [y]), q = !m && l;
5786
+ ), { ...$ } = B(), oe = d ? "Drag 'n' drop some files here, or click here to edit" : "Drag 'n' drop a file here, or click here edit", Y = d ? e.of : e, X = he(() => Ct(y), [y]), q = !m && l;
5795
5787
  return /* @__PURE__ */ v(
5796
5788
  "div",
5797
5789
  {
@@ -5814,7 +5806,7 @@ function rc({
5814
5806
  return V.storagePathOrDownloadUrl ? te = /* @__PURE__ */ n(
5815
5807
  ic,
5816
5808
  {
5817
- property: U,
5809
+ property: Y,
5818
5810
  value: V.storagePathOrDownloadUrl,
5819
5811
  entity: o,
5820
5812
  size: y
@@ -5839,7 +5831,7 @@ function rc({
5839
5831
  className: "flex-grow m-2 max-w-[200px]",
5840
5832
  onClick: C,
5841
5833
  children: /* @__PURE__ */ n(
5842
- Y,
5834
+ U,
5843
5835
  {
5844
5836
  className: "text-gray-400 dark:text-gray-600",
5845
5837
  variant: "body2",
@@ -6339,7 +6331,7 @@ const fc = ({
6339
6331
  o ? f(void 0) : !a && Ae && f(Ae);
6340
6332
  }, [y, f, a, o]), $ = x((Ae) => {
6341
6333
  M(), Ae.stopPropagation();
6342
- }, [M]), oe = he(() => b ? b.height > k : !1, [b, k]), U = !P && a, X = !o && p && oe, q = !o && !p && oe, V = x(() => E(!0), []), ae = x(() => E(!1), []), te = P ? "border-red-500" : C ? "border-green-500" : U ? "border-primary" : "border-transparent";
6334
+ }, [M]), oe = he(() => b ? b.height > k : !1, [b, k]), Y = !P && a, X = !o && p && oe, q = !o && !p && oe, V = x(() => E(!0), []), ae = x(() => E(!1), []), te = P ? "border-red-500" : C ? "border-green-500" : Y ? "border-primary" : "border-transparent";
6343
6335
  return /* @__PURE__ */ v(
6344
6336
  "div",
6345
6337
  {
@@ -6349,7 +6341,7 @@ const fc = ({
6349
6341
  _ && !o ? "bg-gray-50 dark:bg-gray-900" : "",
6350
6342
  l ? "bg-gray-100 bg-opacity-75 dark:bg-gray-800 dark:bg-opacity-75" : "",
6351
6343
  g ? "overflow-hidden" : "",
6352
- U ? "bg-gray-50 dark:bg-gray-900" : "",
6344
+ Y ? "bg-gray-50 dark:bg-gray-900" : "",
6353
6345
  te
6354
6346
  ),
6355
6347
  ref: y,
@@ -6436,7 +6428,7 @@ const Ac = S.memo(
6436
6428
  F(!0), setTimeout(() => {
6437
6429
  F(!1);
6438
6430
  }, 100);
6439
- }, []), $ = !!a.Field, oe = !!a.Preview, U = er(a), X = typeof a.disabled == "object" ? a.disabled.disabledMessage : void 0, q = p || m || !!a.disabled, V = he(() => Jt({
6431
+ }, []), $ = !!a.Field, oe = !!a.Preview, Y = er(a), X = typeof a.disabled == "object" ? a.disabled.disabledMessage : void 0, q = p || m || !!a.disabled, V = he(() => Jt({
6440
6432
  property: a,
6441
6433
  entityId: d.id,
6442
6434
  customFieldValidator: r,
@@ -6497,7 +6489,7 @@ const Ac = S.memo(
6497
6489
  };
6498
6490
  let se, ee = !1, T = !1, ne = !0, K = !1, H = !1, j = !0;
6499
6491
  const G = !q && E;
6500
- if (p || U)
6492
+ if (p || Y)
6501
6493
  return /* @__PURE__ */ n(
6502
6494
  br,
6503
6495
  {
@@ -6507,7 +6499,7 @@ const Ac = S.memo(
6507
6499
  value: y,
6508
6500
  align: o ?? "left",
6509
6501
  fullHeight: !1,
6510
- disabledTooltip: X ?? (U ? "Read only" : void 0),
6502
+ disabledTooltip: X ?? (Y ? "Read only" : void 0),
6511
6503
  disabled: !0,
6512
6504
  children: /* @__PURE__ */ n(
6513
6505
  Fe,
@@ -6680,7 +6672,7 @@ const Ac = S.memo(
6680
6672
  )), ee = !1));
6681
6673
  }
6682
6674
  }
6683
- return se || (ee = !1, T = u && b && !se && !q && !U, se = /* @__PURE__ */ n(
6675
+ return se || (ee = !1, T = u && b && !se && !q && !Y, se = /* @__PURE__ */ n(
6684
6676
  Fe,
6685
6677
  {
6686
6678
  width: s,
@@ -6697,7 +6689,7 @@ const Ac = S.memo(
6697
6689
  width: s,
6698
6690
  onSelect: Ae,
6699
6691
  selected: b,
6700
- disabled: q || U,
6692
+ disabled: q || Y,
6701
6693
  disabledTooltip: X ?? "Disabled",
6702
6694
  removePadding: K,
6703
6695
  fullHeight: H,
@@ -6827,22 +6819,16 @@ const Qi = function({
6827
6819
  }
6828
6820
  ) })
6829
6821
  ] }),
6830
- !f && c !== "xs" && /* @__PURE__ */ n("div", { className: "w-[138px] text-center overflow-hidden truncate", children: t ? /* @__PURE__ */ v(
6831
- Y,
6822
+ !f && c !== "xs" && /* @__PURE__ */ n(
6823
+ "div",
6832
6824
  {
6825
+ className: "w-[138px] text-center overflow-hidden truncate font-mono text-xs text-text-secondary dark:text-text-secondary-dark max-w-full text-ellipsis px-2",
6833
6826
  onClick: (C) => {
6834
6827
  C.stopPropagation();
6835
6828
  },
6836
- className: "font-mono select-all",
6837
- variant: "caption",
6838
- color: "secondary",
6839
- children: [
6840
- " ",
6841
- t.id,
6842
- " "
6843
- ]
6829
+ children: t ? t.id : /* @__PURE__ */ n(Le, {})
6844
6830
  }
6845
- ) : /* @__PURE__ */ n(Le, {}) })
6831
+ )
6846
6832
  ]
6847
6833
  }
6848
6834
  );
@@ -7022,7 +7008,7 @@ function yr({ text: e, ...t }) {
7022
7008
  children: /* @__PURE__ */ v("div", { className: "m-auto flex flex-col gap-2 items-center", children: [
7023
7009
  /* @__PURE__ */ n(xt, { ...t }),
7024
7010
  e && /* @__PURE__ */ n(
7025
- Y,
7011
+ U,
7026
7012
  {
7027
7013
  color: "secondary",
7028
7014
  variant: "caption",
@@ -7448,7 +7434,7 @@ const Sc = Ia(({
7448
7434
  z(() => {
7449
7435
  F(o);
7450
7436
  }, [o]);
7451
- const [oe, U] = Wn(), X = x((j) => {
7437
+ const [oe, Y] = Wn(), X = x((j) => {
7452
7438
  F(D.map((G) => G.key === j.column.key ? j.column : G));
7453
7439
  }, [D]), q = x((j) => {
7454
7440
  F(D.map((G) => G.key === j.column.key ? j.column : G)), l && l(j);
@@ -7465,7 +7451,7 @@ const Sc = Ia(({
7465
7451
  x(() => {
7466
7452
  $.current = 0, h && h(void 0);
7467
7453
  }, [h]);
7468
- const Ae = Math.max((t?.length ?? 0) * a - U.height, 0), ue = x((j) => {
7454
+ const Ae = Math.max((t?.length ?? 0) * a - Y.height, 0), ue = x((j) => {
7469
7455
  i && (t?.length ?? 0) > 0 && j > $.current + 600 && ($.current = j, i());
7470
7456
  }, [t?.length, i]), se = x(({
7471
7457
  scrollOffset: j,
@@ -7492,7 +7478,7 @@ const Sc = Ia(({
7492
7478
  maxWidth: "2xl",
7493
7479
  className: "flex flex-col gap-2",
7494
7480
  children: [
7495
- /* @__PURE__ */ n(Y, { variant: "h6", children: "Error fetching data from the data source" }),
7481
+ /* @__PURE__ */ n(U, { variant: "h6", children: "Error fetching data from the data source" }),
7496
7482
  u?.message && /* @__PURE__ */ n(Fc, { text: u.message })
7497
7483
  ]
7498
7484
  }
@@ -7530,8 +7516,8 @@ const Sc = Ia(({
7530
7516
  Nc,
7531
7517
  {
7532
7518
  outerRef: M,
7533
- width: U.width,
7534
- height: U.height,
7519
+ width: Y.width,
7520
+ height: Y.height,
7535
7521
  itemCount: (t?.length ?? 0) + (E ? 1 : 0),
7536
7522
  onScroll: se,
7537
7523
  includeAddColumn: !!C,
@@ -7663,9 +7649,9 @@ function Pc({
7663
7649
  const M = Jr.includes(u), $ = Jr.includes(D);
7664
7650
  let oe = F;
7665
7651
  M !== $ && (oe = $ ? oe?.isEntityReference && oe?.isEntityReference() ? [oe] : [] : void 0), f(D), g(oe);
7666
- const U = oe !== null && Array.isArray(oe) ? oe.length > 0 : oe !== void 0;
7652
+ const Y = oe !== null && Array.isArray(oe) ? oe.length > 0 : oe !== void 0;
7667
7653
  r(
7668
- D && U ? [D, oe] : void 0
7654
+ D && Y ? [D, oe] : void 0
7669
7655
  );
7670
7656
  }
7671
7657
  const b = _e(), y = he(() => a ? b.getCollection(a) : void 0, [a]), k = (D) => {
@@ -8018,7 +8004,7 @@ const Tc = S.memo(
8018
8004
  endAdornment: $,
8019
8005
  AddColumnComponent: oe
8020
8006
  }) {
8021
- const U = ce(null), [X, q] = S.useState(void 0), V = () => {
8007
+ const Y = ce(null), [X, q] = S.useState(void 0), V = () => {
8022
8008
  !_ || d || p || b !== void 0 && y?.(b + k);
8023
8009
  }, ae = x(() => {
8024
8010
  y?.(k);
@@ -8027,7 +8013,7 @@ const Tc = S.memo(
8027
8013
  return i && i(ee);
8028
8014
  }, [i, l]);
8029
8015
  Mn(
8030
- U,
8016
+ Y,
8031
8017
  () => {
8032
8018
  X && ue();
8033
8019
  },
@@ -8061,7 +8047,7 @@ const Tc = S.memo(
8061
8047
  "div",
8062
8048
  {
8063
8049
  className: "h-full w-full flex flex-col bg-white dark:bg-gray-950",
8064
- ref: U,
8050
+ ref: Y,
8065
8051
  children: /* @__PURE__ */ n(
8066
8052
  Ic,
8067
8053
  {
@@ -8198,7 +8184,7 @@ const Ho = function({
8198
8184
  AdditionalHeaderWidget: M,
8199
8185
  additionalIDHeaderWidget: $,
8200
8186
  emptyComponent: oe,
8201
- getIdColumnWidth: U,
8187
+ getIdColumnWidth: Y,
8202
8188
  onTextSearchClick: X,
8203
8189
  textSearchLoading: q,
8204
8190
  enablePopupIcon: V
@@ -8281,7 +8267,7 @@ const Ho = function({
8281
8267
  })(), Ie = [
8282
8268
  {
8283
8269
  key: "id_ewcfedcswdf3",
8284
- width: U?.() ?? (te ? 160 : 130),
8270
+ width: Y?.() ?? (te ? 160 : 130),
8285
8271
  title: "ID",
8286
8272
  resizable: !1,
8287
8273
  frozen: te,
@@ -8418,7 +8404,7 @@ function Zo({
8418
8404
  z(() => {
8419
8405
  J(f, _) || E(f);
8420
8406
  }, [f]);
8421
- const [_, E] = S.useState(f ?? o ?? void 0), [C, B] = S.useState(k), P = C ? C[0] : void 0, D = C ? C[1] : void 0, F = Re(), [M, $] = Q([]), [oe, U] = Q(!1), [X, q] = Q(), [V, ae] = Q(!1), te = x((T, ne) => m.isFilterCombinationValid ? m.isFilterCombinationValid({
8407
+ const [_, E] = S.useState(f ?? o ?? void 0), [C, B] = S.useState(k), P = C ? C[0] : void 0, D = C ? C[1] : void 0, F = Re(), [M, $] = Q([]), [oe, Y] = Q(!1), [X, q] = Q(), [V, ae] = Q(!1), te = x((T, ne) => m.isFilterCombinationValid ? m.isFilterCombinationValid({
8422
8408
  path: u,
8423
8409
  collection: t,
8424
8410
  filterValues: T,
@@ -8431,7 +8417,7 @@ function Zo({
8431
8417
  T && Object.keys(T).length === 0 ? E(void 0) : E(T);
8432
8418
  }, [f]);
8433
8419
  z(() => {
8434
- U(!0);
8420
+ Y(!0);
8435
8421
  const T = async (K) => {
8436
8422
  if (t.callbacks?.onFetch)
8437
8423
  try {
@@ -8446,12 +8432,12 @@ function Zo({
8446
8432
  } catch (H) {
8447
8433
  console.error(H);
8448
8434
  }
8449
- U(!1), q(void 0), $(K.map((H) => ({
8435
+ Y(!1), q(void 0), $(K.map((H) => ({
8450
8436
  ...H
8451
8437
  // values: sanitizeData(e.values, resolvedCollection.properties)
8452
8438
  }))), ae(!b || K.length < b);
8453
8439
  }, ne = (K) => {
8454
- console.error("ERROR", K), U(!1), $([]), q(K);
8440
+ console.error("ERROR", K), Y(!1), $([]), q(K);
8455
8441
  };
8456
8442
  return m.listenCollection ? m.listenCollection({
8457
8443
  path: u,
@@ -8654,7 +8640,7 @@ function ea({
8654
8640
  onOpenChange: (M) => M ? void 0 : r(),
8655
8641
  children: [
8656
8642
  /* @__PURE__ */ v(xi, { fullHeight: !0, children: [
8657
- /* @__PURE__ */ n(Y, { variant: "subtitle2", className: "p-4", children: F }),
8643
+ /* @__PURE__ */ n(U, { variant: "subtitle2", className: "p-4", children: F }),
8658
8644
  !g && /* @__PURE__ */ n("div", { className: "p-4", children: D })
8659
8645
  ] }),
8660
8646
  /* @__PURE__ */ v(Nt, { children: [
@@ -8904,7 +8890,7 @@ function jc({
8904
8890
  textSearchLoading: M,
8905
8891
  textSearchInitialised: $,
8906
8892
  onTextSearchClick: oe,
8907
- textSearchEnabled: U
8893
+ textSearchEnabled: Y
8908
8894
  } = (
8909
8895
  // eslint-disable-next-line react-hooks/rules-of-hooks
8910
8896
  Ko({
@@ -8918,13 +8904,13 @@ function jc({
8918
8904
  {
8919
8905
  textSearchLoading: M,
8920
8906
  onTextSearchClick: $ ? void 0 : oe,
8921
- textSearchEnabled: U,
8907
+ textSearchEnabled: Y,
8922
8908
  displayedColumnIds: D,
8923
8909
  onEntityClick: _,
8924
8910
  tableController: F,
8925
8911
  enablePopupIcon: !1,
8926
8912
  tableRowActionsBuilder: C,
8927
- title: /* @__PURE__ */ n(Y, { variant: "subtitle2", children: i.singularName ? `Select ${i.singularName}` : `Select from ${i.name}` }),
8913
+ title: /* @__PURE__ */ n(U, { variant: "subtitle2", children: i.singularName ? `Select ${i.singularName}` : `Select from ${i.name}` }),
8928
8914
  defaultSize: i.defaultSize,
8929
8915
  properties: P.properties,
8930
8916
  forceFilter: l,
@@ -8943,7 +8929,7 @@ function jc({
8943
8929
  ) }),
8944
8930
  /* @__PURE__ */ v(Nt, { translucent: !1, children: [
8945
8931
  s && /* @__PURE__ */ n(
8946
- Y,
8932
+ U,
8947
8933
  {
8948
8934
  variant: "body2",
8949
8935
  className: "flex-grow text-left",
@@ -9029,7 +9015,7 @@ function xn({
9029
9015
  }
9030
9016
  },
9031
9017
  title: /* @__PURE__ */ n(
9032
- Y,
9018
+ U,
9033
9019
  {
9034
9020
  color: "secondary",
9035
9021
  className: "font-medium ml-1",
@@ -9080,7 +9066,7 @@ function Uc({
9080
9066
  }
9081
9067
  ),
9082
9068
  /* @__PURE__ */ n(
9083
- Y,
9069
+ U,
9084
9070
  {
9085
9071
  gutterBottom: !0,
9086
9072
  variant: "h5",
@@ -9089,7 +9075,7 @@ function Uc({
9089
9075
  }
9090
9076
  ),
9091
9077
  t && /* @__PURE__ */ n(
9092
- Y,
9078
+ U,
9093
9079
  {
9094
9080
  variant: "body2",
9095
9081
  color: "secondary",
@@ -9125,7 +9111,7 @@ function Lc({
9125
9111
  /* @__PURE__ */ v("div", { className: "flex flex-row items-center flex-grow gap-2 ", children: [
9126
9112
  r,
9127
9113
  /* @__PURE__ */ n(
9128
- Y,
9114
+ U,
9129
9115
  {
9130
9116
  gutterBottom: !0,
9131
9117
  variant: "h5",
@@ -9659,7 +9645,7 @@ function rd({
9659
9645
  i && E.properties[i] ? { [i]: E.properties[i] } : {},
9660
9646
  r
9661
9647
  );
9662
- }, [E, w, i, r]), U = x(() => $(g), [g, $]), X = async (G) => (h(null), a && b && d && i ? d({
9648
+ }, [E, w, i, r]), Y = x(() => $(g), [g, $]), X = async (G) => (h(null), a && b && d && i ? d({
9663
9649
  value: G[i],
9664
9650
  propertyKey: i,
9665
9651
  data: b,
@@ -9777,7 +9763,7 @@ function rd({
9777
9763
  className: `text-gray-900 dark:text-white overflow-auto rounded rounded-md bg-white dark:bg-gray-950 ${l ? "" : "hidden"} cursor-grab max-w-[100vw]`,
9778
9764
  children: [
9779
9765
  ne,
9780
- f && /* @__PURE__ */ n(Y, { color: "error", children: f.message })
9766
+ f && /* @__PURE__ */ n(U, { color: "error", children: f.message })
9781
9767
  ]
9782
9768
  }
9783
9769
  ), j = /* @__PURE__ */ v(
@@ -9789,7 +9775,7 @@ function rd({
9789
9775
  className: `inline-block fixed z-20 shadow-outline rounded-md bg-white dark:bg-gray-950 ${l ? "visible" : "invisible"} cursor-grab overflow-visible`,
9790
9776
  ref: B,
9791
9777
  children: [
9792
- /* @__PURE__ */ n(ed, { onResize: U }),
9778
+ /* @__PURE__ */ n(ed, { onResize: Y }),
9793
9779
  /* @__PURE__ */ v(
9794
9780
  "div",
9795
9781
  {
@@ -9921,7 +9907,7 @@ const od = "collectionGroupParent", ia = S.memo(
9921
9907
  }, [y]), M = x((W) => {
9922
9908
  const le = w.current;
9923
9909
  return fo(le, m, l, W ?? null) ? le.inlineEditing === void 0 || le.inlineEditing : !1;
9924
- }, [m, l]), $ = A.selectionEnabled === void 0 || A.selectionEnabled, oe = !M(), [U, X] = Q(!1), q = Xo(), V = A.selectionController ?? q, {
9910
+ }, [m, l]), $ = A.selectionEnabled === void 0 || A.selectionEnabled, oe = !M(), [Y, X] = Q(!1), q = Xo(), V = A.selectionController ?? q, {
9925
9911
  selectedEntities: ae,
9926
9912
  isEntitySelected: te,
9927
9913
  setSelectedEntities: Ae
@@ -10129,12 +10115,12 @@ const od = "collectionGroupParent", ia = S.memo(
10129
10115
  }, at = /* @__PURE__ */ n(
10130
10116
  vi,
10131
10117
  {
10132
- open: U,
10118
+ open: Y,
10133
10119
  onOpenChange: X,
10134
10120
  enabled: !!A.description,
10135
10121
  trigger: /* @__PURE__ */ v("div", { className: "flex flex-col items-start", children: [
10136
10122
  /* @__PURE__ */ n(
10137
- Y,
10123
+ U,
10138
10124
  {
10139
10125
  variant: "subtitle1",
10140
10126
  className: `leading-none truncate max-w-[160px] lg:max-w-[240px] ${A.description ? "cursor-pointer" : "cursor-auto"}`,
@@ -10253,7 +10239,7 @@ const od = "collectionGroupParent", ia = S.memo(
10253
10239
  }
10254
10240
  ),
10255
10241
  emptyComponent: b && ue.filterValues === void 0 && ue.sortBy === void 0 ? /* @__PURE__ */ v("div", { className: "flex flex-col items-center justify-center", children: [
10256
- /* @__PURE__ */ n(Y, { variant: "subtitle2", children: "So empty..." }),
10242
+ /* @__PURE__ */ n(U, { variant: "subtitle2", children: "So empty..." }),
10257
10243
  /* @__PURE__ */ v(
10258
10244
  ge,
10259
10245
  {
@@ -10267,7 +10253,7 @@ const od = "collectionGroupParent", ia = S.memo(
10267
10253
  ]
10268
10254
  }
10269
10255
  )
10270
- ] }) : /* @__PURE__ */ n(Y, { variant: "label", children: "No results with the applied filter/sort" }),
10256
+ ] }) : /* @__PURE__ */ n(U, { variant: "label", children: "No results with the applied filter/sort" }),
10271
10257
  hoverRow: oe,
10272
10258
  inlineEditing: M(),
10273
10259
  AdditionalHeaderWidget: zt,
@@ -10338,7 +10324,7 @@ function ad({
10338
10324
  }, [e, o.countEntities, f, t, r, m, u]), z(() => {
10339
10325
  a && (p(void 0), a(l ?? 0));
10340
10326
  }, [a, l]), d ? null : /* @__PURE__ */ n(
10341
- Y,
10327
+ U,
10342
10328
  {
10343
10329
  className: "w-full text-ellipsis block overflow-hidden whitespace-nowrap max-w-xs text-left w-fit-content",
10344
10330
  variant: "caption",
@@ -10427,7 +10413,7 @@ function ld() {
10427
10413
  className: "m-auto flex items-center flex-col",
10428
10414
  children: [
10429
10415
  /* @__PURE__ */ n(
10430
- Y,
10416
+ U,
10431
10417
  {
10432
10418
  variant: "h4",
10433
10419
  align: "center",
@@ -10435,7 +10421,7 @@ function ld() {
10435
10421
  children: "Page not found"
10436
10422
  }
10437
10423
  ),
10438
- /* @__PURE__ */ n(Y, { align: "center", gutterBottom: !0, children: "This page does not exist or you may not have access to it" }),
10424
+ /* @__PURE__ */ n(U, { align: "center", gutterBottom: !0, children: "This page does not exist or you may not have access to it" }),
10439
10425
  /* @__PURE__ */ n(
10440
10426
  ge,
10441
10427
  {
@@ -10464,7 +10450,7 @@ function Nm({
10464
10450
  onOpenChange: (s) => s ? void 0 : r(),
10465
10451
  children: [
10466
10452
  /* @__PURE__ */ v(xi, { children: [
10467
- /* @__PURE__ */ n(Y, { variant: "h6", className: "mb-2", children: i }),
10453
+ /* @__PURE__ */ n(U, { variant: "h6", className: "mb-2", children: i }),
10468
10454
  o
10469
10455
  ] }),
10470
10456
  /* @__PURE__ */ v(Nt, { children: [
@@ -10715,7 +10701,7 @@ const cd = function({
10715
10701
  }
10716
10702
  ) : /* @__PURE__ */ n(oa, { width: "32px", height: "32px" })),
10717
10703
  typeof t == "string" ? /* @__PURE__ */ n(
10718
- Y,
10704
+ U,
10719
10705
  {
10720
10706
  variant: "subtitle1",
10721
10707
  noWrap: !0,
@@ -10741,8 +10727,8 @@ const cd = function({
10741
10727
  ),
10742
10728
  /* @__PURE__ */ v(It, { trigger: y, children: [
10743
10729
  b && /* @__PURE__ */ v("div", { className: "px-4 py-2 mb-2", children: [
10744
- b.displayName && /* @__PURE__ */ n(Y, { variant: "body1", color: "secondary", children: b.displayName }),
10745
- b.email && /* @__PURE__ */ n(Y, { variant: "body2", color: "secondary", children: b.email })
10730
+ b.displayName && /* @__PURE__ */ n(U, { variant: "body1", color: "secondary", children: b.displayName }),
10731
+ b.email && /* @__PURE__ */ n(U, { variant: "body2", color: "secondary", children: b.email })
10746
10732
  ] }),
10747
10733
  a,
10748
10734
  !a && /* @__PURE__ */ v(Pe, { onClick: async () => {
@@ -11140,7 +11126,7 @@ function Qm({
11140
11126
  error: e,
11141
11127
  children: t
11142
11128
  }) {
11143
- return t ? /* @__PURE__ */ n(Y, { variant: "caption", color: e ? "error" : "secondary", className: "ml-3.5 mt-0.5", children: t }) : null;
11129
+ return t ? /* @__PURE__ */ n(U, { variant: "caption", color: e ? "error" : "secondary", className: "ml-3.5 mt-0.5", children: t }) : null;
11144
11130
  }
11145
11131
  function zi({
11146
11132
  name: e,
@@ -11182,7 +11168,7 @@ function ze({
11182
11168
  return null;
11183
11169
  if (t && e)
11184
11170
  return /* @__PURE__ */ n(
11185
- Y,
11171
+ U,
11186
11172
  {
11187
11173
  variant: "caption",
11188
11174
  className: "ml-3.5 text-red-500 dark:text-red-500",
@@ -11192,7 +11178,7 @@ function ze({
11192
11178
  const s = typeof r.disabled == "object" ? r.disabled.disabledMessage : void 0;
11193
11179
  return /* @__PURE__ */ v("div", { className: "flex ml-3.5 mt-1", children: [
11194
11180
  /* @__PURE__ */ n(
11195
- Y,
11181
+ U,
11196
11182
  {
11197
11183
  variant: "caption",
11198
11184
  color: a ? "disabled" : "secondary",
@@ -11486,7 +11472,7 @@ function fd({
11486
11472
  className: "flex-grow text-text-secondary dark:text-text-secondary-dark"
11487
11473
  }
11488
11474
  ),
11489
- Array.isArray(t) && /* @__PURE__ */ v(Y, { variant: "caption", className: "px-4", children: [
11475
+ Array.isArray(t) && /* @__PURE__ */ v(U, { variant: "caption", className: "px-4", children: [
11490
11476
  "(",
11491
11477
  t.length,
11492
11478
  ")"
@@ -11819,7 +11805,7 @@ function vd({
11819
11805
  {
11820
11806
  className: "flex-grow min-h-[38px] box-border m-2 text-center",
11821
11807
  children: /* @__PURE__ */ n(
11822
- Y,
11808
+ U,
11823
11809
  {
11824
11810
  align: "center",
11825
11811
  variant: "label",
@@ -12379,7 +12365,7 @@ function Sd({
12379
12365
  customProps: f,
12380
12366
  context: d
12381
12367
  } }),
12382
- a && !k && /* @__PURE__ */ n(Y, { variant: "caption", className: "ml-3.5", children: "This value has been updated elsewhere" })
12368
+ a && !k && /* @__PURE__ */ n(U, { variant: "caption", className: "ml-3.5", children: "This value has been updated elsewhere" })
12383
12369
  ] });
12384
12370
  }
12385
12371
  const mi = (e, t) => {
@@ -12780,7 +12766,7 @@ function Pd({
12780
12766
  )
12781
12767
  }
12782
12768
  ) : /* @__PURE__ */ n(
12783
- Y,
12769
+ U,
12784
12770
  {
12785
12771
  variant: "caption",
12786
12772
  children: `Data type ${g} not supported yet`
@@ -12792,7 +12778,7 @@ function Pd({
12792
12778
  }
12793
12779
  return /* @__PURE__ */ v(O, { children: [
12794
12780
  /* @__PURE__ */ v(
12795
- Y,
12781
+ U,
12796
12782
  {
12797
12783
  component: "div",
12798
12784
  className: "font-mono flex flex-row gap-1",
@@ -12929,7 +12915,7 @@ function Qd({
12929
12915
  i(m);
12930
12916
  }
12931
12917
  }
12932
- ) : p === "array" ? /* @__PURE__ */ n(Y, { variant: "caption", children: "Arrays of arrays are not supported." }) : p === "map" ? /* @__PURE__ */ n("div", { className: L(Se, "ml-2 pl-2 border-l border-solid"), children: /* @__PURE__ */ n(
12918
+ ) : p === "array" ? /* @__PURE__ */ n(U, { variant: "caption", children: "Arrays of arrays are not supported." }) : p === "map" ? /* @__PURE__ */ n("div", { className: L(Se, "ml-2 pl-2 border-l border-solid"), children: /* @__PURE__ */ n(
12933
12919
  Mi,
12934
12920
  {
12935
12921
  value: d,
@@ -12938,7 +12924,7 @@ function Qd({
12938
12924
  }
12939
12925
  }
12940
12926
  ) }) : /* @__PURE__ */ n(
12941
- Y,
12927
+ U,
12942
12928
  {
12943
12929
  variant: "caption",
12944
12930
  children: `Data type ${p} not supported yet`
@@ -12947,7 +12933,7 @@ function Qd({
12947
12933
  }
12948
12934
  return /* @__PURE__ */ v(O, { children: [
12949
12935
  /* @__PURE__ */ v(
12950
- Y,
12936
+ U,
12951
12937
  {
12952
12938
  component: "div",
12953
12939
  className: "font-mono flex min-h-12 flex-row gap-1 items-center",
@@ -13098,7 +13084,7 @@ function Dd({
13098
13084
  className: "flex-grow text-text-secondary dark:text-text-secondary-dark"
13099
13085
  }
13100
13086
  ),
13101
- Array.isArray(t) && /* @__PURE__ */ v(Y, { variant: "caption", className: "px-4", children: [
13087
+ Array.isArray(t) && /* @__PURE__ */ v(U, { variant: "caption", className: "px-4", children: [
13102
13088
  "(",
13103
13089
  t.length,
13104
13090
  ")"
@@ -13254,7 +13240,7 @@ function Td({
13254
13240
  {
13255
13241
  className: "mb-2",
13256
13242
  placeholder: /* @__PURE__ */ n(
13257
- Y,
13243
+ U,
13258
13244
  {
13259
13245
  variant: "caption",
13260
13246
  className: "px-4 py-2 font-medium",
@@ -13334,7 +13320,7 @@ function zd({
13334
13320
  g.internalValue !== h.current && r(g.internalValue);
13335
13321
  }, [g]), /* @__PURE__ */ v(O, { children: [
13336
13322
  !d && /* @__PURE__ */ n(
13337
- Y,
13323
+ U,
13338
13324
  {
13339
13325
  variant: "caption",
13340
13326
  className: "flex-grow",
@@ -14001,7 +13987,7 @@ function Vd({
14001
13987
  className: "flex-grow text-text-secondary dark:text-text-secondary-dark"
14002
13988
  }
14003
13989
  ),
14004
- Array.isArray(t) && /* @__PURE__ */ v(Y, { variant: "caption", className: "px-4", children: [
13990
+ Array.isArray(t) && /* @__PURE__ */ v(U, { variant: "caption", className: "px-4", children: [
14005
13991
  "(",
14006
13992
  t.length,
14007
13993
  ")"
@@ -14713,7 +14699,7 @@ function Ld({
14713
14699
  }
14714
14700
  ),
14715
14701
  l.id && /* @__PURE__ */ n(
14716
- Y,
14702
+ U,
14717
14703
  {
14718
14704
  variant: "caption",
14719
14705
  className: "ml-3.5 text-red-500 dark:text-red-500",
@@ -14753,7 +14739,7 @@ function Wd({ propertyId: e }) {
14753
14739
  return /* @__PURE__ */ v("div", { className: "flex flex-row gap-2 items-center justify-center text-white", children: [
14754
14740
  /* @__PURE__ */ v("div", { children: [
14755
14741
  /* @__PURE__ */ n(
14756
- Y,
14742
+ U,
14757
14743
  {
14758
14744
  variant: "caption",
14759
14745
  className: "min-w-20 text-slate-400",
@@ -14761,7 +14747,7 @@ function Wd({ propertyId: e }) {
14761
14747
  children: t ? "Copied" : "Property ID"
14762
14748
  }
14763
14749
  ),
14764
- /* @__PURE__ */ n(Y, { variant: "caption", className: "text-white", children: /* @__PURE__ */ n("code", { children: e }) })
14750
+ /* @__PURE__ */ n(U, { variant: "caption", className: "text-white", children: /* @__PURE__ */ n("code", { children: e }) })
14765
14751
  ] }),
14766
14752
  /* @__PURE__ */ n(de, { size: "small", children: /* @__PURE__ */ n(
14767
14753
  vr,
@@ -14830,11 +14816,11 @@ function Hd({
14830
14816
  path: e,
14831
14817
  values: d?.values,
14832
14818
  fields: _.propertyConfigs
14833
- }), [d?.values, e, _.propertyConfigs]), D = i ? "copy" : t ? "existing" : "new", [F, M] = Q(D), $ = (F === "new" || F === "copy") && !!P.customId && P.customId !== "optional", oe = he(() => F === "new" || F === "copy" ? $ ? void 0 : w.generateEntityId(e) : t, [t, F]), [U, X] = S.useState(oe), [q, V] = S.useState(!1), [ae, te] = S.useState(), [Ae, ue] = S.useState(!1), se = r ?? uo(
14819
+ }), [d?.values, e, _.propertyConfigs]), D = i ? "copy" : t ? "existing" : "new", [F, M] = Q(D), $ = (F === "new" || F === "copy") && !!P.customId && P.customId !== "optional", oe = he(() => F === "new" || F === "copy" ? $ ? void 0 : w.generateEntityId(e) : t, [t, F]), [Y, X] = S.useState(oe), [q, V] = S.useState(!1), [ae, te] = S.useState(), [Ae, ue] = S.useState(!1), se = r ?? uo(
14834
14820
  a ? a.defaultSelectedView : void 0,
14835
14821
  {
14836
14822
  status: F,
14837
- entityId: U
14823
+ entityId: Y
14838
14824
  }
14839
14825
  ), ee = ce(se ?? Yt), T = ce(Zd(P, F, d)), ne = ee.current === Yt, K = (a.subcollections ?? []).filter((N) => !N.hideFromNavigation), H = K?.length ?? 0, j = a.entityViews, G = j?.length ?? 0, I = a.formAutoSave && !a.customId, R = G > 0 || H > 0, [me, Ie] = Q(d), [Xe, ie] = Q(void 0);
14840
14826
  z(() => {
@@ -14872,8 +14858,8 @@ function Hd({
14872
14858
  u(!1), k.open({
14873
14859
  type: "error",
14874
14860
  message: "Error saving: " + N?.message
14875
- }), console.error("Error saving entity", e, U), console.error(N);
14876
- }, [U, e, k]), We = ({
14861
+ }), console.error("Error saving entity", e, Y), console.error(N);
14862
+ }, [Y, e, k]), We = ({
14877
14863
  values: N,
14878
14864
  previousValues: Z,
14879
14865
  closeAfterSave: ve,
@@ -14915,14 +14901,14 @@ function Hd({
14915
14901
  closeAfterSave: Gt
14916
14902
  });
14917
14903
  }, rt = (N, Z) => {
14918
- if ($ && !U) {
14904
+ if ($ && !Y) {
14919
14905
  console.error("Missing custom Id"), V(!0), Z.setSubmitting(!1);
14920
14906
  return;
14921
14907
  }
14922
14908
  if (te(void 0), V(!1), F === "existing") {
14923
14909
  if (!d?.id) throw Error("Form misconfiguration when saving, no id for existing entity");
14924
14910
  } else if (F === "new" || F === "copy") {
14925
- if (g.customId && g.customId !== "optional" && !U)
14911
+ if (g.customId && g.customId !== "optional" && !Y)
14926
14912
  throw Error("Form misconfiguration when saving, entityId should be set");
14927
14913
  } else
14928
14914
  throw Error("New FormType added, check EntityForm");
@@ -14947,14 +14933,14 @@ function Hd({
14947
14933
  }), Be = Ue({
14948
14934
  collection: g,
14949
14935
  path: e,
14950
- entityId: U,
14936
+ entityId: Y,
14951
14937
  values: re.values,
14952
14938
  previousValues: re.initialValues,
14953
14939
  fields: _.propertyConfigs
14954
14940
  }), ir = ce(d?.values), Ot = (N) => (ir.current = N, Ke({
14955
14941
  collection: Be,
14956
14942
  path: e,
14957
- entityId: U,
14943
+ entityId: Y,
14958
14944
  values: N,
14959
14945
  previousValues: d?.values,
14960
14946
  closeAfterSave: C.current,
@@ -14971,7 +14957,7 @@ function Hd({
14971
14957
  setFieldValue: x(re.setFieldValue, []),
14972
14958
  values: re.values,
14973
14959
  collection: Be,
14974
- entityId: U,
14960
+ entityId: Y,
14975
14961
  path: e,
14976
14962
  save: Ot,
14977
14963
  formex: re
@@ -15023,7 +15009,7 @@ function Hd({
15023
15009
  "div",
15024
15010
  {
15025
15011
  className: "flex items-center justify-center w-full h-full p-3",
15026
- children: /* @__PURE__ */ n(Y, { variant: "label", children: "You need to save your entity before adding additional collections" })
15012
+ children: /* @__PURE__ */ n(U, { variant: "label", children: "You need to save your entity before adding additional collections" })
15027
15013
  }
15028
15014
  ))
15029
15015
  ]
@@ -15036,7 +15022,7 @@ function Hd({
15036
15022
  }, []), be = (N) => {
15037
15023
  ee.current = N, y.replace({
15038
15024
  path: e,
15039
- entityId: U,
15025
+ entityId: Y,
15040
15026
  selectedSubPath: N === Yt ? void 0 : N,
15041
15027
  updateUrl: !0,
15042
15028
  collection: a
@@ -15054,12 +15040,12 @@ function Hd({
15054
15040
  }, []), Je = [], st = _.plugins;
15055
15041
  if (st && g) {
15056
15042
  const N = {
15057
- entityId: U,
15043
+ entityId: Y,
15058
15044
  path: e,
15059
15045
  status: F,
15060
15046
  collection: g,
15061
15047
  context: E,
15062
- currentEntityId: U,
15048
+ currentEntityId: Y,
15063
15049
  formContext: at
15064
15050
  };
15065
15051
  Je.push(...st.map((Z, ve) => Z.form?.Actions ? /* @__PURE__ */ n(
@@ -15077,7 +15063,7 @@ function Hd({
15077
15063
  const N = await Ui({
15078
15064
  collection: Be,
15079
15065
  path: e,
15080
- entityId: U,
15066
+ entityId: Y,
15081
15067
  values: re.values,
15082
15068
  context: E
15083
15069
  });
@@ -15087,7 +15073,7 @@ function Hd({
15087
15073
  }
15088
15074
  ue(!1);
15089
15075
  }
15090
- }, [U, re.values, F]);
15076
+ }, [Y, re.values, F]);
15091
15077
  z(() => {
15092
15078
  Li();
15093
15079
  }, [Li]);
@@ -15096,15 +15082,15 @@ function Hd({
15096
15082
  name: N,
15097
15083
  value: Z,
15098
15084
  property: ve
15099
- }) => w.checkUniqueField(e, N, Z, U),
15100
- [w, e, U]
15085
+ }) => w.checkUniqueField(e, N, Z, Y),
15086
+ [w, e, Y]
15101
15087
  ), ba = he(
15102
- () => U ? Uo(
15103
- U,
15088
+ () => Y ? Uo(
15089
+ Y,
15104
15090
  Be.properties,
15105
15091
  $i
15106
15092
  ) : void 0,
15107
- [U, Be.properties, $i]
15093
+ [Y, Be.properties, $i]
15108
15094
  ), ya = x(({
15109
15095
  entity: N,
15110
15096
  customEntityActions: Z
@@ -15160,7 +15146,7 @@ function Hd({
15160
15146
  entity: d,
15161
15147
  customEntityActions: g.entityActions
15162
15148
  }).filter((N) => N.includeInForm === void 0 || N.includeInForm), va = /* @__PURE__ */ v(Nt, { position: "absolute", children: [
15163
- ae && /* @__PURE__ */ n("div", { className: "text-right", children: /* @__PURE__ */ n(Y, { color: "error", children: ae.message }) }),
15149
+ ae && /* @__PURE__ */ n("div", { className: "text-right", children: /* @__PURE__ */ n(U, { color: "error", children: ae.message }) }),
15164
15150
  d && Wi.length > 0 && /* @__PURE__ */ n("div", { className: "flex-grow flex overflow-auto no-scrollbar", children: Wi.map((N) => /* @__PURE__ */ n(
15165
15151
  de,
15166
15152
  {
@@ -15239,7 +15225,7 @@ function Hd({
15239
15225
  className: `w-full py-2 flex flex-col items-start mt-${4 + (Je ? 8 : 0)} lg:mt-${8 + (Je ? 8 : 0)} mb-8`,
15240
15226
  children: [
15241
15227
  /* @__PURE__ */ n(
15242
- Y,
15228
+ U,
15243
15229
  {
15244
15230
  className: "mt-4 flex-grow line-clamp-1 " + g.hideIdFromForm ? "mb-2" : "mb-0",
15245
15231
  variant: "h4",
@@ -15249,7 +15235,7 @@ function Hd({
15249
15235
  /* @__PURE__ */ n(ws, { color: "base", className: "w-full", size: "small", children: /* @__PURE__ */ v("code", { className: "text-xs select-all", children: [
15250
15236
  e,
15251
15237
  "/",
15252
- U
15238
+ Y
15253
15239
  ] }) })
15254
15240
  ]
15255
15241
  }
@@ -15258,7 +15244,7 @@ function Hd({
15258
15244
  Ld,
15259
15245
  {
15260
15246
  customId: g.customId,
15261
- entityId: U,
15247
+ entityId: Y,
15262
15248
  status: F,
15263
15249
  onChange: X,
15264
15250
  error: q,
@@ -15266,7 +15252,7 @@ function Hd({
15266
15252
  entity: d
15267
15253
  }
15268
15254
  ),
15269
- U && at && /* @__PURE__ */ v(O, { children: [
15255
+ Y && at && /* @__PURE__ */ v(O, { children: [
15270
15256
  /* @__PURE__ */ v(
15271
15257
  "div",
15272
15258
  {
@@ -15301,7 +15287,7 @@ function Hd({
15301
15287
  }
15302
15288
  const _a = Xe === void 0 ? /* @__PURE__ */ n(O, {}) : Xe ? /* @__PURE__ */ v(O, { children: [
15303
15289
  /* @__PURE__ */ n(
15304
- Y,
15290
+ U,
15305
15291
  {
15306
15292
  className: "mt-16 mb-8 mx-8",
15307
15293
  variant: "h4",
@@ -15339,8 +15325,8 @@ function Hd({
15339
15325
  )
15340
15326
  );
15341
15327
  return z(() => {
15342
- U && we && we(U);
15343
- }, [U, we]), /* @__PURE__ */ n(Nn, { value: re, children: /* @__PURE__ */ v("div", { className: "flex flex-col h-full w-full transition-width duration-250 ease-in-out", children: [
15328
+ Y && we && we(Y);
15329
+ }, [Y, we]), /* @__PURE__ */ n(Nn, { value: re, children: /* @__PURE__ */ v("div", { className: "flex flex-col h-full w-full transition-width duration-250 ease-in-out", children: [
15344
15330
  /* @__PURE__ */ v(
15345
15331
  "div",
15346
15332
  {
@@ -15491,9 +15477,9 @@ function eu({
15491
15477
  onOpenChange: (o) => o ? r() : t(),
15492
15478
  children: [
15493
15479
  /* @__PURE__ */ v(xi, { children: [
15494
- /* @__PURE__ */ n(Y, { variant: "h6", children: a }),
15480
+ /* @__PURE__ */ n(U, { variant: "h6", children: a }),
15495
15481
  i,
15496
- /* @__PURE__ */ n(Y, { children: "Are you sure you want to leave this page?" })
15482
+ /* @__PURE__ */ n(U, { children: "Are you sure you want to leave this page?" })
15497
15483
  ] }),
15498
15484
  /* @__PURE__ */ v(Nt, { children: [
15499
15485
  /* @__PURE__ */ n(ge, { variant: "text", onClick: r, autoFocus: !0, children: " Cancel " }),
@@ -16104,8 +16090,8 @@ function Tm(e) {
16104
16090
  error: s.authError
16105
16091
  }
16106
16092
  ) }) : E?.blocked ? /* @__PURE__ */ v(sr, { maxWidth: "md", fullScreen: !0, children: [
16107
- /* @__PURE__ */ n(Y, { variant: "h4", children: "Access blocked" }),
16108
- /* @__PURE__ */ v(Y, { children: [
16093
+ /* @__PURE__ */ n(U, { variant: "h4", children: "Access blocked" }),
16094
+ /* @__PURE__ */ v(U, { children: [
16109
16095
  "This app has been blocked. Please reach out at ",
16110
16096
  /* @__PURE__ */ n(
16111
16097
  "a",
@@ -16116,7 +16102,7 @@ function Tm(e) {
16116
16102
  ),
16117
16103
  " for more information."
16118
16104
  ] }),
16119
- E?.message && /* @__PURE__ */ v(Y, { children: [
16105
+ E?.message && /* @__PURE__ */ v(U, { children: [
16120
16106
  "Response from the server: ",
16121
16107
  E?.message
16122
16108
  ] })
@@ -16430,7 +16416,7 @@ function Au({
16430
16416
  {
16431
16417
  className: "pt-8 pl-6 pr-8 pb-2 flex flex-row items-center",
16432
16418
  children: /* @__PURE__ */ n(
16433
- Y,
16419
+ U,
16434
16420
  {
16435
16421
  variant: "caption",
16436
16422
  color: "secondary",