@oliasoft-open-source/react-ui-library 10.0.3-beta-1 → 10.1.0

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.js CHANGED
@@ -8387,19 +8387,74 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8387
8387
  children: f(t)
8388
8388
  })]
8389
8389
  });
8390
- }, Rp = (e, t) => {
8390
+ }, Rp = { backgroundColor: "var(--color-background-error-muted)" }, zp = { backgroundColor: "var(--color-background-success-muted)" }, Bp = { backgroundColor: "var(--color-background-warning-muted)" }, Vp = {
8391
+ addedBackground: "var(--color-diff-added-background)",
8392
+ addedGutterBackground: "var(--color-diff-added-gutter-background)",
8393
+ codeFoldBackground: "var(--color-diff-code-fold-background)",
8394
+ codeFoldContentColor: "var(--color-diff-code-fold-content-color)",
8395
+ codeFoldGutterBackground: "var(--color-diff-code-fold-gutter-background)",
8396
+ diffViewerBackground: "var(--color-diff-viewer-background)",
8397
+ diffViewerColor: "var(--color-diff-viewer-color)",
8398
+ diffViewerTitleBackground: "var(--color-diff-title-background)",
8399
+ diffViewerTitleBorderColor: "var(--color-diff-title-border-color)",
8400
+ diffViewerTitleColor: "var(--color-diff-title-color)",
8401
+ emptyLineBackground: "var(--color-diff-empty-line-background)",
8402
+ gutterBackground: "var(--color-diff-gutter-background)",
8403
+ gutterBackgroundDark: "var(--color-diff-gutter-background-hover)",
8404
+ gutterColor: "var(--color-diff-gutter-color)",
8405
+ removedBackground: "var(--color-diff-removed-background)",
8406
+ removedGutterBackground: "var(--color-diff-removed-gutter-background)",
8407
+ wordAddedBackground: "var(--color-diff-word-added-background)",
8408
+ wordRemovedBackground: "var(--color-diff-word-removed-background)"
8409
+ }, Hp = {
8410
+ variables: {
8411
+ light: Vp,
8412
+ dark: Vp
8413
+ },
8414
+ diffContainer: { minWidth: "unset" },
8415
+ codeFoldGutter: {
8416
+ verticalAlign: "middle",
8417
+ svg: {
8418
+ display: "block",
8419
+ margin: "0 auto"
8420
+ }
8421
+ },
8422
+ gutter: { "&:hover": {
8423
+ cursor: "default",
8424
+ pre: { opacity: .5 }
8425
+ } },
8426
+ marker: { pre: { opacity: .4 } }
8427
+ }, Up = { codeOnly: "_codeOnly_1lph2_42" }, Wp = ({ value: e, compareValue: t, splitView: n = !1, showDiffOnly: r = !1, compareMethod: i = Ti.LINES, extraLinesSurroundingDiff: a, hideSummary: o = !0, className: s }) => {
8428
+ let c = t !== void 0, l = c ? t : e, u = i !== Ti.WORDS;
8429
+ return /* @__PURE__ */ S("div", {
8430
+ className: b(s, { [Up.codeOnly]: !c && !n }),
8431
+ children: /* @__PURE__ */ S(wi, {
8432
+ oldValue: l,
8433
+ newValue: e,
8434
+ splitView: n,
8435
+ showDiffOnly: r,
8436
+ compareMethod: i,
8437
+ extraLinesSurroundingDiff: a,
8438
+ disableWordDiff: u,
8439
+ hideLineNumbers: !1,
8440
+ hideSummary: o,
8441
+ disableWorker: !0,
8442
+ styles: Hp
8443
+ })
8444
+ });
8445
+ }, Gp = (e, t) => {
8391
8446
  let n = e.replace(/\r\n/g, "\n").split("\n"), r = t.replace(/\r\n/g, "\n").split("\n"), i = r.length - n.length, a = n.length - r.length;
8392
8447
  return {
8393
8448
  added: Math.max(0, i),
8394
8449
  removed: Math.max(0, a)
8395
8450
  };
8396
- }, zp = "split", Bp = "unified", Vp = ({ oldJson: e, newJson: t, viewType: n = zp }) => {
8451
+ }, Kp = "split", qp = "unified", Jp = ({ oldJson: e, newJson: t, viewType: n = Kp }) => {
8397
8452
  var r, i;
8398
8453
  let { translations: a } = Ap(), [o, s] = v(n), c = [{
8399
- value: zp,
8454
+ value: Kp,
8400
8455
  label: (r = a == null ? void 0 : a.split) == null ? "Split" : r
8401
8456
  }, {
8402
- value: Bp,
8457
+ value: qp,
8403
8458
  label: (i = a == null ? void 0 : a.unified) == null ? "Unified" : i
8404
8459
  }];
8405
8460
  d(() => {
@@ -8407,7 +8462,7 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8407
8462
  }, [n]);
8408
8463
  let l = ({ target: { value: e } }) => {
8409
8464
  s(e);
8410
- }, { added: u, removed: f } = Rp(e, t), p = u + f > 3500;
8465
+ }, { added: u, removed: f } = Gp(e, t), p = u + f > 3500;
8411
8466
  return /* @__PURE__ */ S(x, { children: /* @__PURE__ */ S(bo, {
8412
8467
  bordered: !0,
8413
8468
  heading: /* @__PURE__ */ C(bd, {
@@ -8432,24 +8487,26 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8432
8487
  }),
8433
8488
  padding: !1,
8434
8489
  children: p ? /* @__PURE__ */ S("div", {
8435
- style: { padding: "5px" },
8490
+ style: { padding: "var(--padding-sm)" },
8436
8491
  children: /* @__PURE__ */ S(Yo, {
8437
8492
  muted: !0,
8438
8493
  children: a == null ? void 0 : a.changesTooLarge
8439
8494
  })
8440
- }) : /* @__PURE__ */ S(wi, {
8441
- oldValue: e,
8442
- newValue: t,
8443
- splitView: o === zp,
8444
- compareMethod: Ti.WORDS
8495
+ }) : /* @__PURE__ */ S(Wp, {
8496
+ value: t,
8497
+ compareValue: e,
8498
+ splitView: o === Kp,
8499
+ compareMethod: Ti.WORDS,
8500
+ showDiffOnly: !0,
8501
+ hideSummary: !1
8445
8502
  })
8446
8503
  }) });
8447
- }, Hp = { backgroundColor: "var(--color-background-error-muted)" }, Up = { backgroundColor: "var(--color-background-success-muted)" }, Wp = { backgroundColor: "var(--color-background-warning-muted)" }, Gp = (e) => typeof e == "object" && e && "value" in e ? e.value : e, Kp = (e) => {
8504
+ }, Yp = (e) => typeof e == "object" && e && "value" in e ? e.value : e, Xp = (e) => {
8448
8505
  var t;
8449
8506
  if (e.id != null) return String(e.id);
8450
- let n = Gp((t = e.cells) == null || (t = t[0]) == null ? void 0 : t.value);
8507
+ let n = Yp((t = e.cells) == null || (t = t[0]) == null ? void 0 : t.value);
8451
8508
  return n == null ? "" : String(n);
8452
- }, qp = (e, t) => ({
8509
+ }, Zp = (e, t) => ({
8453
8510
  ...e,
8454
8511
  cells: e.cells.map((e) => ({
8455
8512
  ...e,
@@ -8458,7 +8515,7 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8458
8515
  ...t
8459
8516
  }
8460
8517
  }))
8461
- }), Jp = (e, t) => ({
8518
+ }), Qp = (e, t) => ({
8462
8519
  ...e,
8463
8520
  cells: e.cells.map((e, n) => {
8464
8521
  var r;
@@ -8467,17 +8524,17 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8467
8524
  ...e,
8468
8525
  style: {
8469
8526
  ...e.style,
8470
- ...Wp
8527
+ ...Bp
8471
8528
  },
8472
8529
  tooltip: typeof a == "number" ? String(a) : a
8473
8530
  };
8474
8531
  })
8475
- }), Yp = (e = [], t = []) => {
8532
+ }), $p = (e = [], t = []) => {
8476
8533
  let n = /* @__PURE__ */ new Map();
8477
- for (let e of t) n.set(Kp(e), e);
8478
- let r = new Set(e.map(Kp)), i = /* @__PURE__ */ new Map(), a = [], o = null;
8534
+ for (let e of t) n.set(Xp(e), e);
8535
+ let r = new Set(e.map(Xp)), i = /* @__PURE__ */ new Map(), a = [], o = null;
8479
8536
  for (let e = t.length - 1; e >= 0; e--) {
8480
- let n = t[e], c = Kp(n);
8537
+ let n = t[e], c = Xp(n);
8481
8538
  if (r.has(c)) {
8482
8539
  o = c;
8483
8540
  continue;
@@ -8492,7 +8549,7 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8492
8549
  a.reverse();
8493
8550
  let c = [];
8494
8551
  for (let t of e) {
8495
- let e = Kp(t), r = i.get(e);
8552
+ let e = Xp(t), r = i.get(e);
8496
8553
  if (r) for (let e of r) c.push({
8497
8554
  status: "deleted",
8498
8555
  row: e
@@ -8512,11 +8569,11 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8512
8569
  row: e
8513
8570
  });
8514
8571
  return c;
8515
- }, Xp = (e) => e.status === "deleted" ? qp(e.row, Hp) : e.status === "added" ? qp(e.row, Up) : Jp(e.row, e.compareRow), Zp = ({ table: e, compareRows: t, beforeRenderRow: n, ...r }) => {
8516
- let i = h(() => Yp(e.rows, t), [e.rows, t]), a = !!e.infiniteScroll, o = h(() => {
8572
+ }, em = (e) => e.status === "deleted" ? Zp(e.row, Rp) : e.status === "added" ? Zp(e.row, zp) : Qp(e.row, e.compareRow), tm = ({ table: e, compareRows: t, beforeRenderRow: n, ...r }) => {
8573
+ let i = h(() => $p(e.rows, t), [e.rows, t]), a = !!e.infiniteScroll, o = h(() => {
8517
8574
  if (!a) return i.map((e) => e.row);
8518
8575
  }, [a, i]), s = l(({ row: e, rowIndex: t }) => {
8519
- let r = i[t], a = r ? Xp(r) : e;
8576
+ let r = i[t], a = r ? em(r) : e;
8520
8577
  return n ? n({
8521
8578
  row: a,
8522
8579
  rowIndex: t
@@ -8535,7 +8592,7 @@ var ko = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Ao =
8535
8592
  };
8536
8593
  //#endregion
8537
8594
  //#region src/helpers/date.ts
8538
- function Qp({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i, locale: a }) {
8595
+ function nm({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i, locale: a }) {
8539
8596
  return e ? new Date(e).toLocaleString(a, {
8540
8597
  year: "numeric",
8541
8598
  month: "short",
@@ -8549,28 +8606,28 @@ function Qp({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i
8549
8606
  }
8550
8607
  //#endregion
8551
8608
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/clone.js
8552
- function $p(e) {
8609
+ function rm(e) {
8553
8610
  var t;
8554
8611
  let n = /^\/(.*)\/([gimyu]*)$/.exec(e.toString());
8555
8612
  if (!n) throw Error("Invalid RegExp");
8556
8613
  return new RegExp((t = n[1]) == null ? "" : t, n[2]);
8557
8614
  }
8558
- function em(e) {
8615
+ function im(e) {
8559
8616
  if (typeof e != "object") return e;
8560
8617
  if (e === null) return null;
8561
- if (Array.isArray(e)) return e.map(em);
8618
+ if (Array.isArray(e)) return e.map(im);
8562
8619
  if (e instanceof Date) return new Date(e.getTime());
8563
- if (e instanceof RegExp) return $p(e);
8620
+ if (e instanceof RegExp) return rm(e);
8564
8621
  let t = {};
8565
- for (let n in e) Object.prototype.hasOwnProperty.call(e, n) && (t[n] = em(e[n]));
8622
+ for (let n in e) Object.prototype.hasOwnProperty.call(e, n) && (t[n] = im(e[n]));
8566
8623
  return t;
8567
8624
  }
8568
8625
  //#endregion
8569
8626
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/assertions/arrays.js
8570
- function tm(e, t) {
8627
+ function am(e, t) {
8571
8628
  if (e.length === 0) throw Error(t || "Expected a non-empty array");
8572
8629
  }
8573
- var nm = (e) => e[e.length - 1], rm = class {
8630
+ var om = (e) => e[e.length - 1], sm = class {
8574
8631
  setResult(e) {
8575
8632
  return this.result = e, this.hasResult = !0, this;
8576
8633
  }
@@ -8578,16 +8635,16 @@ var nm = (e) => e[e.length - 1], rm = class {
8578
8635
  return this.exiting = !0, this;
8579
8636
  }
8580
8637
  push(e, t) {
8581
- return e.parent = this, t !== void 0 && (e.childName = t), e.root = this.root || this, e.options = e.options || this.options, this.children ? (tm(this.children), nm(this.children).next = e, this.children.push(e)) : (this.children = [e], this.nextAfterChildren = this.next || null, this.next = e), e.next = this, this;
8638
+ return e.parent = this, t !== void 0 && (e.childName = t), e.root = this.root || this, e.options = e.options || this.options, this.children ? (am(this.children), om(this.children).next = e, this.children.push(e)) : (this.children = [e], this.nextAfterChildren = this.next || null, this.next = e), e.next = this, this;
8582
8639
  }
8583
- }, im = class extends rm {
8640
+ }, cm = class extends sm {
8584
8641
  constructor(e, t) {
8585
8642
  super(), this.left = e, this.right = t, this.pipe = "diff";
8586
8643
  }
8587
8644
  prepareDeltaResult(e) {
8588
8645
  var t, n, r, i;
8589
8646
  if (typeof e == "object" && ((t = this.options) != null && t.omitRemovedValues && Array.isArray(e) && e.length > 1 && (e.length === 2 || e[2] === 0 || e[2] === 3) && (e[0] = 0), (n = this.options) != null && n.cloneDiffValues)) {
8590
- let t = typeof ((r = this.options) == null ? void 0 : r.cloneDiffValues) == "function" ? (i = this.options) == null ? void 0 : i.cloneDiffValues : em;
8647
+ let t = typeof ((r = this.options) == null ? void 0 : r.cloneDiffValues) == "function" ? (i = this.options) == null ? void 0 : i.cloneDiffValues : im;
8591
8648
  typeof e[0] == "object" && (e[0] = t(e[0])), typeof e[1] == "object" && (e[1] = t(e[1]));
8592
8649
  }
8593
8650
  return e;
@@ -8595,15 +8652,15 @@ var nm = (e) => e[e.length - 1], rm = class {
8595
8652
  setResult(e) {
8596
8653
  return this.prepareDeltaResult(e), super.setResult(e);
8597
8654
  }
8598
- }, am = class extends rm {
8655
+ }, lm = class extends sm {
8599
8656
  constructor(e, t) {
8600
8657
  super(), this.left = e, this.delta = t, this.pipe = "patch";
8601
8658
  }
8602
- }, om = class extends rm {
8659
+ }, um = class extends sm {
8603
8660
  constructor(e) {
8604
8661
  super(), this.delta = e, this.pipe = "reverse";
8605
8662
  }
8606
- }, sm = class {
8663
+ }, dm = class {
8607
8664
  constructor(e) {
8608
8665
  this.name = e, this.filters = [];
8609
8666
  }
@@ -8667,7 +8724,7 @@ var nm = (e) => e[e.length - 1], rm = class {
8667
8724
  }
8668
8725
  }), this);
8669
8726
  }
8670
- }, cm = class {
8727
+ }, fm = class {
8671
8728
  constructor(e) {
8672
8729
  this.selfOptions = e || {}, this.pipes = {};
8673
8730
  }
@@ -8694,7 +8751,7 @@ var nm = (e) => e[e.length - 1], rm = class {
8694
8751
  for (; r;) n.nextAfterChildren !== void 0 && (n.next = n.nextAfterChildren, n.nextAfterChildren = null), typeof r == "string" && (r = this.pipe(r)), r.process(n), i = r, r = null, n && n.next && (n = n.next, r = n.pipe || i);
8695
8752
  return n.hasResult ? n.result : void 0;
8696
8753
  }
8697
- }, lm = (e, t, n, r) => e[n] === t[r], um = (e, t, n, r) => {
8754
+ }, pm = (e, t, n, r) => e[n] === t[r], mm = (e, t, n, r) => {
8698
8755
  var i, a, o;
8699
8756
  let s = e.length, c = t.length, l, u, d = Array(s + 1);
8700
8757
  for (l = 0; l < s + 1; l++) {
@@ -8710,7 +8767,7 @@ var nm = (e) => e[e.length - 1], rm = class {
8710
8767
  for (u = 1; u < c + 1; u++) n(e, t, l - 1, u - 1, r) ? s[u] = ((i = f[u - 1]) == null ? 0 : i) + 1 : s[u] = Math.max((a = f[u]) == null ? 0 : a, (o = s[u - 1]) == null ? 0 : o);
8711
8768
  }
8712
8769
  return d;
8713
- }, dm = (e, t, n, r) => {
8770
+ }, hm = (e, t, n, r) => {
8714
8771
  let i = t.length, a = n.length, o = {
8715
8772
  sequence: [],
8716
8773
  indices1: [],
@@ -8732,11 +8789,11 @@ var nm = (e) => e[e.length - 1], rm = class {
8732
8789
  }
8733
8790
  }
8734
8791
  return o;
8735
- }, fm = { get: (e, t, n, r) => {
8792
+ }, gm = { get: (e, t, n, r) => {
8736
8793
  let i = r || {};
8737
- return dm(um(e, t, n || lm, i), e, t, i);
8738
- } }, pm = 3;
8739
- function mm(e, t, n, r) {
8794
+ return hm(mm(e, t, n || pm, i), e, t, i);
8795
+ } }, _m = 3;
8796
+ function vm(e, t, n, r) {
8740
8797
  for (let i = 0; i < n; i++) {
8741
8798
  let n = e[i];
8742
8799
  for (let e = 0; e < r; e++) {
@@ -8746,7 +8803,7 @@ function mm(e, t, n, r) {
8746
8803
  }
8747
8804
  return !1;
8748
8805
  }
8749
- function hm(e, t, n, r, i) {
8806
+ function ym(e, t, n, r, i) {
8750
8807
  let a = e[n], o = t[r];
8751
8808
  if (a === o) return !0;
8752
8809
  if (typeof a != "object" || typeof o != "object") return !1;
@@ -8759,15 +8816,15 @@ function hm(e, t, n, r, i) {
8759
8816
  let l = i.hashCache2[r];
8760
8817
  return l === void 0 && (i.hashCache2[r] = l = s(o, r)), l !== void 0 && c === l;
8761
8818
  }
8762
- var gm = function(e) {
8819
+ var bm = function(e) {
8763
8820
  var t, n, r, i, a;
8764
8821
  if (!e.leftIsArray) return;
8765
8822
  let o = {
8766
8823
  objectHash: (t = e.options) == null ? void 0 : t.objectHash,
8767
8824
  matchByPosition: (n = e.options) == null ? void 0 : n.matchByPosition
8768
8825
  }, s = 0, c = 0, l, u, d, f = e.left, p = e.right, m = f.length, h = p.length, g;
8769
- for (m > 0 && h > 0 && !o.objectHash && typeof o.matchByPosition != "boolean" && (o.matchByPosition = !mm(f, p, m, h)); s < m && s < h && hm(f, p, s, s, o);) l = s, g = new im(f[l], p[l]), e.push(g, l), s++;
8770
- for (; c + s < m && c + s < h && hm(f, p, m - 1 - c, h - 1 - c, o);) u = m - 1 - c, d = h - 1 - c, g = new im(f[u], p[d]), e.push(g, d), c++;
8826
+ for (m > 0 && h > 0 && !o.objectHash && typeof o.matchByPosition != "boolean" && (o.matchByPosition = !vm(f, p, m, h)); s < m && s < h && ym(f, p, s, s, o);) l = s, g = new cm(f[l], p[l]), e.push(g, l), s++;
8827
+ for (; c + s < m && c + s < h && ym(f, p, m - 1 - c, h - 1 - c, o);) u = m - 1 - c, d = h - 1 - c, g = new cm(f[u], p[d]), e.push(g, d), c++;
8771
8828
  let _;
8772
8829
  if (s + c === m) {
8773
8830
  if (m === h) {
@@ -8791,7 +8848,7 @@ var gm = function(e) {
8791
8848
  return;
8792
8849
  }
8793
8850
  o.hashCache1 = void 0, o.hashCache2 = void 0;
8794
- let v = f.slice(s, m - c), y = p.slice(s, h - c), b = fm.get(v, y, hm, o), x = [];
8851
+ let v = f.slice(s, m - c), y = p.slice(s, h - c), b = gm.get(v, y, ym, o), x = [];
8795
8852
  for (_ = _ || { _t: "a" }, l = s; l < m - c; l++) if (b.indices1.indexOf(l - s) < 0) {
8796
8853
  let t = `_${l}`;
8797
8854
  _[t] = [
@@ -8812,8 +8869,8 @@ var gm = function(e) {
8812
8869
  if (S && w > 0) for (let n = 0; n < w; n++) {
8813
8870
  u = x[n];
8814
8871
  let r = u === void 0 ? void 0 : _[`_${u}`];
8815
- if (u !== void 0 && r && hm(v, y, u - s, l - s, o)) {
8816
- r.splice(1, 2, l, pm), r.splice(1, 2, l, pm), C || (r[0] = ""), d = l, g = new im(f[u], p[d]), e.push(g, d), x.splice(n, 1), t = !0;
8872
+ if (u !== void 0 && r && ym(v, y, u - s, l - s, o)) {
8873
+ r.splice(1, 2, l, _m), r.splice(1, 2, l, _m), C || (r[0] = ""), d = l, g = new cm(f[u], p[d]), e.push(g, d), x.splice(n, 1), t = !0;
8817
8874
  break;
8818
8875
  }
8819
8876
  }
@@ -8821,20 +8878,20 @@ var gm = function(e) {
8821
8878
  } else {
8822
8879
  if (b.indices1[t] === void 0) throw Error(`Invalid indexOnArray2: ${t}, seq.indices1: ${b.indices1}`);
8823
8880
  if (u = b.indices1[t] + s, b.indices2[t] === void 0) throw Error(`Invalid indexOnArray2: ${t}, seq.indices2: ${b.indices2}`);
8824
- d = b.indices2[t] + s, g = new im(f[u], p[d]), e.push(g, d);
8881
+ d = b.indices2[t] + s, g = new cm(f[u], p[d]), e.push(g, d);
8825
8882
  }
8826
8883
  }
8827
8884
  e.setResult(_).exit();
8828
8885
  };
8829
- gm.filterName = "arrays";
8830
- var _m = {
8886
+ bm.filterName = "arrays";
8887
+ var xm = {
8831
8888
  numerically(e, t) {
8832
8889
  return e - t;
8833
8890
  },
8834
8891
  numericallyBy(e) {
8835
8892
  return (t, n) => t[e] - n[e];
8836
8893
  }
8837
- }, vm = function(e) {
8894
+ }, Sm = function(e) {
8838
8895
  var t;
8839
8896
  if (!e.nested) return;
8840
8897
  let n = e.delta;
@@ -8843,7 +8900,7 @@ var _m = {
8843
8900
  for (r in a) if (r !== "_t") {
8844
8901
  if (r[0] === "_") {
8845
8902
  let e = r;
8846
- if (a[e] !== void 0 && (a[e][2] === 0 || a[e][2] === pm)) s.push(Number.parseInt(r.slice(1), 10));
8903
+ if (a[e] !== void 0 && (a[e][2] === 0 || a[e][2] === _m)) s.push(Number.parseInt(r.slice(1), 10));
8847
8904
  else throw Error(`only removal or move can be applied at original array indices, invalid diff type: ${(t = a[e]) == null ? void 0 : t[2]}`);
8848
8905
  } else {
8849
8906
  let e = r;
@@ -8856,15 +8913,15 @@ var _m = {
8856
8913
  });
8857
8914
  }
8858
8915
  }
8859
- for (s = s.sort(_m.numerically), r = s.length - 1; r >= 0; r--) {
8916
+ for (s = s.sort(xm.numerically), r = s.length - 1; r >= 0; r--) {
8860
8917
  if (i = s[r], i === void 0) continue;
8861
8918
  let e = a[`_${i}`], t = o.splice(i, 1)[0];
8862
- (e == null ? void 0 : e[2]) === pm && c.push({
8919
+ (e == null ? void 0 : e[2]) === _m && c.push({
8863
8920
  index: e[1],
8864
8921
  value: t
8865
8922
  });
8866
8923
  }
8867
- c = c.sort(_m.numericallyBy("index"));
8924
+ c = c.sort(xm.numericallyBy("index"));
8868
8925
  let u = c.length;
8869
8926
  for (r = 0; r < u; r++) {
8870
8927
  let e = c[r];
@@ -8874,7 +8931,7 @@ var _m = {
8874
8931
  if (d > 0) for (r = 0; r < d; r++) {
8875
8932
  let t = l[r];
8876
8933
  if (t === void 0) continue;
8877
- let n = new am(o[t.index], t.delta);
8934
+ let n = new lm(o[t.index], t.delta);
8878
8935
  e.push(n, t.index);
8879
8936
  }
8880
8937
  if (!e.children) {
@@ -8883,8 +8940,8 @@ var _m = {
8883
8940
  }
8884
8941
  e.exit();
8885
8942
  };
8886
- vm.filterName = "arrays";
8887
- var ym = function(e) {
8943
+ Sm.filterName = "arrays";
8944
+ var Cm = function(e) {
8888
8945
  if (!e || !e.children || e.delta._t !== "a") return;
8889
8946
  let t = e.left, n = e.children.length;
8890
8947
  for (let r = 0; r < n; r++) {
@@ -8895,16 +8952,16 @@ var ym = function(e) {
8895
8952
  }
8896
8953
  e.setResult(t).exit();
8897
8954
  };
8898
- ym.filterName = "arraysCollectChildren";
8899
- var bm = function(e) {
8955
+ Cm.filterName = "arraysCollectChildren";
8956
+ var wm = function(e) {
8900
8957
  if (!e.nested) {
8901
8958
  let t = e.delta;
8902
- if (t[2] === pm) {
8959
+ if (t[2] === _m) {
8903
8960
  let n = t;
8904
8961
  e.newName = `_${n[1]}`, e.setResult([
8905
8962
  n[0],
8906
8963
  Number.parseInt(e.childName.substring(1), 10),
8907
- pm
8964
+ _m
8908
8965
  ]).exit();
8909
8966
  }
8910
8967
  return;
@@ -8914,20 +8971,20 @@ var bm = function(e) {
8914
8971
  let n = t;
8915
8972
  for (let t in n) {
8916
8973
  if (t === "_t") continue;
8917
- let r = new om(n[t]);
8974
+ let r = new um(n[t]);
8918
8975
  e.push(r, t);
8919
8976
  }
8920
8977
  e.exit();
8921
8978
  };
8922
- bm.filterName = "arrays";
8923
- var xm = (e, t, n) => {
8979
+ wm.filterName = "arrays";
8980
+ var Tm = (e, t, n) => {
8924
8981
  if (typeof t == "string" && t[0] === "_") return Number.parseInt(t.substring(1), 10);
8925
8982
  if (Array.isArray(n) && n[2] === 0) return `_${t}`;
8926
8983
  let r = +t;
8927
8984
  for (let n in e) {
8928
8985
  let i = e[n];
8929
8986
  if (Array.isArray(i)) {
8930
- if (i[2] === pm) {
8987
+ if (i[2] === _m) {
8931
8988
  let e = Number.parseInt(n.substring(1), 10), a = i[1];
8932
8989
  if (a === +t) return e;
8933
8990
  e <= r && a > r ? r++ : e >= r && a < r && r--;
@@ -8935,7 +8992,7 @@ var xm = (e, t, n) => {
8935
8992
  }
8936
8993
  }
8937
8994
  return r;
8938
- }, Sm = (e) => {
8995
+ }, Em = (e) => {
8939
8996
  if (!e || !e.children) return;
8940
8997
  let t = e.delta;
8941
8998
  if (t._t !== "a") return;
@@ -8946,22 +9003,22 @@ var xm = (e, t, n) => {
8946
9003
  let a = r.newName;
8947
9004
  if (a === void 0) {
8948
9005
  if (r.childName === void 0) throw Error("child.childName is undefined");
8949
- a = xm(n, r.childName, r.result);
9006
+ a = Tm(n, r.childName, r.result);
8950
9007
  }
8951
9008
  i[a] !== r.result && (i[a] = r.result);
8952
9009
  }
8953
9010
  e.setResult(i).exit();
8954
9011
  };
8955
- Sm.filterName = "arraysCollectChildren";
9012
+ Em.filterName = "arraysCollectChildren";
8956
9013
  //#endregion
8957
9014
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/dates.js
8958
- var Cm = function(e) {
9015
+ var Dm = function(e) {
8959
9016
  e.left instanceof Date ? (e.right instanceof Date && e.left.getTime() === e.right.getTime() ? e.setResult(void 0) : e.setResult([e.left, e.right]), e.exit()) : e.right instanceof Date && e.setResult([e.left, e.right]).exit();
8960
9017
  };
8961
- Cm.filterName = "dates";
9018
+ Dm.filterName = "dates";
8962
9019
  //#endregion
8963
9020
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/nested.js
8964
- var wm = /* @__PURE__ */ new Set(["__proto__"]), Tm = (e) => {
9021
+ var Om = /* @__PURE__ */ new Set(["__proto__"]), km = (e) => {
8965
9022
  if (!e || !e.children) return;
8966
9023
  let t = e.children.length, n = e.result;
8967
9024
  for (let r = 0; r < t; r++) {
@@ -8973,18 +9030,18 @@ var wm = /* @__PURE__ */ new Set(["__proto__"]), Tm = (e) => {
8973
9030
  }
8974
9031
  n && e.leftIsArray && (n._t = "a"), e.setResult(n).exit();
8975
9032
  };
8976
- Tm.filterName = "collectChildren";
8977
- var Em = (e) => {
9033
+ km.filterName = "collectChildren";
9034
+ var Am = (e) => {
8978
9035
  var t;
8979
9036
  if (e.leftIsArray || e.leftType !== "object") return;
8980
9037
  let n = e.left, r = e.right, i = (t = e.options) == null ? void 0 : t.propertyFilter;
8981
9038
  for (let t in n) {
8982
9039
  if (!Object.prototype.hasOwnProperty.call(n, t) || i && !i(t, e)) continue;
8983
- let a = new im(n[t], r[t]);
9040
+ let a = new cm(n[t], r[t]);
8984
9041
  e.push(a, t);
8985
9042
  }
8986
9043
  for (let t in r) if (Object.prototype.hasOwnProperty.call(r, t) && !(i && !i(t, e)) && n[t] === void 0) {
8987
- let n = new im(void 0, r[t]);
9044
+ let n = new cm(void 0, r[t]);
8988
9045
  e.push(n, t);
8989
9046
  }
8990
9047
  if (!e.children || e.children.length === 0) {
@@ -8993,15 +9050,15 @@ var Em = (e) => {
8993
9050
  }
8994
9051
  e.exit();
8995
9052
  };
8996
- Em.filterName = "objects";
8997
- var Dm = function(e) {
9053
+ Am.filterName = "objects";
9054
+ var jm = function(e) {
8998
9055
  if (!e.nested) return;
8999
9056
  let t = e.delta;
9000
9057
  if (t._t) return;
9001
9058
  let n = t, r = !1;
9002
9059
  for (let t in n) {
9003
- if (wm.has(t) || !Object.prototype.hasOwnProperty.call(n, t)) continue;
9004
- let i = e.left, a = new am(typeof i == "object" && i && Object.prototype.hasOwnProperty.call(i, t) ? i[t] : void 0, n[t]);
9060
+ if (Om.has(t) || !Object.prototype.hasOwnProperty.call(n, t)) continue;
9061
+ let i = e.left, a = new lm(typeof i == "object" && i && Object.prototype.hasOwnProperty.call(i, t) ? i[t] : void 0, n[t]);
9005
9062
  e.push(a, t), r = !0;
9006
9063
  }
9007
9064
  if (!r) {
@@ -9010,8 +9067,8 @@ var Dm = function(e) {
9010
9067
  }
9011
9068
  e.exit();
9012
9069
  };
9013
- Dm.filterName = "objects";
9014
- var Om = function(e) {
9070
+ jm.filterName = "objects";
9071
+ var Mm = function(e) {
9015
9072
  if (!e || !e.children || e.delta._t) return;
9016
9073
  if (e.left === null || typeof e.left != "object") {
9017
9074
  e.setResult(e.left).exit();
@@ -9022,17 +9079,17 @@ var Om = function(e) {
9022
9079
  let n = e.children[r];
9023
9080
  if (n === void 0) continue;
9024
9081
  let i = n.childName;
9025
- wm.has(i) || (Object.prototype.hasOwnProperty.call(e.left, i) && n.result === void 0 ? delete t[i] : t[i] !== n.result && (t[i] = n.result));
9082
+ Om.has(i) || (Object.prototype.hasOwnProperty.call(e.left, i) && n.result === void 0 ? delete t[i] : t[i] !== n.result && (t[i] = n.result));
9026
9083
  }
9027
9084
  e.setResult(t).exit();
9028
9085
  };
9029
- Om.filterName = "collectChildren";
9030
- var km = function(e) {
9086
+ Mm.filterName = "collectChildren";
9087
+ var Nm = function(e) {
9031
9088
  if (!e.nested || e.delta._t) return;
9032
9089
  let t = e.delta, n = !1;
9033
9090
  for (let r in t) {
9034
- if (wm.has(r) || !Object.prototype.hasOwnProperty.call(t, r)) continue;
9035
- let i = new om(t[r]);
9091
+ if (Om.has(r) || !Object.prototype.hasOwnProperty.call(t, r)) continue;
9092
+ let i = new um(t[r]);
9036
9093
  e.push(i, r), n = !0;
9037
9094
  }
9038
9095
  if (!n) {
@@ -9041,25 +9098,25 @@ var km = function(e) {
9041
9098
  }
9042
9099
  e.exit();
9043
9100
  };
9044
- km.filterName = "objects";
9045
- var Am = (e) => {
9101
+ Nm.filterName = "objects";
9102
+ var Pm = (e) => {
9046
9103
  if (!e || !e.children || e.delta._t) return;
9047
9104
  let t = e.children.length, n = {};
9048
9105
  for (let r = 0; r < t; r++) {
9049
9106
  let t = e.children[r];
9050
9107
  if (t === void 0) continue;
9051
9108
  let i = t.childName;
9052
- wm.has(i) || n[i] !== t.result && (n[i] = t.result);
9109
+ Om.has(i) || n[i] !== t.result && (n[i] = t.result);
9053
9110
  }
9054
9111
  e.setResult(n).exit();
9055
9112
  };
9056
- Am.filterName = "collectChildren";
9113
+ Pm.filterName = "collectChildren";
9057
9114
  //#endregion
9058
9115
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/texts.js
9059
- var jm = 2, Mm = 60, Nm = null;
9060
- function Pm(e, t) {
9116
+ var Fm = 2, Im = 60, Lm = null;
9117
+ function Rm(e, t) {
9061
9118
  var n;
9062
- if (!Nm) {
9119
+ if (!Lm) {
9063
9120
  let r;
9064
9121
  if ((n = e == null ? void 0 : e.textDiff) != null && n.diffMatchPatch) r = new e.textDiff.diffMatchPatch();
9065
9122
  else {
@@ -9067,7 +9124,7 @@ function Pm(e, t) {
9067
9124
  let e = /* @__PURE__ */ Error("The diff-match-patch library was not provided. Pass the library in through the options or use the `jsondiffpatch/with-text-diffs` entry-point.");
9068
9125
  throw e.diff_match_patch_not_found = !0, e;
9069
9126
  }
9070
- Nm = {
9127
+ Lm = {
9071
9128
  diff: (e, t) => r.patch_toText(r.patch_make(e, t)),
9072
9129
  patch: (e, t) => {
9073
9130
  let n = r.patch_apply(r.patch_fromText(t), e);
@@ -9079,17 +9136,17 @@ function Pm(e, t) {
9079
9136
  }
9080
9137
  };
9081
9138
  }
9082
- return Nm;
9139
+ return Lm;
9083
9140
  }
9084
- var Fm = function(e) {
9141
+ var zm = function(e) {
9085
9142
  var t, n;
9086
9143
  if (e.leftType !== "string") return;
9087
- let r = e.left, i = e.right, a = ((n = (t = e.options) == null ? void 0 : t.textDiff) == null ? void 0 : n.minLength) || Mm;
9144
+ let r = e.left, i = e.right, a = ((n = (t = e.options) == null ? void 0 : t.textDiff) == null ? void 0 : n.minLength) || Im;
9088
9145
  if (r.length < a || i.length < a) {
9089
9146
  e.setResult([r, i]).exit();
9090
9147
  return;
9091
9148
  }
9092
- let o = Pm(e.options);
9149
+ let o = Rm(e.options);
9093
9150
  if (!o) {
9094
9151
  e.setResult([r, i]).exit();
9095
9152
  return;
@@ -9098,19 +9155,19 @@ var Fm = function(e) {
9098
9155
  e.setResult([
9099
9156
  s(r, i),
9100
9157
  0,
9101
- jm
9158
+ Fm
9102
9159
  ]).exit();
9103
9160
  };
9104
- Fm.filterName = "texts";
9105
- var Im = function(e) {
9161
+ zm.filterName = "texts";
9162
+ var Bm = function(e) {
9106
9163
  if (e.nested) return;
9107
9164
  let t = e.delta;
9108
- if (t[2] !== jm) return;
9109
- let n = t, r = Pm(e.options, !0).patch;
9165
+ if (t[2] !== Fm) return;
9166
+ let n = t, r = Rm(e.options, !0).patch;
9110
9167
  e.setResult(r(e.left, n[0])).exit();
9111
9168
  };
9112
- Im.filterName = "texts";
9113
- var Lm = (e) => {
9169
+ Bm.filterName = "texts";
9170
+ var Vm = (e) => {
9114
9171
  var t, n, r;
9115
9172
  let i = /^@@ +-(\d+),(\d+) +\+(\d+),(\d+) +@@$/, a = e.split("\n");
9116
9173
  for (let e = 0; e < a.length; e++) {
@@ -9131,21 +9188,21 @@ var Lm = (e) => {
9131
9188
  } else s === "-" && (a[e] = `+${(r = a[e]) == null ? void 0 : r.slice(1)}`);
9132
9189
  }
9133
9190
  return a.join("\n");
9134
- }, Rm = function(e) {
9191
+ }, Hm = function(e) {
9135
9192
  if (e.nested) return;
9136
9193
  let t = e.delta;
9137
- if (t[2] !== jm) return;
9194
+ if (t[2] !== Fm) return;
9138
9195
  let n = t;
9139
9196
  e.setResult([
9140
- Lm(n[0]),
9197
+ Vm(n[0]),
9141
9198
  0,
9142
- jm
9199
+ Fm
9143
9200
  ]).exit();
9144
9201
  };
9145
- Rm.filterName = "texts";
9202
+ Hm.filterName = "texts";
9146
9203
  //#endregion
9147
9204
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/trivial.js
9148
- var zm = function(e) {
9205
+ var Um = function(e) {
9149
9206
  if (e.left === e.right) {
9150
9207
  e.setResult(void 0).exit();
9151
9208
  return;
@@ -9178,8 +9235,8 @@ var zm = function(e) {
9178
9235
  }
9179
9236
  e.left instanceof RegExp && (e.right instanceof RegExp ? e.setResult([e.left.toString(), e.right.toString()]).exit() : e.setResult([e.left, e.right]).exit());
9180
9237
  };
9181
- zm.filterName = "trivial";
9182
- var Bm = function(e) {
9238
+ Um.filterName = "trivial";
9239
+ var Wm = function(e) {
9183
9240
  if (e.delta === void 0) {
9184
9241
  e.setResult(e.left).exit();
9185
9242
  return;
@@ -9203,8 +9260,8 @@ var Bm = function(e) {
9203
9260
  }
9204
9261
  t.length === 3 && t[2] === 0 && e.setResult(void 0).exit();
9205
9262
  };
9206
- Bm.filterName = "trivial";
9207
- var Vm = function(e) {
9263
+ Wm.filterName = "trivial";
9264
+ var Gm = function(e) {
9208
9265
  if (e.delta === void 0) {
9209
9266
  e.setResult(e.delta).exit();
9210
9267
  return;
@@ -9225,36 +9282,36 @@ var Vm = function(e) {
9225
9282
  }
9226
9283
  t.length === 3 && t[2] === 0 && e.setResult([t[0]]).exit();
9227
9284
  };
9228
- Vm.filterName = "trivial";
9285
+ Gm.filterName = "trivial";
9229
9286
  //#endregion
9230
9287
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/diffpatcher.js
9231
- var Hm = class {
9288
+ var Km = class {
9232
9289
  constructor(e) {
9233
- this.processor = new cm(e), this.processor.pipe(new sm("diff").append(Tm, zm, Cm, Fm, Em, gm).shouldHaveResult()), this.processor.pipe(new sm("patch").append(Om, ym, Bm, Im, Dm, vm).shouldHaveResult()), this.processor.pipe(new sm("reverse").append(Am, Sm, Vm, Rm, km, bm).shouldHaveResult());
9290
+ this.processor = new fm(e), this.processor.pipe(new dm("diff").append(km, Um, Dm, zm, Am, bm).shouldHaveResult()), this.processor.pipe(new dm("patch").append(Mm, Cm, Wm, Bm, jm, Sm).shouldHaveResult()), this.processor.pipe(new dm("reverse").append(Pm, Em, Gm, Hm, Nm, wm).shouldHaveResult());
9234
9291
  }
9235
9292
  options(e) {
9236
9293
  return this.processor.options(e);
9237
9294
  }
9238
9295
  diff(e, t) {
9239
- return this.processor.process(new im(e, t));
9296
+ return this.processor.process(new cm(e, t));
9240
9297
  }
9241
9298
  patch(e, t) {
9242
- return this.processor.process(new am(e, t));
9299
+ return this.processor.process(new lm(e, t));
9243
9300
  }
9244
9301
  reverse(e) {
9245
- return this.processor.process(new om(e));
9302
+ return this.processor.process(new um(e));
9246
9303
  }
9247
9304
  unpatch(e, t) {
9248
9305
  return this.patch(e, this.reverse(t));
9249
9306
  }
9250
9307
  clone(e) {
9251
- return em(e);
9308
+ return im(e);
9252
9309
  }
9253
9310
  };
9254
9311
  //#endregion
9255
9312
  //#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/index.js
9256
- function Um(e) {
9257
- return new Hm(e);
9313
+ function qm(e) {
9314
+ return new Km(e);
9258
9315
  }
9259
9316
  //#endregion
9260
9317
  //#region node_modules/.pnpm/@dmsnell+diff-match-patch@1.1.0/node_modules/@dmsnell/diff-match-patch/index.js
@@ -9816,46 +9873,46 @@ $.Diff = function(e, t) {
9816
9873
  };
9817
9874
  //#endregion
9818
9875
  //#region src/components/audit-log/create-diff-patcher.tsx
9819
- var Wm = (e = {}) => Um({
9876
+ var Jm = (e = {}) => qm({
9820
9877
  ...e,
9821
9878
  textDiff: {
9822
9879
  diffMatchPatch: $,
9823
9880
  minLength: 120
9824
9881
  },
9825
9882
  cloneDiffValues: !0
9826
- }), Gm = ["user", "unittemplate"], Km = Wm(), qm = (e, t, n) => {
9883
+ }), Ym = ["user", "unittemplate"], Xm = Jm(), Zm = (e, t, n) => {
9827
9884
  let r = Object.fromEntries(e.map((e) => [e.sectionKey, e.sectionLabel]));
9828
9885
  for (let e = t.length - 1; e >= 0; e--) {
9829
9886
  let n = r[t[e]];
9830
9887
  if (n) return n;
9831
9888
  }
9832
9889
  return n || "";
9833
- }, Jm = (e) => {
9890
+ }, Qm = (e) => {
9834
9891
  let t = (e) => _r(e) ? kr(e) : String(e);
9835
9892
  return Array.isArray(e) ? e.length === 0 ? "" : e.some((e) => e && typeof e == "object") ? "Multiple changes..." : e.map(t).join(", ") : e && typeof e == "object" ? Object.keys(e).length === 0 ? "" : "Multiple changes..." : t(e);
9836
- }, Ym = (e) => {
9893
+ }, $m = (e) => {
9837
9894
  switch (e.length) {
9838
9895
  case 1: {
9839
9896
  let [t] = e;
9840
9897
  return {
9841
9898
  type: "created",
9842
9899
  before: "",
9843
- after: Jm(t)
9900
+ after: Qm(t)
9844
9901
  };
9845
9902
  }
9846
9903
  case 2: {
9847
9904
  let [t, n] = e;
9848
9905
  return {
9849
9906
  type: "modified",
9850
- before: Jm(t),
9851
- after: Jm(n)
9907
+ before: Qm(t),
9908
+ after: Qm(n)
9852
9909
  };
9853
9910
  }
9854
9911
  case 3: {
9855
9912
  let [t] = e;
9856
9913
  return {
9857
9914
  type: "deleted",
9858
- before: Jm(t),
9915
+ before: Qm(t),
9859
9916
  after: ""
9860
9917
  };
9861
9918
  }
@@ -9865,15 +9922,15 @@ var Wm = (e = {}) => Um({
9865
9922
  after: ""
9866
9923
  };
9867
9924
  }
9868
- }, Xm = (e) => Array.isArray(e), Zm = (e, t) => t ? Xm(t) ? t.length === 0 ? e : t.reduce((e, t) => Km.unpatch(tn(e), tn(t)), tn(e)) : Km.unpatch(tn(e), tn(t)) : e, Qm = (e) => e.createdAt || e.date, $m = (e, t, n) => {
9869
- let r = Qm(e);
9925
+ }, eh = (e) => Array.isArray(e), th = (e, t) => t ? eh(t) ? t.length === 0 ? e : t.reduce((e, t) => Xm.unpatch(tn(e), tn(t)), tn(e)) : Xm.unpatch(tn(e), tn(t)) : e, nh = (e) => e.createdAt || e.date, rh = (e, t, n) => {
9926
+ let r = nh(e);
9870
9927
  if (!r) return {
9871
9928
  oldJson: "",
9872
9929
  newJson: "",
9873
9930
  error: `Cannot create comparison view: missing date for audit log ${e.id}`
9874
9931
  };
9875
9932
  let i = t.filter((e) => {
9876
- let t = Qm(e);
9933
+ let t = nh(e);
9877
9934
  return !!(e.diffs && t && t >= r);
9878
9935
  }), a = Array.from({ length: i.length + 1 });
9879
9936
  a[0] = tn(n);
@@ -9886,7 +9943,7 @@ var Wm = (e = {}) => Um({
9886
9943
  a[e + 1] = a[e];
9887
9944
  continue;
9888
9945
  }
9889
- a[e + 1] = Zm(a[e], t);
9946
+ a[e + 1] = th(a[e], t);
9890
9947
  }
9891
9948
  let e = i.length > 0 ? a[i.length - 1] : n, t = i.length > 0 ? a[i.length] : n;
9892
9949
  o = JSON.stringify(t == null ? "" : t, null, 2), s = JSON.stringify(e == null ? "" : e, null, 2);
@@ -9901,10 +9958,10 @@ var Wm = (e = {}) => Um({
9901
9958
  oldJson: o,
9902
9959
  newJson: s
9903
9960
  };
9904
- }, eh = (e, t, n = {}, r = []) => {
9961
+ }, ih = (e, t, n = {}, r = []) => {
9905
9962
  var i;
9906
9963
  if (!e) return;
9907
- let a = [...Gm, ...(i = n.hiddenKeys) == null ? [] : i];
9964
+ let a = [...Ym, ...(i = n.hiddenKeys) == null ? [] : i];
9908
9965
  Object.keys(e).forEach((i) => {
9909
9966
  var o;
9910
9967
  let s = e[i];
@@ -9917,12 +9974,12 @@ var Wm = (e = {}) => Um({
9917
9974
  sn(s) ? t.push({
9918
9975
  deltaFormat: [...s],
9919
9976
  path: c
9920
- }) : hn(s) && eh(s, t, n, c);
9977
+ }) : hn(s) && ih(s, t, n, c);
9921
9978
  });
9922
- }, th = (e, t = {}) => {
9979
+ }, ah = (e, t = {}) => {
9923
9980
  let n = [];
9924
- return e ? (eh(e, n, t), n) : [];
9925
- }, nh = (e) => e.replace(/\[\d+\]/g, "").replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]/g, " ").replace(/\s+/g, " ").trim().replace(/^./, (e) => e.toUpperCase()), rh = (e) => {
9981
+ return e ? (ih(e, n, t), n) : [];
9982
+ }, oh = (e) => e.replace(/\[\d+\]/g, "").replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]/g, " ").replace(/\s+/g, " ").trim().replace(/^./, (e) => e.toUpperCase()), sh = (e) => {
9926
9983
  if (e == null || e === "") return "empty";
9927
9984
  if (typeof e == "boolean") return e ? "true" : "false";
9928
9985
  if (typeof e == "string") return e;
@@ -9933,27 +9990,27 @@ var Wm = (e = {}) => Um({
9933
9990
  } catch {
9934
9991
  return String(e);
9935
9992
  }
9936
- }, ih = (e, t = e.length - 1) => {
9993
+ }, ch = (e, t = e.length - 1) => {
9937
9994
  if (t >= e.length) return "Value";
9938
9995
  let n = e[t];
9939
- return !n || mr(n) ? ih(e, t - 1) : nh(n);
9940
- }, ah = ({ userName: e, type: t, property: n, before: r, after: i, sectionName: a }) => {
9941
- let o = rh(r), s = rh(i), c = a ? ` in ${a}` : "";
9996
+ return !n || mr(n) ? ch(e, t - 1) : oh(n);
9997
+ }, lh = ({ userName: e, type: t, property: n, before: r, after: i, sectionName: a }) => {
9998
+ let o = sh(r), s = sh(i), c = a ? ` in ${a}` : "";
9942
9999
  switch (t) {
9943
10000
  case "modified": return `${e} updated ${n} from ${o} to ${s}${c}.`;
9944
10001
  case "created": return `${e} created ${s}${c}.`;
9945
10002
  case "deleted": return `${e} deleted ${o}${c}.`;
9946
10003
  default: return `${e} changed ${n}${c}.`;
9947
10004
  }
9948
- }, oh = ({ sectionNames: e, userName: t, diffs: n, defaultSectionName: r }) => {
10005
+ }, uh = ({ sectionNames: e, userName: t, diffs: n, defaultSectionName: r }) => {
9949
10006
  let i = {
9950
10007
  headers: [{ cells: [{ value: "Changes" }] }],
9951
10008
  rows: n.map((n) => {
9952
- let { deltaFormat: i, path: a } = n, o = qm(e, a, r), { type: s, before: c, after: l } = Ym(i);
9953
- return { cells: [{ value: ah({
10009
+ let { deltaFormat: i, path: a } = n, o = Zm(e, a, r), { type: s, before: c, after: l } = $m(i);
10010
+ return { cells: [{ value: lh({
9954
10011
  userName: t,
9955
10012
  type: s,
9956
- property: ih(a),
10013
+ property: ch(a),
9957
10014
  before: c,
9958
10015
  after: l,
9959
10016
  sectionName: o
@@ -9961,7 +10018,7 @@ var Wm = (e = {}) => Um({
9961
10018
  })
9962
10019
  };
9963
10020
  return /* @__PURE__ */ S(eu, { table: i });
9964
- }, sh = Object.freeze({
10021
+ }, dh = Object.freeze({
9965
10022
  summary: {
9966
10023
  label: "Summary",
9967
10024
  value: "summary"
@@ -9970,13 +10027,13 @@ var Wm = (e = {}) => Um({
9970
10027
  label: "Compare",
9971
10028
  value: "compare"
9972
10029
  }
9973
- }), ch = ({ auditLog: e, auditLogs: t, data: n, isOpen: r, transformDiffsConfig: i, sectionNames: a, defaultSectionName: o, onClose: s }) => {
9974
- let c = [sh.summary, sh.compare].map(({ label: e, value: t }) => ({
10030
+ }), fh = ({ auditLog: e, auditLogs: t, data: n, isOpen: r, transformDiffsConfig: i, sectionNames: a, defaultSectionName: o, onClose: s }) => {
10031
+ let c = [dh.summary, dh.compare].map(({ label: e, value: t }) => ({
9975
10032
  label: e,
9976
10033
  value: t
9977
10034
  })), [l, u] = v(c[0]), { diffs: d = void 0 } = e || {};
9978
10035
  if (!d) return null;
9979
- let { oldJson: f, newJson: p, error: m } = $m(e, t, n);
10036
+ let { oldJson: f, newJson: p, error: m } = rh(e, t, n);
9980
10037
  return /* @__PURE__ */ S(Ts, {
9981
10038
  visible: r,
9982
10039
  centered: !0,
@@ -9989,15 +10046,15 @@ var Wm = (e = {}) => Um({
9989
10046
  onChange: (e) => u(c.find((t) => t.value === e.target.value)),
9990
10047
  options: c,
9991
10048
  value: l
9992
- }), l.value === "summary" ? /* @__PURE__ */ S(oh, {
10049
+ }), l.value === "summary" ? /* @__PURE__ */ S(uh, {
9993
10050
  userName: e.userName,
9994
10051
  sectionNames: a,
9995
- diffs: th(d, i),
10052
+ diffs: ah(d, i),
9996
10053
  defaultSectionName: o
9997
10054
  }) : m ? /* @__PURE__ */ S("div", {
9998
10055
  style: { padding: 16 },
9999
10056
  children: m
10000
- }) : /* @__PURE__ */ S(Vp, {
10057
+ }) : /* @__PURE__ */ S(Jp, {
10001
10058
  oldJson: f,
10002
10059
  newJson: p
10003
10060
  })] }),
@@ -10010,7 +10067,7 @@ var Wm = (e = {}) => Um({
10010
10067
  height: "90vh"
10011
10068
  } })
10012
10069
  });
10013
- }, lh = [
10070
+ }, ph = [
10014
10071
  {
10015
10072
  label: "10 / page",
10016
10073
  value: 10
@@ -10023,19 +10080,18 @@ var Wm = (e = {}) => Um({
10023
10080
  label: "50 / page",
10024
10081
  value: 50
10025
10082
  }
10026
- ], uh = (e, t = {}) => {
10027
- let { diffs: n, userName: r, source: i, operation: a, operationMetaData: o } = e, s = th(n, t).length, c = s ? `${s} change${s === 1 ? "" : "s"}` : "no field changes";
10083
+ ], mh = (e, t = {}) => {
10084
+ let { diffs: n, userName: r, source: i, operation: a, operationMetaData: o } = e, s = ah(n, t).length, c = s ? `${s} change${s === 1 ? "" : "s"}` : "no field changes";
10028
10085
  if (i === "API" && !r) return a === "Created" ? "Created through API" : "Changed through API";
10029
10086
  switch (a) {
10030
10087
  case "Created": return `Created by ${r}`;
10031
10088
  case "Cloned": return `Cloned by ${r} (from ${o || "unknown"})`;
10032
- case "Reverted": return `Reverted by ${r} ${o ? `(from ${o})` : ""}`;
10033
- case "Restored": return `Restored by ${r} ${o ? `(from ${o})` : ""}`;
10089
+ case "Reverted": return `Restored by ${r} ${o ? `(from ${o})` : ""}`;
10034
10090
  case "Imported": return `Imported by ${r}`;
10035
10091
  case "Updated": return `Updated by ${r} (${c})`;
10036
10092
  default: return `Change by ${r}`;
10037
10093
  }
10038
- }, dh = ({ logs: e, data: t, total: n, loading: r, selectedPage: i, rowsPerPage: a, sectionNames: o, defaultSectionName: s, filterToggles: c = [], transformDiffsConfig: l, onChangeRowsPerPage: u, onSelectPage: d, onClickSnapshot: f, snapshotLoading: p, getActions: m, isLogDisabled: h }) => {
10094
+ }, hh = ({ logs: e, data: t, total: n, loading: r, selectedPage: i, rowsPerPage: a, sectionNames: o, defaultSectionName: s, filterToggles: c = [], transformDiffsConfig: l, onChangeRowsPerPage: u, onSelectPage: d, onClickSnapshot: f, snapshotLoading: p, getActions: m, isLogDisabled: h }) => {
10039
10095
  let [g, _] = v(!1), [y, b] = v(null), w = (e) => {
10040
10096
  if (e.snapshot) {
10041
10097
  f == null || f(e.snapshot, e);
@@ -10054,7 +10110,7 @@ var Wm = (e = {}) => Um({
10054
10110
  return {
10055
10111
  cells: [
10056
10112
  {
10057
- value: e.snapshot ? `Snapshot: ${e.snapshot}` : uh(e, l),
10113
+ value: e.snapshot ? `Snapshot: ${e.snapshot}` : mh(e, l),
10058
10114
  type: "Link",
10059
10115
  disabled: n,
10060
10116
  onClick: n ? void 0 : () => w(e),
@@ -10073,8 +10129,8 @@ var Wm = (e = {}) => Um({
10073
10129
  type: "Static"
10074
10130
  },
10075
10131
  {
10076
- value: Qp({
10077
- date: Qm(e),
10132
+ value: nm({
10133
+ date: nh(e),
10078
10134
  showTime: !0
10079
10135
  }),
10080
10136
  type: "Static"
@@ -10117,14 +10173,14 @@ var Wm = (e = {}) => Um({
10117
10173
  onChange: (e) => {
10118
10174
  u(Number(e.target.value));
10119
10175
  },
10120
- options: lh,
10176
+ options: ph,
10121
10177
  value: a
10122
10178
  },
10123
10179
  onSelectPage: (e) => d(e),
10124
10180
  small: !0
10125
10181
  } }
10126
10182
  } })
10127
- }), g && y && y.diffs && /* @__PURE__ */ S(ch, {
10183
+ }), g && y && y.diffs && /* @__PURE__ */ S(fh, {
10128
10184
  sectionNames: o,
10129
10185
  isOpen: g,
10130
10186
  onClose: () => _(!1),
@@ -10134,7 +10190,7 @@ var Wm = (e = {}) => Um({
10134
10190
  data: t,
10135
10191
  transformDiffsConfig: l
10136
10192
  })] });
10137
- }, fh = ({ pathName: e, moduleName: t, onNavigate: n, onStartTimingEvent: r }) => {
10193
+ }, gh = ({ pathName: e, moduleName: t, onNavigate: n, onStartTimingEvent: r }) => {
10138
10194
  let i = window.location.href, a = _(i);
10139
10195
  return d(() => {
10140
10196
  a.current = i;
@@ -10157,20 +10213,20 @@ var Wm = (e = {}) => Um({
10157
10213
  });
10158
10214
  };
10159
10215
  }, [e, t]), null;
10160
- }, ph = {
10216
+ }, _h = {
10161
10217
  errorBoundary: "_errorBoundary_hmco0_1",
10162
10218
  sidebarErrorBoundary: "_sidebarErrorBoundary_hmco0_5",
10163
10219
  rightSidebarErrorBoundary: "_rightSidebarErrorBoundary_hmco0_6"
10164
- }, mh = ({ options: e }) => {
10220
+ }, vh = ({ options: e }) => {
10165
10221
  let { ErrorComponent: t, isSideBar: n, isRightSideBar: r, isPage: i, style: a } = e == null ? {} : e, { translations: o } = Ap();
10166
10222
  if (t) return /* @__PURE__ */ S(t, {});
10167
10223
  if (n || r) return /* @__PURE__ */ S("div", {
10168
- className: b(n ? ph.sidebarErrorBoundary : "", r ? ph.rightSidebarErrorBoundary : ""),
10224
+ className: b(n ? _h.sidebarErrorBoundary : "", r ? _h.rightSidebarErrorBoundary : ""),
10169
10225
  style: a,
10170
10226
  children: o == null ? void 0 : o.unexpectedError
10171
10227
  });
10172
10228
  let s = /* @__PURE__ */ S("div", {
10173
- className: ph.errorBoundary,
10229
+ className: _h.errorBoundary,
10174
10230
  style: a,
10175
10231
  children: /* @__PURE__ */ S(Gs, { message: {
10176
10232
  icon: !0,
@@ -10185,19 +10241,19 @@ var Wm = (e = {}) => Um({
10185
10241
  padding: 0,
10186
10242
  children: s
10187
10243
  }) : s;
10188
- }, hh = ({ children: e, options: t }) => /* @__PURE__ */ S(Ei.ErrorBoundary, {
10189
- fallback: /* @__PURE__ */ S(mh, { options: t }),
10244
+ }, yh = ({ children: e, options: t }) => /* @__PURE__ */ S(Ei.ErrorBoundary, {
10245
+ fallback: /* @__PURE__ */ S(vh, { options: t }),
10190
10246
  onError: (e, t) => {
10191
10247
  console.error("Error caught by boundary:", e, t);
10192
10248
  },
10193
10249
  children: e
10194
- }), gh = (e, t = {}) => (n) => /* @__PURE__ */ S(hh, {
10250
+ }), bh = (e, t = {}) => (n) => /* @__PURE__ */ S(yh, {
10195
10251
  options: t,
10196
10252
  children: /* @__PURE__ */ S(e, { ...n })
10197
- }), _h = (e = {}) => (t) => gh(t, e), vh = (e) => typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null, yh = (e) => {
10253
+ }), xh = (e = {}) => (t) => bh(t, e), Sh = (e) => typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null, Ch = (e) => {
10198
10254
  jp(Ep.LanguageKey, e.languageKey), Object.entries(e).forEach(([e, t]) => {
10199
- e === Ep.Translations ? jp(e, Op(t)) : jp(e, vh(t) ? t : { ...t });
10255
+ e === Ep.Translations ? jp(e, Op(t)) : jp(e, Sh(t) ? t : { ...t });
10200
10256
  });
10201
10257
  };
10202
10258
  //#endregion
10203
- export { Zi as Accordion, ya as AccordionWithDefaultToggle, fo as Actions, ki as Align, dh as AuditLog, no as Badge, go as Breadcrumb, mo as BreadcrumbLinkType, q as Button, vo as ButtonGroup, Ai as ButtonPosition, Ca as ButtonType, bo as Card, ha as CheckBox, Gi as Chevron, Ji as Collapse, Oi as Color, Vo as ColorInput, Bo as ColorInputPopover, Ko as Column, rs as Dialog, Zp as DiffTable, Vp as DiffViewer, W as DisabledContext, Zo as Divider, us as Drawer, rp as ElementType, du as Empty, hh as ErrorBoundary, yd as Field, hd as FileButton, bs as FileInput, bd as Flex, Sd as FormRow, Eo as Grid, H as GroupOrder, es as Heading, ma as HelpIcon, G as Icon, U as IconType, hs as Input, ps as InputGroup, ol as InputGroupAddon, _s as InputReaderMethods, Ni as InputType, _d as Label, Fd as List, wd as ListHeading, Ad as ListSubheading, Ld as Loader, mf as Mention, lo as Menu, Ka as MenuCarat, Ga as MenuType, Gs as Message, zs as MessageType, Ts as Modal, Zs as NativeSelect, yl as NumberInput, Wd as OptionDropdown, Kd as Page, sl as Pagination, lp as PopConfirm, So as Popover, qd as Portal, Yd as PrintHeader, Os as ProgressBar, Xd as RadioButton, pf as RichTextInput, gf as Row, el as Select, Lp as SettingField, xf as SideBar, Cf as Skeleton, kl as Slider, Ns as SmartUploadModal, xs as Spacer, Sa as Spinner, eu as Table, md as TableImportExport, Xf as Tabs, Yo as Text, $f as TextArea, Zf as TextLink, ji as TextTransform, Mi as Theme, ai as Toaster, Qu as Toggle, K as Tooltip, op as TopBar, pp as Tree, Tp as TreeTable, Di as TriggerType, Uf as UnitInput, qf as UnitSlider, Fp as UnitTable, fh as UsageTracker, Yu as dismissToast, Bf as initializeContext, yh as initializeGuiLibrary, vs as readFile, Ju as toast, Qs as useFocus, Ss as useKeyboardEvent, tc as useWindowWidth, _h as withChainableErrorBoundary, gh as withErrorBoundary };
10259
+ export { Zi as Accordion, ya as AccordionWithDefaultToggle, fo as Actions, ki as Align, hh as AuditLog, no as Badge, go as Breadcrumb, mo as BreadcrumbLinkType, q as Button, vo as ButtonGroup, Ai as ButtonPosition, Ca as ButtonType, bo as Card, ha as CheckBox, Gi as Chevron, Ji as Collapse, Oi as Color, Vo as ColorInput, Bo as ColorInputPopover, Ko as Column, rs as Dialog, Wp as DiffCode, tm as DiffTable, Jp as DiffViewer, W as DisabledContext, Zo as Divider, us as Drawer, rp as ElementType, du as Empty, yh as ErrorBoundary, yd as Field, hd as FileButton, bs as FileInput, bd as Flex, Sd as FormRow, Eo as Grid, H as GroupOrder, es as Heading, ma as HelpIcon, G as Icon, U as IconType, hs as Input, ps as InputGroup, ol as InputGroupAddon, _s as InputReaderMethods, Ni as InputType, _d as Label, Fd as List, wd as ListHeading, Ad as ListSubheading, Ld as Loader, mf as Mention, lo as Menu, Ka as MenuCarat, Ga as MenuType, Gs as Message, zs as MessageType, Ts as Modal, Zs as NativeSelect, yl as NumberInput, Wd as OptionDropdown, Kd as Page, sl as Pagination, lp as PopConfirm, So as Popover, qd as Portal, Yd as PrintHeader, Os as ProgressBar, Xd as RadioButton, pf as RichTextInput, gf as Row, el as Select, Lp as SettingField, xf as SideBar, Cf as Skeleton, kl as Slider, Ns as SmartUploadModal, xs as Spacer, Sa as Spinner, eu as Table, md as TableImportExport, Xf as Tabs, Yo as Text, $f as TextArea, Zf as TextLink, ji as TextTransform, Mi as Theme, ai as Toaster, Qu as Toggle, K as Tooltip, op as TopBar, pp as Tree, Tp as TreeTable, Di as TriggerType, Uf as UnitInput, qf as UnitSlider, Fp as UnitTable, gh as UsageTracker, Yu as dismissToast, Bf as initializeContext, Ch as initializeGuiLibrary, vs as readFile, Ju as toast, Qs as useFocus, Ss as useKeyboardEvent, tc as useWindowWidth, xh as withChainableErrorBoundary, bh as withErrorBoundary };