@oliasoft-open-source/react-ui-library 10.4.0 → 10.5.0-beta-1
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/global.css +1 -1
- package/dist/index.d.ts +21 -0
- package/dist/index.js +436 -371
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -6881,6 +6881,71 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6881
6881
|
children: m
|
|
6882
6882
|
});
|
|
6883
6883
|
}, Sf = {
|
|
6884
|
+
root: "_root_1byf6_7",
|
|
6885
|
+
isResizing: "_isResizing_1byf6_12",
|
|
6886
|
+
handle: "_handle_1byf6_15",
|
|
6887
|
+
axisX: "_axisX_1byf6_34",
|
|
6888
|
+
start: "_start_1byf6_40",
|
|
6889
|
+
end: "_end_1byf6_43",
|
|
6890
|
+
axisY: "_axisY_1byf6_46"
|
|
6891
|
+
}, Cf = {
|
|
6892
|
+
x: {
|
|
6893
|
+
start: "w",
|
|
6894
|
+
end: "e"
|
|
6895
|
+
},
|
|
6896
|
+
y: {
|
|
6897
|
+
start: "n",
|
|
6898
|
+
end: "s"
|
|
6899
|
+
}
|
|
6900
|
+
}, wf = o((e, t) => {
|
|
6901
|
+
let { handleAxis: n, ...r } = e;
|
|
6902
|
+
return /* @__PURE__ */ S("div", {
|
|
6903
|
+
ref: t,
|
|
6904
|
+
className: Sf.handle,
|
|
6905
|
+
...r,
|
|
6906
|
+
children: /* @__PURE__ */ S(G, { icon: U.DRAG })
|
|
6907
|
+
});
|
|
6908
|
+
}), Tf = Un, Ef = ({ children: e, axis: t, size: n, onResize: r, minSize: i = 0, maxSize: a = Infinity, handlePosition: o, className: s }) => {
|
|
6909
|
+
let c = _(null), [l, u] = v(!1), [f, p] = v(Infinity), m = o == null ? t === "y" ? "start" : "end" : o, h = t === "x", g = Cf[t][m], y = Math.min(a, f);
|
|
6910
|
+
d(() => {
|
|
6911
|
+
var e;
|
|
6912
|
+
let t = (e = c.current) == null ? void 0 : e.parentElement;
|
|
6913
|
+
if (!t) return;
|
|
6914
|
+
let n = () => {
|
|
6915
|
+
p(h ? t.clientWidth : t.clientHeight);
|
|
6916
|
+
};
|
|
6917
|
+
n();
|
|
6918
|
+
let r = new ResizeObserver(n);
|
|
6919
|
+
return r.observe(t), () => r.disconnect();
|
|
6920
|
+
}, [h]);
|
|
6921
|
+
let x = (e, t) => {
|
|
6922
|
+
r(h ? t.size.width : t.size.height);
|
|
6923
|
+
}, C = h ? {
|
|
6924
|
+
width: n,
|
|
6925
|
+
height: "100%"
|
|
6926
|
+
} : {
|
|
6927
|
+
height: n,
|
|
6928
|
+
width: "100%"
|
|
6929
|
+
};
|
|
6930
|
+
return /* @__PURE__ */ S(Tf, {
|
|
6931
|
+
width: h ? n : 100,
|
|
6932
|
+
height: h ? 100 : n,
|
|
6933
|
+
minConstraints: h ? [i, 0] : [0, i],
|
|
6934
|
+
maxConstraints: h ? [y, Infinity] : [Infinity, y],
|
|
6935
|
+
onResize: x,
|
|
6936
|
+
handle: /* @__PURE__ */ S(wf, {}),
|
|
6937
|
+
resizeHandles: [g],
|
|
6938
|
+
axis: t,
|
|
6939
|
+
onResizeStart: () => u(!0),
|
|
6940
|
+
onResizeStop: () => u(!1),
|
|
6941
|
+
children: /* @__PURE__ */ S("div", {
|
|
6942
|
+
ref: c,
|
|
6943
|
+
className: b(Sf.root, h ? Sf.axisX : Sf.axisY, Sf[m], l && Sf.isResizing, s),
|
|
6944
|
+
style: C,
|
|
6945
|
+
children: e
|
|
6946
|
+
})
|
|
6947
|
+
});
|
|
6948
|
+
}, Df = {
|
|
6884
6949
|
inputInTable: "_inputInTable_t1w93_1",
|
|
6885
6950
|
inputHover: "_inputHover_t1w93_13",
|
|
6886
6951
|
inputFocus: "_inputFocus_t1w93_18",
|
|
@@ -6900,7 +6965,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6900
6965
|
experimental: "_experimental_t1w93_159",
|
|
6901
6966
|
active: "_active_t1w93_163",
|
|
6902
6967
|
icon: "_icon_t1w93_167"
|
|
6903
|
-
},
|
|
6968
|
+
}, Of = c(({ isOpen: e, label: t, icon: n, invalid: r }) => /* @__PURE__ */ C(x, { children: [/* @__PURE__ */ S(K, {
|
|
6904
6969
|
text: t,
|
|
6905
6970
|
enabled: !e,
|
|
6906
6971
|
placement: "right-center",
|
|
@@ -6909,7 +6974,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6909
6974
|
padding: "var(--padding-sm)",
|
|
6910
6975
|
display: "block",
|
|
6911
6976
|
children: /* @__PURE__ */ S("span", {
|
|
6912
|
-
className:
|
|
6977
|
+
className: Df.icon,
|
|
6913
6978
|
children: /* @__PURE__ */ S(Qa, {
|
|
6914
6979
|
small: !0,
|
|
6915
6980
|
title: r ? "!" : void 0,
|
|
@@ -6918,18 +6983,18 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6918
6983
|
})
|
|
6919
6984
|
})
|
|
6920
6985
|
}), /* @__PURE__ */ S("span", {
|
|
6921
|
-
className:
|
|
6986
|
+
className: Df.label,
|
|
6922
6987
|
children: t
|
|
6923
|
-
})] }), (e, t) => Dr(e, t)),
|
|
6924
|
-
className:
|
|
6988
|
+
})] }), (e, t) => Dr(e, t)), kf = ({ isOpen: e, items: t, sectionIndex: n, onClick: r, testId: i }) => /* @__PURE__ */ S("div", {
|
|
6989
|
+
className: Df.list,
|
|
6925
6990
|
children: t.map((t, a) => {
|
|
6926
6991
|
let o = `${n}_${a}`;
|
|
6927
6992
|
return /* @__PURE__ */ S("a", {
|
|
6928
6993
|
href: t.value,
|
|
6929
|
-
className: b(
|
|
6994
|
+
className: b(Df.item, t.isActive ? Df.active : "", t.isExperimental ? Df.experimental : ""),
|
|
6930
6995
|
onClick: (e) => r(e, t.value, t.label, t.onClick),
|
|
6931
6996
|
"data-testid": i,
|
|
6932
|
-
children: /* @__PURE__ */ S(
|
|
6997
|
+
children: /* @__PURE__ */ S(Of, {
|
|
6933
6998
|
label: t.label,
|
|
6934
6999
|
icon: t.icon,
|
|
6935
7000
|
invalid: t.invalid,
|
|
@@ -6937,16 +7002,16 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6937
7002
|
}, o)
|
|
6938
7003
|
}, o);
|
|
6939
7004
|
})
|
|
6940
|
-
}),
|
|
6941
|
-
className:
|
|
7005
|
+
}), Af = ({ isOpen: t, sections: n, onClick: r }) => /* @__PURE__ */ S(x, { children: n.map((n, i) => /* @__PURE__ */ C(e.Fragment, { children: [/* @__PURE__ */ S("h5", {
|
|
7006
|
+
className: Df.subtitle,
|
|
6942
7007
|
children: n.heading.toUpperCase()
|
|
6943
|
-
}), /* @__PURE__ */ S(
|
|
7008
|
+
}), /* @__PURE__ */ S(kf, {
|
|
6944
7009
|
isOpen: t,
|
|
6945
7010
|
items: n.items,
|
|
6946
7011
|
sectionIndex: i,
|
|
6947
7012
|
onClick: r,
|
|
6948
7013
|
testId: n.testId
|
|
6949
|
-
})] }, i)) }),
|
|
7014
|
+
})] }, i)) }), jf = c(({ options: e, startOpen: t = !1, onShiftClickToggleOpen: n = () => {}, top: r, testId: i }) => {
|
|
6950
7015
|
let [a, o] = v(t), s = (e, t, n, r) => {
|
|
6951
7016
|
e.preventDefault(), typeof r == "function" && (e.currentTarget.value = t, e.currentTarget.label = n, r(e)), o(!1);
|
|
6952
7017
|
}, c = e.sections.length > 0;
|
|
@@ -6969,13 +7034,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6969
7034
|
testId: i ? `${i}-toggle` : void 0
|
|
6970
7035
|
}),
|
|
6971
7036
|
children: /* @__PURE__ */ S("div", {
|
|
6972
|
-
className: b(
|
|
7037
|
+
className: b(Df.sidebar, a ? "" : Df.collapsed),
|
|
6973
7038
|
children: c && /* @__PURE__ */ C("div", {
|
|
6974
|
-
className:
|
|
7039
|
+
className: Df.inner,
|
|
6975
7040
|
children: [/* @__PURE__ */ S("h4", {
|
|
6976
|
-
className:
|
|
7041
|
+
className: Df.title,
|
|
6977
7042
|
children: e.title
|
|
6978
|
-
}), /* @__PURE__ */ S(
|
|
7043
|
+
}), /* @__PURE__ */ S(Af, {
|
|
6979
7044
|
isOpen: a,
|
|
6980
7045
|
sections: e.sections,
|
|
6981
7046
|
onClick: s
|
|
@@ -6983,18 +7048,18 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
6983
7048
|
})
|
|
6984
7049
|
})
|
|
6985
7050
|
});
|
|
6986
|
-
}, (e, t) => Dr(e, t)),
|
|
7051
|
+
}, (e, t) => Dr(e, t)), Mf = {
|
|
6987
7052
|
skeletonContainer: "_skeletonContainer_mcfxp_9",
|
|
6988
7053
|
skeleton: "_skeleton_mcfxp_9"
|
|
6989
|
-
},
|
|
7054
|
+
}, Nf = ({ count: e, width: t, height: n }) => /* @__PURE__ */ S(_i, {
|
|
6990
7055
|
baseColor: "var(--color-skeleton-base)",
|
|
6991
7056
|
highlightColor: "var(--color-skeleton-highlight)",
|
|
6992
|
-
containerClassName:
|
|
6993
|
-
className:
|
|
7057
|
+
containerClassName: Mf.skeletonContainer,
|
|
7058
|
+
className: Mf.skeleton,
|
|
6994
7059
|
count: e,
|
|
6995
7060
|
width: t,
|
|
6996
7061
|
height: n
|
|
6997
|
-
}),
|
|
7062
|
+
}), Pf = {
|
|
6998
7063
|
wrapper: "_wrapper_j8x9r_1",
|
|
6999
7064
|
label: "_label_j8x9r_5",
|
|
7000
7065
|
input: "_input_j8x9r_9",
|
|
@@ -7002,38 +7067,38 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7002
7067
|
editable: "_editable_j8x9r_22",
|
|
7003
7068
|
inputControl: "_inputControl_j8x9r_25",
|
|
7004
7069
|
actions: "_actions_j8x9r_28"
|
|
7005
|
-
},
|
|
7070
|
+
}, Ff = () => {
|
|
7006
7071
|
let e = _(null);
|
|
7007
7072
|
return m(() => {
|
|
7008
7073
|
e.current && (e.current(), e.current = null);
|
|
7009
7074
|
}), (t) => {
|
|
7010
7075
|
e.current = t;
|
|
7011
7076
|
};
|
|
7012
|
-
},
|
|
7077
|
+
}, If = (e) => {
|
|
7013
7078
|
let t = _(void 0);
|
|
7014
7079
|
return d(() => {
|
|
7015
7080
|
t.current = e;
|
|
7016
7081
|
}, [e]), t.current;
|
|
7017
|
-
},
|
|
7082
|
+
}, Lf = (e, t) => {
|
|
7018
7083
|
let n = t == null ? void 0 : t[e];
|
|
7019
7084
|
if (!n) {
|
|
7020
7085
|
var r;
|
|
7021
7086
|
return console.log(`Warning: 'unitTemplate' missing for '${e}'. Using initial unit, preferred unit or value unit.`), (r = pr(e)) == null ? "" : r;
|
|
7022
7087
|
}
|
|
7023
7088
|
return n;
|
|
7024
|
-
},
|
|
7089
|
+
}, Rf = /* @__PURE__ */ function(e) {
|
|
7025
7090
|
return e.CUSTOM = "custom", e.PREDEFINED = "predefined", e;
|
|
7026
|
-
}({}),
|
|
7091
|
+
}({}), zf = (e) => e === "undefined" || e === void 0 || e === "" || e === "null" || e === null || e === "NaN" || isNaN(e), Bf = (e) => {
|
|
7027
7092
|
if (!e) return !1;
|
|
7028
7093
|
let t = Zn(e);
|
|
7029
7094
|
return !Gn.includes(t);
|
|
7030
|
-
},
|
|
7095
|
+
}, Vf = ({ value: e, unitkey: t, toUnit: n }) => {
|
|
7031
7096
|
var r;
|
|
7032
7097
|
let i = Wn[t];
|
|
7033
7098
|
if (!i || i.length === 0 || !((r = mr(e)) != null && r.valid) || !i.includes(n)) return !1;
|
|
7034
7099
|
let a = Zn(String(e));
|
|
7035
7100
|
return !(a && !i.includes(a));
|
|
7036
|
-
},
|
|
7101
|
+
}, Hf = ({ value: e, unitkey: t, toUnit: n, fromUnit: r, doNotConvertValue: i = !1, exactPrecision: a = !1 }) => {
|
|
7037
7102
|
var o;
|
|
7038
7103
|
let s = rr(e) ? $n(e) : e, c = [Infinity, -Infinity].includes(Number(s));
|
|
7039
7104
|
if (i || c) return {
|
|
@@ -7053,13 +7118,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7053
7118
|
value: void 0,
|
|
7054
7119
|
error: "Source unit is missing"
|
|
7055
7120
|
};
|
|
7056
|
-
if (
|
|
7121
|
+
if (zf(s)) return {
|
|
7057
7122
|
value: void 0,
|
|
7058
7123
|
error: "Value is invalid for conversion"
|
|
7059
7124
|
};
|
|
7060
7125
|
try {
|
|
7061
7126
|
let e = gr(s, l);
|
|
7062
|
-
if (
|
|
7127
|
+
if (Vf({
|
|
7063
7128
|
value: e,
|
|
7064
7129
|
toUnit: n,
|
|
7065
7130
|
unitkey: t
|
|
@@ -7080,13 +7145,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7080
7145
|
error: "Conversion not possible"
|
|
7081
7146
|
};
|
|
7082
7147
|
}
|
|
7083
|
-
},
|
|
7084
|
-
let a = $n(e), o =
|
|
7085
|
-
return !
|
|
7148
|
+
}, Uf = ({ value: e = "", toUnit: t, unitkey: n, defaultFromUnit: r, doNotConvertValue: i }) => {
|
|
7149
|
+
let a = $n(e), o = zf(a);
|
|
7150
|
+
return !Vf({
|
|
7086
7151
|
value: e,
|
|
7087
7152
|
unitkey: n,
|
|
7088
7153
|
toUnit: t
|
|
7089
|
-
}) ||
|
|
7154
|
+
}) || Bf(e) || o ? { value: a } : rr(e) ? Hf({
|
|
7090
7155
|
value: e,
|
|
7091
7156
|
unitkey: n,
|
|
7092
7157
|
toUnit: t,
|
|
@@ -7094,25 +7159,25 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7094
7159
|
doNotConvertValue: i,
|
|
7095
7160
|
exactPrecision: !0
|
|
7096
7161
|
}) : { value: e };
|
|
7097
|
-
},
|
|
7162
|
+
}, Wf = (e) => gn(e) && !cn(e) && !pn(e) ? sn(e, "fieldName", "") : typeof e == "string" ? e : "", Gf = (e = "") => Gn == null ? void 0 : Gn.includes(e), Kf = (e, t) => {
|
|
7098
7163
|
let n = Zn(e || "");
|
|
7099
|
-
return
|
|
7100
|
-
},
|
|
7101
|
-
|
|
7102
|
-
},
|
|
7164
|
+
return Gf(t) && Gf(n);
|
|
7165
|
+
}, qf = i(null), Jf = () => u(qf), Yf = !1, Xf = (e) => {
|
|
7166
|
+
Yf || (Yf = !0, qf = e);
|
|
7167
|
+
}, Zf = (e) => tr(e) ? e : ar(e), Qf = {
|
|
7103
7168
|
predefinedMenuActive: "_predefinedMenuActive_ye9w9_1",
|
|
7104
7169
|
inputWrapper: "_inputWrapper_ye9w9_4"
|
|
7105
|
-
},
|
|
7170
|
+
}, $f = ({ name: e, placeholder: t = "", disabled: n = !1, disabledUnit: r = !1, error: i = null, left: a = !1, small: o = !1, width: s = "100%", value: c, unitkey: l = "", initUnit: u, noConversion: f = !1, onChange: p = bn, onClick: m = bn, onFocus: g = bn, onSwitchUnit: _ = bn, unitTemplate: y, testId: w, warning: T = null, predefinedOptions: E, initialPredefinedOption: D = !1, shouldLinkAutomaticly: O = !0, selectedPredefinedOptionKey: k, validationCallback: A = () => ({
|
|
7106
7171
|
name: "",
|
|
7107
7172
|
error: null
|
|
7108
7173
|
}), disabledValidation: j = !1, allowEmpty: M = !1, convertBackToStorageUnit: N = !1, enableCosmeticRounding: P = !0, enableDisplayRounding: F = !1, roundDisplayValue: I, selectOnFocus: L = !0, groupOrder: R, tooltip: z = null }) => {
|
|
7109
|
-
let B =
|
|
7174
|
+
let B = Jf(), ee = Ff();
|
|
7110
7175
|
typeof c == "number" && (c = `${c}`);
|
|
7111
|
-
let [te = "", ne = ""] = c === void 0 ? [] : lr(c), V = h(() =>
|
|
7176
|
+
let [te = "", ne = ""] = c === void 0 ? [] : lr(c), V = h(() => Lf(l, y || (B == null ? void 0 : B.unitTemplate)), [
|
|
7112
7177
|
l,
|
|
7113
7178
|
y,
|
|
7114
7179
|
B == null ? void 0 : B.unitTemplate
|
|
7115
|
-
]), re =
|
|
7180
|
+
]), re = Kf(c, V), ie = u || V || ne, ae = If(ie), { value: oe } = Uf({
|
|
7116
7181
|
value: c,
|
|
7117
7182
|
toUnit: ie,
|
|
7118
7183
|
unitkey: l,
|
|
@@ -7124,10 +7189,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7124
7189
|
} : {
|
|
7125
7190
|
value: oe,
|
|
7126
7191
|
unit: ie
|
|
7127
|
-
}), le = M || (se == null ? void 0 : se.value) === void 0, [ue, de] = v(D ?
|
|
7192
|
+
}), le = M || (se == null ? void 0 : se.value) === void 0, [ue, de] = v(D ? Rf.PREDEFINED : Rf.CUSTOM), fe = !!(j || n), pe = E && E.find((e) => {
|
|
7128
7193
|
if (!(e != null && e.value)) return;
|
|
7129
7194
|
if (k) return k === e.valueKey;
|
|
7130
|
-
let t = rr(e.value) ? Zn(e.value) : "", { value: n = c } =
|
|
7195
|
+
let t = rr(e.value) ? Zn(e.value) : "", { value: n = c } = Hf({
|
|
7131
7196
|
value: String(c),
|
|
7132
7197
|
unitkey: l,
|
|
7133
7198
|
toUnit: t
|
|
@@ -7136,7 +7201,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7136
7201
|
}), me = () => {
|
|
7137
7202
|
var e;
|
|
7138
7203
|
let t = (e = c) == null ? "" : e, n = se.unit;
|
|
7139
|
-
if (!
|
|
7204
|
+
if (!Vf({
|
|
7140
7205
|
value: t,
|
|
7141
7206
|
unitkey: l,
|
|
7142
7207
|
toUnit: n
|
|
@@ -7151,7 +7216,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7151
7216
|
return null;
|
|
7152
7217
|
}
|
|
7153
7218
|
}, he = (t) => {
|
|
7154
|
-
let n =
|
|
7219
|
+
let n = Wf(e), r = t.target, { value: i, selectionStart: a } = r, o = gr(i, (se == null ? void 0 : se.unit) || "");
|
|
7155
7220
|
p({ target: {
|
|
7156
7221
|
value: N ? gr(Jn(o, ne), ne) : o,
|
|
7157
7222
|
name: n
|
|
@@ -7173,7 +7238,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7173
7238
|
let e, t = "";
|
|
7174
7239
|
if (ie) {
|
|
7175
7240
|
if (ae !== ie) {
|
|
7176
|
-
let { value: n } =
|
|
7241
|
+
let { value: n } = Uf({
|
|
7177
7242
|
value: c,
|
|
7178
7243
|
toUnit: ie,
|
|
7179
7244
|
unitkey: l,
|
|
@@ -7182,7 +7247,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7182
7247
|
});
|
|
7183
7248
|
e = n, t = ie;
|
|
7184
7249
|
} else if (gr(se.value, se.unit) !== c) {
|
|
7185
|
-
let { value: n } =
|
|
7250
|
+
let { value: n } = Uf({
|
|
7186
7251
|
value: c,
|
|
7187
7252
|
toUnit: se.unit,
|
|
7188
7253
|
unitkey: l,
|
|
@@ -7195,21 +7260,21 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7195
7260
|
e !== void 0 && ce({
|
|
7196
7261
|
value: e,
|
|
7197
7262
|
unit: t
|
|
7198
|
-
}), de(E && pe && O ?
|
|
7263
|
+
}), de(E && pe && O ? Rf.PREDEFINED : Rf.CUSTOM);
|
|
7199
7264
|
}, [
|
|
7200
7265
|
ie,
|
|
7201
7266
|
c,
|
|
7202
7267
|
i,
|
|
7203
7268
|
O
|
|
7204
7269
|
]);
|
|
7205
|
-
let _e = me(), ve = ir(se.unit) || se.unit || "", ye = f || !_e || _e && _e.length === 1, be =
|
|
7270
|
+
let _e = me(), ve = ir(se.unit) || se.unit || "", ye = f || !_e || _e && _e.length === 1, be = Wf(e), xe, Se = (t) => {
|
|
7206
7271
|
let r = t != null && t.value ? t.value : "", [i = "", a = ""] = rr(r) ? lr(r) : [r], o = hr(r);
|
|
7207
|
-
if (
|
|
7272
|
+
if (Vf({
|
|
7208
7273
|
value: r,
|
|
7209
7274
|
unitkey: l,
|
|
7210
7275
|
toUnit: a
|
|
7211
7276
|
})) {
|
|
7212
|
-
let { value: e = "" } =
|
|
7277
|
+
let { value: e = "" } = Uf({
|
|
7213
7278
|
value: r,
|
|
7214
7279
|
toUnit: V,
|
|
7215
7280
|
unitkey: l,
|
|
@@ -7222,7 +7287,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7222
7287
|
type: Va.OPTION,
|
|
7223
7288
|
inline: !0,
|
|
7224
7289
|
onClick: () => {
|
|
7225
|
-
mr(i).valid && !n && (de(
|
|
7290
|
+
mr(i).valid && !n && (de(Rf.PREDEFINED), p({ target: {
|
|
7226
7291
|
value: r,
|
|
7227
7292
|
name: typeof e == "string" ? e : (e == null ? void 0 : e.fieldName) || "",
|
|
7228
7293
|
predefinedSelected: !0,
|
|
@@ -7234,27 +7299,27 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7234
7299
|
height: "0"
|
|
7235
7300
|
})] }),
|
|
7236
7301
|
description: o,
|
|
7237
|
-
selected: pe === t && ue ===
|
|
7302
|
+
selected: pe === t && ue === Rf.PREDEFINED
|
|
7238
7303
|
};
|
|
7239
7304
|
};
|
|
7240
7305
|
if (xe = [{
|
|
7241
7306
|
type: Va.OPTION,
|
|
7242
7307
|
inline: !0,
|
|
7243
7308
|
onClick: () => {
|
|
7244
|
-
ue !==
|
|
7309
|
+
ue !== Rf.CUSTOM && !n && p({ target: {
|
|
7245
7310
|
value: gr(se.value, se.unit),
|
|
7246
7311
|
name: typeof e == "string" ? e : (e == null ? void 0 : e.fieldName) || ""
|
|
7247
7312
|
} });
|
|
7248
7313
|
},
|
|
7249
7314
|
label: "Custom",
|
|
7250
|
-
selected: ue ===
|
|
7315
|
+
selected: ue === Rf.CUSTOM
|
|
7251
7316
|
}], E != null && E.length) {
|
|
7252
7317
|
let e = E.map(Se);
|
|
7253
7318
|
xe = [...xe, ...e];
|
|
7254
7319
|
}
|
|
7255
7320
|
let Ce = (e) => {
|
|
7256
7321
|
if (rr(e)) {
|
|
7257
|
-
let t = Zn(e), { value: n } =
|
|
7322
|
+
let t = Zn(e), { value: n } = Uf({
|
|
7258
7323
|
value: e,
|
|
7259
7324
|
toUnit: se.unit,
|
|
7260
7325
|
unitkey: l,
|
|
@@ -7266,7 +7331,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7266
7331
|
return e;
|
|
7267
7332
|
}, we = !E && (!R || R === H.FIRST) ? H.FIRST : H.MIDDLE, Te = !R || R === H.LAST ? H.LAST : H.MIDDLE;
|
|
7268
7333
|
return /* @__PURE__ */ S("div", {
|
|
7269
|
-
className: ue ===
|
|
7334
|
+
className: ue === Rf.PREDEFINED ? b(Qf.predefinedMenuActive) : "",
|
|
7270
7335
|
children: /* @__PURE__ */ C(ls, {
|
|
7271
7336
|
small: o,
|
|
7272
7337
|
width: s,
|
|
@@ -7281,17 +7346,17 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7281
7346
|
trigger: "Component",
|
|
7282
7347
|
component: /* @__PURE__ */ S(q, {
|
|
7283
7348
|
groupOrder: "first",
|
|
7284
|
-
active: ue ===
|
|
7285
|
-
icon: ue ===
|
|
7349
|
+
active: ue === Rf.PREDEFINED,
|
|
7350
|
+
icon: ue === Rf.PREDEFINED ? "link" : "unlink",
|
|
7286
7351
|
small: o
|
|
7287
7352
|
}),
|
|
7288
7353
|
small: o,
|
|
7289
7354
|
sections: xe
|
|
7290
7355
|
},
|
|
7291
|
-
tooltip: ue ===
|
|
7356
|
+
tooltip: ue === Rf.PREDEFINED ? pe == null ? void 0 : pe.label : ""
|
|
7292
7357
|
}),
|
|
7293
7358
|
/* @__PURE__ */ S("div", {
|
|
7294
|
-
className:
|
|
7359
|
+
className: Qf.inputWrapper,
|
|
7295
7360
|
children: /* @__PURE__ */ S(vl, {
|
|
7296
7361
|
name: be,
|
|
7297
7362
|
testId: w,
|
|
@@ -7333,7 +7398,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7333
7398
|
let r = n || t || "", i = nr(e) ? e : "";
|
|
7334
7399
|
return {
|
|
7335
7400
|
type: "Option",
|
|
7336
|
-
label: P ?
|
|
7401
|
+
label: P ? Zf(i) : i,
|
|
7337
7402
|
inline: !0,
|
|
7338
7403
|
onClick: (n) => {
|
|
7339
7404
|
n.stopPropagation(), ge(e, t);
|
|
@@ -7348,10 +7413,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7348
7413
|
]
|
|
7349
7414
|
})
|
|
7350
7415
|
});
|
|
7351
|
-
},
|
|
7416
|
+
}, ep = (e, t) => ({ target: {
|
|
7352
7417
|
name: e,
|
|
7353
7418
|
value: t
|
|
7354
|
-
} }),
|
|
7419
|
+
} }), tp = (e) => `Value cannot be less than ${e}`, np = (e) => `Value cannot be greater than ${e}`, rp = ({ name: e = "", value: t, min: n, max: r, label: i, step: a = .01, onChange: o, onChangeComplete: s, preferredUnit: c = "m", onSwitchUnit: l, enableEditUnitInput: u = !1, disabled: f = !1, showUnitInput: p = !0, showArrows: m = !0, unitkey: h = "length", testId: g, noConversion: _ = !1, small: y = !1, marks: x, minErrorMessage: w = tp, maxErrorMessage: T = np }) => {
|
|
7355
7420
|
let E = gr(t, c), [D, O] = v(E), [k, A] = v(!1), [j, M] = v(c);
|
|
7356
7421
|
d(() => {
|
|
7357
7422
|
k || O(E);
|
|
@@ -7369,7 +7434,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7369
7434
|
}, z = () => {
|
|
7370
7435
|
O(E), A(!1);
|
|
7371
7436
|
}, B = () => {
|
|
7372
|
-
L || I === null || (o(
|
|
7437
|
+
L || I === null || (o(ep(e, I)), s == null || s(ep(e, I)), A(!1));
|
|
7373
7438
|
}, ee = (e) => {
|
|
7374
7439
|
M(e), l == null || l(e);
|
|
7375
7440
|
}, te = (e) => {
|
|
@@ -7384,7 +7449,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7384
7449
|
}, ne = (e) => {
|
|
7385
7450
|
e.key === "Enter" && B(), e.key === "Escape" && z();
|
|
7386
7451
|
}, V = f || k, re = /* @__PURE__ */ C("div", {
|
|
7387
|
-
className:
|
|
7452
|
+
className: Pf.actions,
|
|
7388
7453
|
children: [/* @__PURE__ */ S(q, {
|
|
7389
7454
|
icon: "close",
|
|
7390
7455
|
small: !0,
|
|
@@ -7399,18 +7464,18 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7399
7464
|
})]
|
|
7400
7465
|
});
|
|
7401
7466
|
return /* @__PURE__ */ C("div", {
|
|
7402
|
-
className:
|
|
7467
|
+
className: Pf.wrapper,
|
|
7403
7468
|
"data-testid": g && `${g}-wrapper`,
|
|
7404
7469
|
children: [
|
|
7405
7470
|
i && /* @__PURE__ */ S("span", {
|
|
7406
|
-
className:
|
|
7471
|
+
className: Pf.label,
|
|
7407
7472
|
children: /* @__PURE__ */ S(Go, {
|
|
7408
7473
|
small: y,
|
|
7409
7474
|
children: i
|
|
7410
7475
|
})
|
|
7411
7476
|
}),
|
|
7412
7477
|
p && /* @__PURE__ */ S("div", {
|
|
7413
|
-
className: b(
|
|
7478
|
+
className: b(Pf.input, y && Pf.inputSmall, u && !f && Pf.editable),
|
|
7414
7479
|
children: /* @__PURE__ */ S(vo, {
|
|
7415
7480
|
content: re,
|
|
7416
7481
|
isOpen: k,
|
|
@@ -7424,11 +7489,11 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7424
7489
|
testId: g && `${g}-edit-popover`,
|
|
7425
7490
|
toggleOnTriggerClick: !1,
|
|
7426
7491
|
children: /* @__PURE__ */ S("div", {
|
|
7427
|
-
className:
|
|
7492
|
+
className: Pf.inputControl,
|
|
7428
7493
|
"data-testid": g && `${g}-edit-trigger`,
|
|
7429
7494
|
onClick: R,
|
|
7430
7495
|
onKeyDown: ne,
|
|
7431
|
-
children: /* @__PURE__ */ S(
|
|
7496
|
+
children: /* @__PURE__ */ S($f, {
|
|
7432
7497
|
name: e,
|
|
7433
7498
|
value: k ? D : E,
|
|
7434
7499
|
unitkey: h,
|
|
@@ -7463,7 +7528,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7463
7528
|
})
|
|
7464
7529
|
]
|
|
7465
7530
|
});
|
|
7466
|
-
},
|
|
7531
|
+
}, ip = ({ label: e, invalid: t, badge: n }) => t ? /* @__PURE__ */ S(Qa, {
|
|
7467
7532
|
small: !0,
|
|
7468
7533
|
margin: "-4px",
|
|
7469
7534
|
color: "var(--color-text-error)",
|
|
@@ -7474,7 +7539,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7474
7539
|
margin: "-4px",
|
|
7475
7540
|
title: n == null ? void 0 : n.toString(),
|
|
7476
7541
|
children: e
|
|
7477
|
-
}) : /* @__PURE__ */ S(x, { children: e }),
|
|
7542
|
+
}) : /* @__PURE__ */ S(x, { children: e }), ap = {
|
|
7478
7543
|
tabs: "_tabs_1olt8_1",
|
|
7479
7544
|
padding: "_padding_1olt8_7",
|
|
7480
7545
|
margin: "_margin_1olt8_11",
|
|
@@ -7484,7 +7549,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7484
7549
|
left: "_left_1olt8_67",
|
|
7485
7550
|
right: "_right_1olt8_67",
|
|
7486
7551
|
selectionIndicator: "_selectionIndicator_1olt8_70"
|
|
7487
|
-
},
|
|
7552
|
+
}, op = ({ name: e = void 0, options: t = null, value: n = void 0, onChange: r = bn, padding: i = !1, margin: a = !0, small: o = !1, testId: s, linkComponent: c }) => {
|
|
7488
7553
|
let l = u(W), { simpleInputs: d, options: f, selectedOptions: p } = Xc(t, n), m = mn(p) ? void 0 : d ? p : p.value, h = (e) => {
|
|
7489
7554
|
var t;
|
|
7490
7555
|
return (t = e.component) == null ? c : t;
|
|
@@ -7510,7 +7575,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7510
7575
|
...m ? { href: m } : {},
|
|
7511
7576
|
shouldSelectOnPressUp: !0,
|
|
7512
7577
|
isDisabled: i || l,
|
|
7513
|
-
className: b(
|
|
7578
|
+
className: b(ap.item, s ? ap.right : ap.left, o ? ap.small : ""),
|
|
7514
7579
|
"data-testid": d,
|
|
7515
7580
|
render: f && p ? (e) => "href" in e ? /* @__PURE__ */ S(p, {
|
|
7516
7581
|
...e,
|
|
@@ -7520,11 +7585,11 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7520
7585
|
(n = e.onClick) == null || n.call(e, t), y(t, a);
|
|
7521
7586
|
}
|
|
7522
7587
|
}) : /* @__PURE__ */ S("div", { ...e }) : void 0,
|
|
7523
|
-
children: [/* @__PURE__ */ S(
|
|
7588
|
+
children: [/* @__PURE__ */ S(ip, {
|
|
7524
7589
|
label: t,
|
|
7525
7590
|
invalid: c,
|
|
7526
7591
|
badge: u
|
|
7527
|
-
}), /* @__PURE__ */ S(vi, { className:
|
|
7592
|
+
}), /* @__PURE__ */ S(vi, { className: ap.selectionIndicator })]
|
|
7528
7593
|
}, a);
|
|
7529
7594
|
};
|
|
7530
7595
|
if (f) {
|
|
@@ -7534,7 +7599,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7534
7599
|
"data-testid": s,
|
|
7535
7600
|
children: /* @__PURE__ */ S(bi, {
|
|
7536
7601
|
"aria-label": e == null ? "Tabs" : e,
|
|
7537
|
-
className: b(
|
|
7602
|
+
className: b(ap.tabs, i ? ap.padding : "", a ? ap.margin : ""),
|
|
7538
7603
|
children: x.map(T)
|
|
7539
7604
|
})
|
|
7540
7605
|
});
|
|
@@ -7544,7 +7609,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7544
7609
|
}) : t;
|
|
7545
7610
|
}
|
|
7546
7611
|
return null;
|
|
7547
|
-
},
|
|
7612
|
+
}, sp = ({ children: e, href: t = void 0, target: n = void 0, testId: r, onClick: i, component: a = "a" }) => /* @__PURE__ */ S(a, {
|
|
7548
7613
|
href: t,
|
|
7549
7614
|
to: t,
|
|
7550
7615
|
target: n,
|
|
@@ -7554,7 +7619,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7554
7619
|
link: !0,
|
|
7555
7620
|
children: e
|
|
7556
7621
|
})
|
|
7557
|
-
}),
|
|
7622
|
+
}), cp = {
|
|
7558
7623
|
inputInTable: "_inputInTable_qbe2o_1",
|
|
7559
7624
|
inputHover: "_inputHover_qbe2o_13",
|
|
7560
7625
|
inputFocus: "_inputFocus_qbe2o_18",
|
|
@@ -7566,9 +7631,9 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7566
7631
|
textarea: "_textarea_qbe2o_81",
|
|
7567
7632
|
small: "_small_qbe2o_120",
|
|
7568
7633
|
monospace: "_monospace_qbe2o_159"
|
|
7569
|
-
},
|
|
7634
|
+
}, lp = ({ name: e, value: t = "", placeholder: n = "", cols: r, rows: i, disabled: a = !1, onChange: o = bn, onKeyPress: s = bn, onFocus: c = bn, onBlur: l = bn, tabIndex: d = 0, error: f = null, warning: p = null, tooltip: m = null, maxTooltipWidth: h, resize: g, monospace: _ = !1, small: v = !1, testId: y }) => {
|
|
7570
7635
|
let x = u(W), C = /* @__PURE__ */ S("textarea", {
|
|
7571
|
-
className: b(
|
|
7636
|
+
className: b(cp.textarea, f ? cp.error : "", p ? cp.warning : "", _ ? cp.monospace : "", v ? cp.small : ""),
|
|
7572
7637
|
name: e,
|
|
7573
7638
|
value: t,
|
|
7574
7639
|
placeholder: n,
|
|
@@ -7610,10 +7675,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7610
7675
|
menu: "_menu_oyr59_139",
|
|
7611
7676
|
active: "_active_oyr59_168",
|
|
7612
7677
|
alert: "_alert_oyr59_193"
|
|
7613
|
-
},
|
|
7678
|
+
}, up = ({ warning: e }) => /* @__PURE__ */ S("div", {
|
|
7614
7679
|
className: Q.alert,
|
|
7615
7680
|
children: e
|
|
7616
|
-
}),
|
|
7681
|
+
}), dp = ({ icon: e, url: t, onClick: n }) => {
|
|
7617
7682
|
let r = /* @__PURE__ */ S(G, { icon: e });
|
|
7618
7683
|
return t ? /* @__PURE__ */ S("a", {
|
|
7619
7684
|
href: t,
|
|
@@ -7625,7 +7690,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7625
7690
|
className: Q.appSwitcher,
|
|
7626
7691
|
children: r
|
|
7627
7692
|
});
|
|
7628
|
-
},
|
|
7693
|
+
}, fp = ({ label: e, logo: t, url: n, version: r, onClick: i }) => {
|
|
7629
7694
|
let a = /* @__PURE__ */ C("div", {
|
|
7630
7695
|
className: Q.title,
|
|
7631
7696
|
children: [
|
|
@@ -7654,9 +7719,9 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7654
7719
|
children: a
|
|
7655
7720
|
})
|
|
7656
7721
|
});
|
|
7657
|
-
},
|
|
7722
|
+
}, pp = /* @__PURE__ */ function(e) {
|
|
7658
7723
|
return e.LINK = "Link", e.BUTTON = "Button", e.MENU = "Menu", e.COMPONENT = "Component", e;
|
|
7659
|
-
}({}),
|
|
7724
|
+
}({}), mp = ({ label: e, url: t, icon: n, onClick: r, active: i, disabled: a, testId: o, component: s = "a" }) => {
|
|
7660
7725
|
let c = u(W);
|
|
7661
7726
|
return /* @__PURE__ */ C(s, {
|
|
7662
7727
|
className: b(Q.link, i ? Q.active : ""),
|
|
@@ -7673,11 +7738,11 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7673
7738
|
children: e
|
|
7674
7739
|
})]
|
|
7675
7740
|
});
|
|
7676
|
-
},
|
|
7741
|
+
}, hp = ({ element: e }) => {
|
|
7677
7742
|
switch (e.type) {
|
|
7678
|
-
case
|
|
7743
|
+
case pp.LINK: return /* @__PURE__ */ S("div", {
|
|
7679
7744
|
className: Q.item,
|
|
7680
|
-
children: /* @__PURE__ */ S(
|
|
7745
|
+
children: /* @__PURE__ */ S(mp, {
|
|
7681
7746
|
label: e.label,
|
|
7682
7747
|
url: e.url,
|
|
7683
7748
|
icon: e.icon,
|
|
@@ -7688,7 +7753,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7688
7753
|
component: e.component
|
|
7689
7754
|
})
|
|
7690
7755
|
});
|
|
7691
|
-
case
|
|
7756
|
+
case pp.BUTTON: return /* @__PURE__ */ S("div", {
|
|
7692
7757
|
className: b(Q.item, Q.button),
|
|
7693
7758
|
children: /* @__PURE__ */ S(q, {
|
|
7694
7759
|
label: e.label,
|
|
@@ -7700,14 +7765,14 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7700
7765
|
testId: e.testId
|
|
7701
7766
|
})
|
|
7702
7767
|
});
|
|
7703
|
-
case
|
|
7768
|
+
case pp.MENU: return /* @__PURE__ */ S("div", {
|
|
7704
7769
|
className: b(Q.item, Q.menu),
|
|
7705
7770
|
children: /* @__PURE__ */ S(ao, {
|
|
7706
7771
|
maxHeight: "100%",
|
|
7707
7772
|
menu: {
|
|
7708
7773
|
trigger: ki.COMPONENT,
|
|
7709
7774
|
placement: "bottom-start",
|
|
7710
|
-
component: /* @__PURE__ */ S(
|
|
7775
|
+
component: /* @__PURE__ */ S(mp, {
|
|
7711
7776
|
label: e.label,
|
|
7712
7777
|
icon: e.icon,
|
|
7713
7778
|
onClick: e.onClick
|
|
@@ -7716,50 +7781,50 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7716
7781
|
}
|
|
7717
7782
|
})
|
|
7718
7783
|
});
|
|
7719
|
-
case
|
|
7784
|
+
case pp.COMPONENT: return /* @__PURE__ */ S("div", {
|
|
7720
7785
|
className: Q.item,
|
|
7721
7786
|
children: e.component
|
|
7722
7787
|
});
|
|
7723
7788
|
default: return null;
|
|
7724
7789
|
}
|
|
7725
|
-
},
|
|
7790
|
+
}, gp = ({ title: e, appSwitcher: t, content: n = [], contentRight: r = [], warning: i = "", height: a = "var(--size-topbar)", fixedPosition: o = !0 }) => /* @__PURE__ */ C("div", { children: [i && /* @__PURE__ */ S(up, { warning: i }), /* @__PURE__ */ C("div", {
|
|
7726
7791
|
className: b(Q.topbar, o ? Q.fixed : ""),
|
|
7727
7792
|
style: { height: a },
|
|
7728
7793
|
children: [
|
|
7729
|
-
!!t && /* @__PURE__ */ S(
|
|
7794
|
+
!!t && /* @__PURE__ */ S(dp, {
|
|
7730
7795
|
icon: t.icon,
|
|
7731
7796
|
url: t.url,
|
|
7732
7797
|
onClick: t.onClick
|
|
7733
7798
|
}),
|
|
7734
7799
|
/* @__PURE__ */ C("div", {
|
|
7735
7800
|
className: Q.left,
|
|
7736
|
-
children: [e && /* @__PURE__ */ S(
|
|
7801
|
+
children: [e && /* @__PURE__ */ S(fp, {
|
|
7737
7802
|
label: e.label,
|
|
7738
7803
|
logo: e.logo,
|
|
7739
7804
|
url: e.url,
|
|
7740
7805
|
version: e.version,
|
|
7741
7806
|
onClick: e.onClick
|
|
7742
|
-
}), n.map((e, t) => e ? /* @__PURE__ */ S(
|
|
7807
|
+
}), n.map((e, t) => e ? /* @__PURE__ */ S(hp, { element: e }, t) : null)]
|
|
7743
7808
|
}),
|
|
7744
7809
|
/* @__PURE__ */ S("div", {
|
|
7745
7810
|
className: Q.right,
|
|
7746
|
-
children: r.map((e, t) => e ? /* @__PURE__ */ S(
|
|
7811
|
+
children: r.map((e, t) => e ? /* @__PURE__ */ S(hp, { element: e }, t) : null)
|
|
7747
7812
|
})
|
|
7748
7813
|
]
|
|
7749
|
-
})] }),
|
|
7814
|
+
})] }), _p = {
|
|
7750
7815
|
popConfirm: "_popConfirm_1x6ye_1",
|
|
7751
7816
|
content: "_content_1x6ye_7",
|
|
7752
7817
|
buttons: "_buttons_1x6ye_13"
|
|
7753
|
-
},
|
|
7754
|
-
className:
|
|
7818
|
+
}, vp = ({ title: e, okText: t, onClickOk: n, disableConfirmButton: r, cancelText: i, onClickCancel: a, close: o, testId: s }) => /* @__PURE__ */ C("div", {
|
|
7819
|
+
className: _p.popConfirm,
|
|
7755
7820
|
children: [e && /* @__PURE__ */ S("div", {
|
|
7756
|
-
className:
|
|
7821
|
+
className: _p.content,
|
|
7757
7822
|
children: /* @__PURE__ */ S(Go, {
|
|
7758
7823
|
small: !0,
|
|
7759
7824
|
children: e
|
|
7760
7825
|
})
|
|
7761
7826
|
}), /* @__PURE__ */ C("div", {
|
|
7762
|
-
className:
|
|
7827
|
+
className: _p.buttons,
|
|
7763
7828
|
children: [/* @__PURE__ */ S(q, {
|
|
7764
7829
|
small: !0,
|
|
7765
7830
|
colored: !0,
|
|
@@ -7774,8 +7839,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7774
7839
|
testId: `${s}-cancel-button`
|
|
7775
7840
|
})]
|
|
7776
7841
|
})]
|
|
7777
|
-
}),
|
|
7778
|
-
content: /* @__PURE__ */ S(
|
|
7842
|
+
}), yp = ({ children: e, placement: t = "top-center", closeOnOutsideClick: n = !0, fullWidth: r = !1, title: i = "", cancelText: a = "Cancel", onClickCancel: o = (e) => e && e(), okText: s = "Ok", onClickOk: c = () => {}, disableConfirmButton: l = !1, testId: u = void 0 }) => /* @__PURE__ */ S(vo, {
|
|
7843
|
+
content: /* @__PURE__ */ S(vp, {
|
|
7779
7844
|
title: i,
|
|
7780
7845
|
okText: s,
|
|
7781
7846
|
onClickOk: c,
|
|
@@ -7789,14 +7854,14 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7789
7854
|
fullWidth: r,
|
|
7790
7855
|
testId: u,
|
|
7791
7856
|
children: e
|
|
7792
|
-
}),
|
|
7857
|
+
}), bp = {
|
|
7793
7858
|
tree: "_tree_coxxe_1",
|
|
7794
7859
|
toggle: "_toggle_coxxe_8",
|
|
7795
7860
|
dropTarget: "_dropTarget_coxxe_15",
|
|
7796
7861
|
placeholder: "_placeholder_coxxe_30",
|
|
7797
7862
|
draggingSource: "_draggingSource_coxxe_36",
|
|
7798
7863
|
placeholderContainer: "_placeholderContainer_coxxe_39"
|
|
7799
|
-
},
|
|
7864
|
+
}, xp = ({ node: t, depth: n, isOpen: r, onToggle: i, hasChild: a, draggable: o, icons: s, onDrop: c }) => {
|
|
7800
7865
|
let { id: l, data: u } = t, { active: d, disabled: f, testId: p, onClick: m, actions: h = [] } = u, [g, _] = e.useState(!1), [v, y] = e.useState(0), x = (e) => {
|
|
7801
7866
|
e.stopPropagation(), i(l);
|
|
7802
7867
|
}, w = (e) => {
|
|
@@ -7823,7 +7888,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7823
7888
|
className: b(Z.itemHeader, g ? Z.noPointerEvents : ""),
|
|
7824
7889
|
children: [
|
|
7825
7890
|
a && /* @__PURE__ */ S("div", {
|
|
7826
|
-
className:
|
|
7891
|
+
className: bp.toggle,
|
|
7827
7892
|
children: /* @__PURE__ */ S(q, {
|
|
7828
7893
|
basic: !0,
|
|
7829
7894
|
colored: r ? !0 : Ai.MUTED,
|
|
@@ -7848,13 +7913,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7848
7913
|
]
|
|
7849
7914
|
})
|
|
7850
7915
|
});
|
|
7851
|
-
},
|
|
7852
|
-
className:
|
|
7916
|
+
}, Sp = ({ depth: e, indent: t = "var(--size-sm)" }) => /* @__PURE__ */ S("div", {
|
|
7917
|
+
className: bp.placeholder,
|
|
7853
7918
|
style: { left: `calc(${t} * ${e})` }
|
|
7854
|
-
}),
|
|
7919
|
+
}), Cp = (e, t) => {
|
|
7855
7920
|
var n;
|
|
7856
7921
|
return e && (t == null || (n = t.data) == null ? void 0 : n.draggable) !== !1;
|
|
7857
|
-
},
|
|
7922
|
+
}, wp = ({ list: e, canDrop: t, draggable: n = !1, onListReorder: r, onChangeOpen: i, testId: a, isInitialOpen: o = !1, autoOpenActiveItems: s = !1, treeRef: c, itemHasChild: l, onItemToggle: u, icons: f, allowParentReassignment: p, stickyHeader: m, height: h, render: g, placeholderIndent: v }) => {
|
|
7858
7923
|
var y, b;
|
|
7859
7924
|
let x = c == null ? _(null) : c, w = (e) => {
|
|
7860
7925
|
i && i(e);
|
|
@@ -7935,7 +8000,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7935
8000
|
tree: N,
|
|
7936
8001
|
sort: !1,
|
|
7937
8002
|
insertDroppableFirst: !1,
|
|
7938
|
-
canDrag: (e) =>
|
|
8003
|
+
canDrag: (e) => Cp(n, e),
|
|
7939
8004
|
canDrop: t || ((e, { dragSource: t, dropTargetId: n }) => {
|
|
7940
8005
|
if ((t == null ? void 0 : t.parent) === n) return !0;
|
|
7941
8006
|
}),
|
|
@@ -7949,7 +8014,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7949
8014
|
hasChild: n,
|
|
7950
8015
|
isOpen: i,
|
|
7951
8016
|
onToggle: a
|
|
7952
|
-
}) : /* @__PURE__ */ S(
|
|
8017
|
+
}) : /* @__PURE__ */ S(xp, {
|
|
7953
8018
|
hasChild: l ? l(e) : n,
|
|
7954
8019
|
node: e,
|
|
7955
8020
|
depth: t,
|
|
@@ -7965,7 +8030,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7965
8030
|
onDrop: M,
|
|
7966
8031
|
onChangeOpen: w,
|
|
7967
8032
|
dropTargetOffset: 10,
|
|
7968
|
-
placeholderRender: (e, { depth: t }) => /* @__PURE__ */ S(
|
|
8033
|
+
placeholderRender: (e, { depth: t }) => /* @__PURE__ */ S(Sp, {
|
|
7969
8034
|
depth: t,
|
|
7970
8035
|
indent: v
|
|
7971
8036
|
}),
|
|
@@ -7973,17 +8038,17 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7973
8038
|
listComponent: "div",
|
|
7974
8039
|
listItemComponent: "div",
|
|
7975
8040
|
classes: {
|
|
7976
|
-
root:
|
|
7977
|
-
draggingSource:
|
|
7978
|
-
dropTarget:
|
|
7979
|
-
placeholder:
|
|
8041
|
+
root: bp.tree,
|
|
8042
|
+
draggingSource: bp.draggingSource,
|
|
8043
|
+
dropTarget: bp.dropTarget,
|
|
8044
|
+
placeholder: bp.placeholderContainer
|
|
7980
8045
|
},
|
|
7981
8046
|
initialOpen: o,
|
|
7982
8047
|
enableAnimateExpand: !0
|
|
7983
8048
|
})
|
|
7984
8049
|
})]
|
|
7985
8050
|
});
|
|
7986
|
-
},
|
|
8051
|
+
}, Tp = {
|
|
7987
8052
|
treeTable: "_treeTable_1ywvy_1",
|
|
7988
8053
|
treeTableHeader: "_treeTableHeader_1ywvy_22",
|
|
7989
8054
|
folderCell: "_folderCell_1ywvy_30",
|
|
@@ -7991,48 +8056,48 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7991
8056
|
drag: "_drag_1ywvy_31",
|
|
7992
8057
|
folder: "_folder_1ywvy_30",
|
|
7993
8058
|
active: "_active_1ywvy_61"
|
|
7994
|
-
},
|
|
8059
|
+
}, Ep = (e, t) => e.filter((e) => e.parent === t).flatMap((t) => [t.id, ...Ep(e, t.id)]), Dp = (e, t) => {
|
|
7995
8060
|
let n = new Set(t);
|
|
7996
8061
|
return e.filter((e) => !n.has(e.id)).map((e) => e.id);
|
|
7997
|
-
},
|
|
8062
|
+
}, Op = (e, t, n) => e.filter((e) => n.has(e) || !t.has(e)), kp = (e, t, n, r = []) => {
|
|
7998
8063
|
let i = new Set(n), a = new Set(r), o = e.filter((e) => e.parent === t && !a.has(e.id));
|
|
7999
8064
|
if (o.length === 0) return {
|
|
8000
8065
|
checked: i.has(t),
|
|
8001
8066
|
indeterminate: !1
|
|
8002
8067
|
};
|
|
8003
|
-
let s = o.map((t) =>
|
|
8068
|
+
let s = o.map((t) => kp(e, t.id, n, r)), c = s.filter((e) => e.checked).length, l = s.filter((e) => e.indeterminate).length, u = c === o.length;
|
|
8004
8069
|
return {
|
|
8005
8070
|
checked: u,
|
|
8006
8071
|
indeterminate: c + l > 0 && !u
|
|
8007
8072
|
};
|
|
8008
|
-
},
|
|
8009
|
-
let r =
|
|
8073
|
+
}, Ap = (e, t, n = []) => {
|
|
8074
|
+
let r = Dp(e, n), i = new Set(t), a = r.filter((e) => i.has(e)).length;
|
|
8010
8075
|
return {
|
|
8011
8076
|
checked: r.length > 0 && a === r.length,
|
|
8012
8077
|
indeterminate: a > 0 && a < r.length
|
|
8013
8078
|
};
|
|
8014
|
-
},
|
|
8079
|
+
}, jp = i(null), Mp = () => u(jp), Np = ({ children: e, rowCheckboxes: t, rows: n }) => {
|
|
8015
8080
|
let r = t !== void 0, { checkedIds: i = [], disabledIds: a = [], getTooltip: o, onChange: s } = t == null ? {} : t, c = h(() => new Set(a), [a]), u = h(() => {
|
|
8016
8081
|
if (!r) return null;
|
|
8017
8082
|
let e = /* @__PURE__ */ new Map();
|
|
8018
|
-
for (let t of n) e.set(t.id,
|
|
8083
|
+
for (let t of n) e.set(t.id, kp(n, t.id, i, a));
|
|
8019
8084
|
return e;
|
|
8020
8085
|
}, [
|
|
8021
8086
|
i,
|
|
8022
8087
|
a,
|
|
8023
8088
|
r,
|
|
8024
8089
|
n
|
|
8025
|
-
]), d = h(() => r ?
|
|
8090
|
+
]), d = h(() => r ? Ap(n, i, a) : void 0, [
|
|
8026
8091
|
i,
|
|
8027
8092
|
a,
|
|
8028
8093
|
r,
|
|
8029
8094
|
n
|
|
8030
8095
|
]), f = l((e) => u == null ? void 0 : u.get(e), [u]), p = l((e) => c.has(e), [c]), m = l((e) => o == null ? void 0 : o(e), [o]), g = l((e) => {
|
|
8031
8096
|
if (!r || c.has(e)) return;
|
|
8032
|
-
let t =
|
|
8097
|
+
let t = Ep(n, e), o = [e, ...t.filter((e) => !c.has(e))], l = [e, ...t], { checked: u } = kp(n, e, i, a);
|
|
8033
8098
|
if (u) {
|
|
8034
8099
|
let e = new Set(l);
|
|
8035
|
-
s == null || s(
|
|
8100
|
+
s == null || s(Op(i, e, c));
|
|
8036
8101
|
} else s == null || s([.../* @__PURE__ */ new Set([...i, ...o])]);
|
|
8037
8102
|
}, [
|
|
8038
8103
|
i,
|
|
@@ -8043,7 +8108,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8043
8108
|
n
|
|
8044
8109
|
]), _ = l(() => {
|
|
8045
8110
|
if (!r) return;
|
|
8046
|
-
let e =
|
|
8111
|
+
let e = Dp(n, a), { checked: t } = Ap(n, i, a);
|
|
8047
8112
|
t ? s == null || s(i.filter((e) => c.has(e))) : s == null || s([.../* @__PURE__ */ new Set([...i, ...e])]);
|
|
8048
8113
|
}, [
|
|
8049
8114
|
i,
|
|
@@ -8069,12 +8134,12 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8069
8134
|
_,
|
|
8070
8135
|
g
|
|
8071
8136
|
]);
|
|
8072
|
-
return /* @__PURE__ */ S(
|
|
8137
|
+
return /* @__PURE__ */ S(jp.Provider, {
|
|
8073
8138
|
value: v,
|
|
8074
8139
|
children: e
|
|
8075
8140
|
});
|
|
8076
|
-
},
|
|
8077
|
-
let g =
|
|
8141
|
+
}, Pp = ({ columnAlignment: e, columnWidths: t, depth: n, draggable: r, handleRef: i, hasChild: a, hasRowActions: o, icons: s, isItemDraggable: c = !0, isOpen: l, node: u, onDragEnter: d, onDragOver: f, onDragLeave: p, onDrop: m, onToggle: h }) => {
|
|
8142
|
+
let g = Mp(), _ = g != null && g.enabled ? g.getRowCheckState(u.id) : void 0, v = _ == null ? void 0 : _.checked, y = _ == null ? void 0 : _.indeterminate, x = g == null ? void 0 : g.isRowCheckDisabled(u.id), w = g == null ? void 0 : g.enabled, { data: T, droppable: E } = u, { id: D, cells: O, testId: k, actions: A = [], active: j, onRowClick: M } = T, N = E || a, P = (e) => {
|
|
8078
8143
|
let r = t ? t[e] : void 0;
|
|
8079
8144
|
return e === 0 ? `calc(${r} - ${`calc(var(--size) * ${N ? n + 1 : n})`})` : r;
|
|
8080
8145
|
};
|
|
@@ -8087,7 +8152,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8087
8152
|
onDragLeave: p,
|
|
8088
8153
|
children: /* @__PURE__ */ S("tbody", { children: /* @__PURE__ */ C("tr", {
|
|
8089
8154
|
onClick: M,
|
|
8090
|
-
className: b(
|
|
8155
|
+
className: b(Tp.treeTableRow, j ? Tp.active : void 0),
|
|
8091
8156
|
children: [
|
|
8092
8157
|
w && /* @__PURE__ */ S(Hl, {
|
|
8093
8158
|
isHeader: !1,
|
|
@@ -8101,19 +8166,19 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8101
8166
|
}
|
|
8102
8167
|
}),
|
|
8103
8168
|
r && /* @__PURE__ */ S("td", {
|
|
8104
|
-
className:
|
|
8169
|
+
className: Tp.dragCell,
|
|
8105
8170
|
children: c && /* @__PURE__ */ S("div", {
|
|
8106
|
-
className:
|
|
8171
|
+
className: Tp.drag,
|
|
8107
8172
|
onClick: (e) => e.stopPropagation(),
|
|
8108
8173
|
ref: i,
|
|
8109
8174
|
children: /* @__PURE__ */ S(G, { icon: U.DRAG })
|
|
8110
8175
|
})
|
|
8111
8176
|
}),
|
|
8112
|
-
Array.from({ length: n }).map((e, t) => /* @__PURE__ */ S("td", { className:
|
|
8177
|
+
Array.from({ length: n }).map((e, t) => /* @__PURE__ */ S("td", { className: Tp.folderCell }, t)),
|
|
8113
8178
|
N && /* @__PURE__ */ S("td", {
|
|
8114
|
-
className:
|
|
8179
|
+
className: Tp.folderCell,
|
|
8115
8180
|
children: /* @__PURE__ */ S("div", {
|
|
8116
|
-
className:
|
|
8181
|
+
className: Tp.folder,
|
|
8117
8182
|
onClick: () => h(D),
|
|
8118
8183
|
onMouseDown: (e) => e.stopPropagation(),
|
|
8119
8184
|
children: /* @__PURE__ */ S(q, {
|
|
@@ -8145,10 +8210,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8145
8210
|
]
|
|
8146
8211
|
}) })
|
|
8147
8212
|
});
|
|
8148
|
-
},
|
|
8149
|
-
let a =
|
|
8213
|
+
}, Fp = ({ columnAlignment: e, columnWidths: t, draggable: n, hasRowActions: r, headers: i }) => {
|
|
8214
|
+
let a = Mp(), o = a == null ? void 0 : a.headerCheckState, s = (a == null ? void 0 : a.enabled) && o !== void 0;
|
|
8150
8215
|
return /* @__PURE__ */ S("table", {
|
|
8151
|
-
className: b(Hs.table,
|
|
8216
|
+
className: b(Hs.table, Tp.treeTableHeader),
|
|
8152
8217
|
children: /* @__PURE__ */ S("thead", { children: i.map((i, c) => /* @__PURE__ */ C("tr", { children: [
|
|
8153
8218
|
s && c === 0 ? /* @__PURE__ */ S(Hl, {
|
|
8154
8219
|
isHeader: !0,
|
|
@@ -8159,7 +8224,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8159
8224
|
onChange: a.toggleHeaderCheck
|
|
8160
8225
|
}
|
|
8161
8226
|
}) : s ? /* @__PURE__ */ S("td", {}) : null,
|
|
8162
|
-
n && /* @__PURE__ */ S("th", { className:
|
|
8227
|
+
n && /* @__PURE__ */ S("th", { className: Tp.dragCell }),
|
|
8163
8228
|
i.cells.map((n, r) => {
|
|
8164
8229
|
let i = t ? t[r] : void 0, a = e ? e[r] : void 0;
|
|
8165
8230
|
return /* @__PURE__ */ S(Hl, {
|
|
@@ -8179,22 +8244,22 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8179
8244
|
})
|
|
8180
8245
|
] }, c)) })
|
|
8181
8246
|
});
|
|
8182
|
-
},
|
|
8247
|
+
}, Ip = ({ allowParentReassignment: e, autoOpenActiveItems: t = !1, canDrop: n, draggable: r = !1, icons: i, isInitialOpen: a = !1, itemHasChild: o, onItemToggle: s, onListReorder: c, onChangeOpen: l, rowCheckboxes: u, table: d, testId: f, treeRef: p }) => {
|
|
8183
8248
|
let { columnAlignment: m, columnWidths: h, fixedWidth: g, headers: _, rows: v = [] } = d, y = ll(v, _ == null ? [] : _);
|
|
8184
|
-
return /* @__PURE__ */ S(
|
|
8249
|
+
return /* @__PURE__ */ S(Np, {
|
|
8185
8250
|
rowCheckboxes: u,
|
|
8186
8251
|
rows: v,
|
|
8187
8252
|
children: /* @__PURE__ */ C("div", {
|
|
8188
|
-
className:
|
|
8253
|
+
className: Tp.treeTable,
|
|
8189
8254
|
"data-testid": f,
|
|
8190
8255
|
style: { width: g },
|
|
8191
|
-
children: [!!_ && /* @__PURE__ */ S(
|
|
8256
|
+
children: [!!_ && /* @__PURE__ */ S(Fp, {
|
|
8192
8257
|
columnAlignment: m,
|
|
8193
8258
|
columnWidths: h,
|
|
8194
8259
|
draggable: r,
|
|
8195
8260
|
hasRowActions: y,
|
|
8196
8261
|
headers: _
|
|
8197
|
-
}), /* @__PURE__ */ S(
|
|
8262
|
+
}), /* @__PURE__ */ S(wp, {
|
|
8198
8263
|
allowParentReassignment: e,
|
|
8199
8264
|
autoOpenActiveItems: t,
|
|
8200
8265
|
canDrop: n,
|
|
@@ -8210,7 +8275,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8210
8275
|
onItemToggle: s,
|
|
8211
8276
|
onListReorder: c,
|
|
8212
8277
|
placeholderIndent: "var(--size)",
|
|
8213
|
-
render: (e, { depth: t, draggable: n, handleRef: a, hasChild: o, isOpen: s, onToggle: c }) => /* @__PURE__ */ S(
|
|
8278
|
+
render: (e, { depth: t, draggable: n, handleRef: a, hasChild: o, isOpen: s, onToggle: c }) => /* @__PURE__ */ S(Pp, {
|
|
8214
8279
|
node: e,
|
|
8215
8280
|
columnAlignment: m,
|
|
8216
8281
|
columnWidths: h,
|
|
@@ -8228,10 +8293,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8228
8293
|
})]
|
|
8229
8294
|
})
|
|
8230
8295
|
});
|
|
8231
|
-
},
|
|
8296
|
+
}, Lp = Object.freeze({
|
|
8232
8297
|
Translations: "translations",
|
|
8233
8298
|
LanguageKey: "languageKey"
|
|
8234
|
-
}),
|
|
8299
|
+
}), Rp = {
|
|
8235
8300
|
unified: "Unified",
|
|
8236
8301
|
split: "Split",
|
|
8237
8302
|
changesTooLarge: "Changes are too large to be shown",
|
|
@@ -8254,39 +8319,39 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8254
8319
|
showAll: "Show all",
|
|
8255
8320
|
unknown: "Unknown",
|
|
8256
8321
|
unexpectedError: "Unexpected error"
|
|
8257
|
-
},
|
|
8322
|
+
}, zp = (e) => Object.keys(Rp).reduce((t, n) => ({
|
|
8258
8323
|
...t,
|
|
8259
|
-
[n]: (e == null ? void 0 : e[n]) || (
|
|
8260
|
-
}), {}),
|
|
8261
|
-
[
|
|
8262
|
-
[
|
|
8263
|
-
},
|
|
8264
|
-
|
|
8265
|
-
},
|
|
8324
|
+
[n]: (e == null ? void 0 : e[n]) || (Rp == null ? void 0 : Rp[n])
|
|
8325
|
+
}), {}), Bp = {
|
|
8326
|
+
[Lp.Translations]: zp(),
|
|
8327
|
+
[Lp.LanguageKey]: "en"
|
|
8328
|
+
}, Vp = (e) => e ? Bp[e] : Bp, Hp = (e, t) => {
|
|
8329
|
+
Bp[e] = t;
|
|
8330
|
+
}, Up = (e) => e.reduce(({ preferredUnits: e, storageUnits: t }, { unitKey: n, preferredUnit: r, storageUnit: i }) => {
|
|
8266
8331
|
var a;
|
|
8267
|
-
let { unitTemplate: o = null } = (a =
|
|
8268
|
-
return e[n] = r == null ?
|
|
8332
|
+
let { unitTemplate: o = null } = (a = Jf()) == null ? {} : a;
|
|
8333
|
+
return e[n] = r == null ? Lf(n, o) : r, t[n] = i, {
|
|
8269
8334
|
preferredUnits: e,
|
|
8270
8335
|
storageUnits: t
|
|
8271
8336
|
};
|
|
8272
8337
|
}, {
|
|
8273
8338
|
preferredUnits: {},
|
|
8274
8339
|
storageUnits: {}
|
|
8275
|
-
}),
|
|
8340
|
+
}), Wp = ({ value: e, unitKey: t, selectedUnits: n, storageUnits: r }) => {
|
|
8276
8341
|
let i = n[t], a = r[t];
|
|
8277
8342
|
if (!(a && i !== a) || e === null || e === "") return e;
|
|
8278
|
-
let { value: o = e } =
|
|
8343
|
+
let { value: o = e } = Hf({
|
|
8279
8344
|
value: fr(e),
|
|
8280
8345
|
unitkey: t,
|
|
8281
8346
|
toUnit: i,
|
|
8282
8347
|
fromUnit: a
|
|
8283
8348
|
});
|
|
8284
8349
|
return o;
|
|
8285
|
-
},
|
|
8350
|
+
}, Gp = ({ row: e, selectedUnits: t, storageUnits: n, convertBackToStorageUnit: r, enableCosmeticRounding: i, enableDisplayRounding: a }) => ({
|
|
8286
8351
|
...e,
|
|
8287
8352
|
cells: e.cells.map((e) => {
|
|
8288
8353
|
if ("autoUnit" in e && e.autoUnit && (typeof e.value == "string" || typeof e.value == "number")) {
|
|
8289
|
-
let { unitKey: o, value: s, formatDisplayValue: c } = e, l = a && "roundDisplayValue" in e ? e.roundDisplayValue : null, u = t[o], d = n[o], f = d && u !== d, p =
|
|
8354
|
+
let { unitKey: o, value: s, formatDisplayValue: c } = e, l = a && "roundDisplayValue" in e ? e.roundDisplayValue : null, u = t[o], d = n[o], f = d && u !== d, p = Wp({
|
|
8290
8355
|
value: s,
|
|
8291
8356
|
unitKey: o,
|
|
8292
8357
|
selectedUnits: t,
|
|
@@ -8300,7 +8365,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8300
8365
|
roundDisplayValue: l,
|
|
8301
8366
|
selectOnFocus: !0,
|
|
8302
8367
|
onChange: (t) => {
|
|
8303
|
-
let n = t, { value: i } = n.target, a = r ? d : u, { value: s = i } =
|
|
8368
|
+
let n = t, { value: i } = n.target, a = r ? d : u, { value: s = i } = Hf({
|
|
8304
8369
|
value: String(i),
|
|
8305
8370
|
unitkey: o,
|
|
8306
8371
|
toUnit: a,
|
|
@@ -8319,8 +8384,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8319
8384
|
}
|
|
8320
8385
|
return e;
|
|
8321
8386
|
})
|
|
8322
|
-
}),
|
|
8323
|
-
let { translations: i } =
|
|
8387
|
+
}), Kp = ({ headers: e, selectedUnits: t, storageUnits: n, onChangeUnit: r }) => {
|
|
8388
|
+
let { translations: i } = Vp();
|
|
8324
8389
|
return e ? e.map((e) => ({
|
|
8325
8390
|
...e,
|
|
8326
8391
|
cells: e.cells.map((e) => {
|
|
@@ -8349,8 +8414,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8349
8414
|
return e;
|
|
8350
8415
|
})
|
|
8351
8416
|
})) : [];
|
|
8352
|
-
},
|
|
8353
|
-
let { headers: c, ...u } = e, { storageUnits: f, preferredUnits: p } =
|
|
8417
|
+
}, qp = ({ table: e, unitConfig: t, convertBackToStorageUnit: n = !0, enableCosmeticRounding: r = !0, enableDisplayRounding: i = !0, onListReorder: a, canListReorder: o, beforeRenderRow: s }) => {
|
|
8418
|
+
let { headers: c, ...u } = e, { storageUnits: f, preferredUnits: p } = Up(t), m = If(p), [h, g] = v(p), _ = ({ unitKey: e, value: n }) => {
|
|
8354
8419
|
g((t) => ({
|
|
8355
8420
|
...t,
|
|
8356
8421
|
[e]: n
|
|
@@ -8361,13 +8426,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8361
8426
|
newUnit: n,
|
|
8362
8427
|
unitKey: e
|
|
8363
8428
|
});
|
|
8364
|
-
}, y = l(({ row: e, rowIndex: t }) =>
|
|
8429
|
+
}, y = l(({ row: e, rowIndex: t }) => Gp({
|
|
8365
8430
|
row: s ? s({
|
|
8366
8431
|
row: e,
|
|
8367
8432
|
rowIndex: t,
|
|
8368
8433
|
selectedUnits: h,
|
|
8369
8434
|
storageUnits: f,
|
|
8370
|
-
convertValue: (e, t) =>
|
|
8435
|
+
convertValue: (e, t) => Wp({
|
|
8371
8436
|
value: e,
|
|
8372
8437
|
unitKey: t,
|
|
8373
8438
|
selectedUnits: h,
|
|
@@ -8398,7 +8463,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8398
8463
|
}, [t]), /* @__PURE__ */ S($l, {
|
|
8399
8464
|
table: {
|
|
8400
8465
|
...u,
|
|
8401
|
-
headers:
|
|
8466
|
+
headers: Kp({
|
|
8402
8467
|
headers: e.headers,
|
|
8403
8468
|
selectedUnits: h,
|
|
8404
8469
|
storageUnits: f,
|
|
@@ -8409,8 +8474,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8409
8474
|
canListReorder: o,
|
|
8410
8475
|
beforeRenderRow: y
|
|
8411
8476
|
});
|
|
8412
|
-
},
|
|
8413
|
-
let { translations: d } =
|
|
8477
|
+
}, Jp = { settingField: "_settingField_1x02n_1" }, Yp = ({ helpText: t, disabled: n = !1, showCustom: r = !1, children: i, userValue: a = void 0, companyValue: o = void 0, noPermission: s = !1, selectedOption: c, handleSelectChange: l, testId: u }) => {
|
|
8478
|
+
let { translations: d } = Vp(), f = (t) => t.replace(/\\n/g, "\n").split(/\n/).map((t, n) => /* @__PURE__ */ C(e.Fragment, { children: [t, /* @__PURE__ */ S("br", {})] }, n)), p = [
|
|
8414
8479
|
...r ? [] : [{
|
|
8415
8480
|
label: d == null ? void 0 : d.allUsers,
|
|
8416
8481
|
value: !1
|
|
@@ -8425,7 +8490,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8425
8490
|
}] : []
|
|
8426
8491
|
], m = a !== void 0 && o !== void 0 && !dn(a, o);
|
|
8427
8492
|
return /* @__PURE__ */ C("div", {
|
|
8428
|
-
className:
|
|
8493
|
+
className: Jp.settingField,
|
|
8429
8494
|
"data-testid": u,
|
|
8430
8495
|
children: [/* @__PURE__ */ C(yd, {
|
|
8431
8496
|
justifyContent: "space-between",
|
|
@@ -8457,7 +8522,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8457
8522
|
children: f(t)
|
|
8458
8523
|
})]
|
|
8459
8524
|
});
|
|
8460
|
-
},
|
|
8525
|
+
}, Xp = { backgroundColor: "var(--color-background-error-muted)" }, Zp = { backgroundColor: "var(--color-background-success-muted)" }, Qp = { backgroundColor: "var(--color-background-warning-muted)" }, $p = {
|
|
8461
8526
|
addedBackground: "var(--color-diff-added-background)",
|
|
8462
8527
|
addedGutterBackground: "var(--color-diff-added-gutter-background)",
|
|
8463
8528
|
codeFoldBackground: "var(--color-diff-code-fold-background)",
|
|
@@ -8476,10 +8541,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8476
8541
|
removedGutterBackground: "var(--color-diff-removed-gutter-background)",
|
|
8477
8542
|
wordAddedBackground: "var(--color-diff-word-added-background)",
|
|
8478
8543
|
wordRemovedBackground: "var(--color-diff-word-removed-background)"
|
|
8479
|
-
},
|
|
8544
|
+
}, em = {
|
|
8480
8545
|
variables: {
|
|
8481
|
-
light:
|
|
8482
|
-
dark:
|
|
8546
|
+
light: $p,
|
|
8547
|
+
dark: $p
|
|
8483
8548
|
},
|
|
8484
8549
|
diffContainer: { minWidth: "unset" },
|
|
8485
8550
|
codeFoldGutter: {
|
|
@@ -8494,10 +8559,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8494
8559
|
pre: { opacity: .5 }
|
|
8495
8560
|
} },
|
|
8496
8561
|
marker: { pre: { opacity: .4 } }
|
|
8497
|
-
},
|
|
8562
|
+
}, tm = { codeOnly: "_codeOnly_1lph2_42" }, nm = ({ value: e, compareValue: t, splitView: n = !1, showDiffOnly: r = !1, compareMethod: i = Di.LINES, extraLinesSurroundingDiff: a, hideSummary: o = !0, className: s }) => {
|
|
8498
8563
|
let c = t !== void 0, l = c ? t : e, u = i !== Di.WORDS;
|
|
8499
8564
|
return /* @__PURE__ */ S("div", {
|
|
8500
|
-
className: b(s, { [
|
|
8565
|
+
className: b(s, { [tm.codeOnly]: !c && !n }),
|
|
8501
8566
|
children: /* @__PURE__ */ S(Ei, {
|
|
8502
8567
|
oldValue: l,
|
|
8503
8568
|
newValue: e,
|
|
@@ -8509,22 +8574,22 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8509
8574
|
hideLineNumbers: !1,
|
|
8510
8575
|
hideSummary: o,
|
|
8511
8576
|
disableWorker: !0,
|
|
8512
|
-
styles:
|
|
8577
|
+
styles: em
|
|
8513
8578
|
})
|
|
8514
8579
|
});
|
|
8515
|
-
},
|
|
8580
|
+
}, rm = (e, t) => {
|
|
8516
8581
|
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;
|
|
8517
8582
|
return {
|
|
8518
8583
|
added: Math.max(0, i),
|
|
8519
8584
|
removed: Math.max(0, a)
|
|
8520
8585
|
};
|
|
8521
|
-
},
|
|
8586
|
+
}, im = "split", am = "unified", om = ({ oldJson: e, newJson: t, viewType: n = im }) => {
|
|
8522
8587
|
var r, i;
|
|
8523
|
-
let { translations: a } =
|
|
8524
|
-
value:
|
|
8588
|
+
let { translations: a } = Vp(), [o, s] = v(n), c = [{
|
|
8589
|
+
value: im,
|
|
8525
8590
|
label: (r = a == null ? void 0 : a.split) == null ? "Split" : r
|
|
8526
8591
|
}, {
|
|
8527
|
-
value:
|
|
8592
|
+
value: am,
|
|
8528
8593
|
label: (i = a == null ? void 0 : a.unified) == null ? "Unified" : i
|
|
8529
8594
|
}];
|
|
8530
8595
|
d(() => {
|
|
@@ -8532,7 +8597,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8532
8597
|
}, [n]);
|
|
8533
8598
|
let l = ({ target: { value: e } }) => {
|
|
8534
8599
|
s(e);
|
|
8535
|
-
}, { added: u, removed: f } =
|
|
8600
|
+
}, { added: u, removed: f } = rm(e, t), p = u + f > 3500;
|
|
8536
8601
|
return /* @__PURE__ */ S(x, { children: /* @__PURE__ */ S(go, {
|
|
8537
8602
|
bordered: !0,
|
|
8538
8603
|
heading: /* @__PURE__ */ C(yd, {
|
|
@@ -8562,21 +8627,21 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8562
8627
|
muted: !0,
|
|
8563
8628
|
children: a == null ? void 0 : a.changesTooLarge
|
|
8564
8629
|
})
|
|
8565
|
-
}) : /* @__PURE__ */ S(
|
|
8630
|
+
}) : /* @__PURE__ */ S(nm, {
|
|
8566
8631
|
value: t,
|
|
8567
8632
|
compareValue: e,
|
|
8568
|
-
splitView: o ===
|
|
8633
|
+
splitView: o === im,
|
|
8569
8634
|
compareMethod: Di.WORDS,
|
|
8570
8635
|
showDiffOnly: !0,
|
|
8571
8636
|
hideSummary: !1
|
|
8572
8637
|
})
|
|
8573
8638
|
}) });
|
|
8574
|
-
},
|
|
8639
|
+
}, sm = (e) => typeof e == "object" && e && "value" in e ? e.value : e, cm = (e) => {
|
|
8575
8640
|
var t;
|
|
8576
8641
|
if (e.id != null) return String(e.id);
|
|
8577
|
-
let n =
|
|
8642
|
+
let n = sm((t = e.cells) == null || (t = t[0]) == null ? void 0 : t.value);
|
|
8578
8643
|
return n == null ? "" : String(n);
|
|
8579
|
-
},
|
|
8644
|
+
}, lm = (e, t) => ({
|
|
8580
8645
|
...e,
|
|
8581
8646
|
cells: e.cells.map((e) => ({
|
|
8582
8647
|
...e,
|
|
@@ -8585,7 +8650,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8585
8650
|
...t
|
|
8586
8651
|
}
|
|
8587
8652
|
}))
|
|
8588
|
-
}),
|
|
8653
|
+
}), um = (e, t) => ({
|
|
8589
8654
|
...e,
|
|
8590
8655
|
cells: e.cells.map((e, n) => {
|
|
8591
8656
|
var r;
|
|
@@ -8594,17 +8659,17 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8594
8659
|
...e,
|
|
8595
8660
|
style: {
|
|
8596
8661
|
...e.style,
|
|
8597
|
-
...
|
|
8662
|
+
...Qp
|
|
8598
8663
|
},
|
|
8599
8664
|
tooltip: typeof a == "number" ? String(a) : a
|
|
8600
8665
|
};
|
|
8601
8666
|
})
|
|
8602
|
-
}),
|
|
8667
|
+
}), dm = (e = [], t = []) => {
|
|
8603
8668
|
let n = /* @__PURE__ */ new Map();
|
|
8604
|
-
for (let e of t) n.set(
|
|
8605
|
-
let r = new Set(e.map(
|
|
8669
|
+
for (let e of t) n.set(cm(e), e);
|
|
8670
|
+
let r = new Set(e.map(cm)), i = /* @__PURE__ */ new Map(), a = [], o = null;
|
|
8606
8671
|
for (let e = t.length - 1; e >= 0; e--) {
|
|
8607
|
-
let n = t[e], c =
|
|
8672
|
+
let n = t[e], c = cm(n);
|
|
8608
8673
|
if (r.has(c)) {
|
|
8609
8674
|
o = c;
|
|
8610
8675
|
continue;
|
|
@@ -8619,7 +8684,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8619
8684
|
a.reverse();
|
|
8620
8685
|
let c = [];
|
|
8621
8686
|
for (let t of e) {
|
|
8622
|
-
let e =
|
|
8687
|
+
let e = cm(t), r = i.get(e);
|
|
8623
8688
|
if (r) for (let e of r) c.push({
|
|
8624
8689
|
status: "deleted",
|
|
8625
8690
|
row: e
|
|
@@ -8639,11 +8704,11 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8639
8704
|
row: e
|
|
8640
8705
|
});
|
|
8641
8706
|
return c;
|
|
8642
|
-
},
|
|
8643
|
-
let i = h(() =>
|
|
8707
|
+
}, fm = (e) => e.status === "deleted" ? lm(e.row, Xp) : e.status === "added" ? lm(e.row, Zp) : um(e.row, e.compareRow), pm = ({ table: e, compareRows: t, beforeRenderRow: n, ...r }) => {
|
|
8708
|
+
let i = h(() => dm(e.rows, t), [e.rows, t]), a = !!e.infiniteScroll, o = h(() => {
|
|
8644
8709
|
if (!a) return i.map((e) => e.row);
|
|
8645
8710
|
}, [a, i]), s = l(({ row: e, rowIndex: t }) => {
|
|
8646
|
-
let r = i[t], a = r ?
|
|
8711
|
+
let r = i[t], a = r ? fm(r) : e;
|
|
8647
8712
|
return n ? n({
|
|
8648
8713
|
row: a,
|
|
8649
8714
|
rowIndex: t
|
|
@@ -8662,7 +8727,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8662
8727
|
};
|
|
8663
8728
|
//#endregion
|
|
8664
8729
|
//#region src/helpers/date.ts
|
|
8665
|
-
function
|
|
8730
|
+
function mm({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i, locale: a }) {
|
|
8666
8731
|
return e ? new Date(e).toLocaleString(a, {
|
|
8667
8732
|
year: "numeric",
|
|
8668
8733
|
month: "short",
|
|
@@ -8676,28 +8741,28 @@ function lm({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i
|
|
|
8676
8741
|
}
|
|
8677
8742
|
//#endregion
|
|
8678
8743
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/clone.js
|
|
8679
|
-
function
|
|
8744
|
+
function hm(e) {
|
|
8680
8745
|
var t;
|
|
8681
8746
|
let n = /^\/(.*)\/([gimyu]*)$/.exec(e.toString());
|
|
8682
8747
|
if (!n) throw Error("Invalid RegExp");
|
|
8683
8748
|
return new RegExp((t = n[1]) == null ? "" : t, n[2]);
|
|
8684
8749
|
}
|
|
8685
|
-
function
|
|
8750
|
+
function gm(e) {
|
|
8686
8751
|
if (typeof e != "object") return e;
|
|
8687
8752
|
if (e === null) return null;
|
|
8688
|
-
if (Array.isArray(e)) return e.map(
|
|
8753
|
+
if (Array.isArray(e)) return e.map(gm);
|
|
8689
8754
|
if (e instanceof Date) return new Date(e.getTime());
|
|
8690
|
-
if (e instanceof RegExp) return
|
|
8755
|
+
if (e instanceof RegExp) return hm(e);
|
|
8691
8756
|
let t = {};
|
|
8692
|
-
for (let n in e) Object.prototype.hasOwnProperty.call(e, n) && (t[n] =
|
|
8757
|
+
for (let n in e) Object.prototype.hasOwnProperty.call(e, n) && (t[n] = gm(e[n]));
|
|
8693
8758
|
return t;
|
|
8694
8759
|
}
|
|
8695
8760
|
//#endregion
|
|
8696
8761
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/assertions/arrays.js
|
|
8697
|
-
function
|
|
8762
|
+
function _m(e, t) {
|
|
8698
8763
|
if (e.length === 0) throw Error(t || "Expected a non-empty array");
|
|
8699
8764
|
}
|
|
8700
|
-
var
|
|
8765
|
+
var vm = (e) => e[e.length - 1], ym = class {
|
|
8701
8766
|
setResult(e) {
|
|
8702
8767
|
return this.result = e, this.hasResult = !0, this;
|
|
8703
8768
|
}
|
|
@@ -8705,16 +8770,16 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8705
8770
|
return this.exiting = !0, this;
|
|
8706
8771
|
}
|
|
8707
8772
|
push(e, t) {
|
|
8708
|
-
return e.parent = this, t !== void 0 && (e.childName = t), e.root = this.root || this, e.options = e.options || this.options, this.children ? (
|
|
8773
|
+
return e.parent = this, t !== void 0 && (e.childName = t), e.root = this.root || this, e.options = e.options || this.options, this.children ? (_m(this.children), vm(this.children).next = e, this.children.push(e)) : (this.children = [e], this.nextAfterChildren = this.next || null, this.next = e), e.next = this, this;
|
|
8709
8774
|
}
|
|
8710
|
-
},
|
|
8775
|
+
}, bm = class extends ym {
|
|
8711
8776
|
constructor(e, t) {
|
|
8712
8777
|
super(), this.left = e, this.right = t, this.pipe = "diff";
|
|
8713
8778
|
}
|
|
8714
8779
|
prepareDeltaResult(e) {
|
|
8715
8780
|
var t, n, r, i;
|
|
8716
8781
|
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)) {
|
|
8717
|
-
let t = typeof ((r = this.options) == null ? void 0 : r.cloneDiffValues) == "function" ? (i = this.options) == null ? void 0 : i.cloneDiffValues :
|
|
8782
|
+
let t = typeof ((r = this.options) == null ? void 0 : r.cloneDiffValues) == "function" ? (i = this.options) == null ? void 0 : i.cloneDiffValues : gm;
|
|
8718
8783
|
typeof e[0] == "object" && (e[0] = t(e[0])), typeof e[1] == "object" && (e[1] = t(e[1]));
|
|
8719
8784
|
}
|
|
8720
8785
|
return e;
|
|
@@ -8722,15 +8787,15 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8722
8787
|
setResult(e) {
|
|
8723
8788
|
return this.prepareDeltaResult(e), super.setResult(e);
|
|
8724
8789
|
}
|
|
8725
|
-
},
|
|
8790
|
+
}, xm = class extends ym {
|
|
8726
8791
|
constructor(e, t) {
|
|
8727
8792
|
super(), this.left = e, this.delta = t, this.pipe = "patch";
|
|
8728
8793
|
}
|
|
8729
|
-
},
|
|
8794
|
+
}, Sm = class extends ym {
|
|
8730
8795
|
constructor(e) {
|
|
8731
8796
|
super(), this.delta = e, this.pipe = "reverse";
|
|
8732
8797
|
}
|
|
8733
|
-
},
|
|
8798
|
+
}, Cm = class {
|
|
8734
8799
|
constructor(e) {
|
|
8735
8800
|
this.name = e, this.filters = [];
|
|
8736
8801
|
}
|
|
@@ -8794,7 +8859,7 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8794
8859
|
}
|
|
8795
8860
|
}), this);
|
|
8796
8861
|
}
|
|
8797
|
-
},
|
|
8862
|
+
}, wm = class {
|
|
8798
8863
|
constructor(e) {
|
|
8799
8864
|
this.selfOptions = e || {}, this.pipes = {};
|
|
8800
8865
|
}
|
|
@@ -8821,7 +8886,7 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8821
8886
|
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);
|
|
8822
8887
|
return n.hasResult ? n.result : void 0;
|
|
8823
8888
|
}
|
|
8824
|
-
},
|
|
8889
|
+
}, Tm = (e, t, n, r) => e[n] === t[r], Em = (e, t, n, r) => {
|
|
8825
8890
|
var i, a, o;
|
|
8826
8891
|
let s = e.length, c = t.length, l, u, d = Array(s + 1);
|
|
8827
8892
|
for (l = 0; l < s + 1; l++) {
|
|
@@ -8837,7 +8902,7 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8837
8902
|
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);
|
|
8838
8903
|
}
|
|
8839
8904
|
return d;
|
|
8840
|
-
},
|
|
8905
|
+
}, Dm = (e, t, n, r) => {
|
|
8841
8906
|
let i = t.length, a = n.length, o = {
|
|
8842
8907
|
sequence: [],
|
|
8843
8908
|
indices1: [],
|
|
@@ -8859,11 +8924,11 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8859
8924
|
}
|
|
8860
8925
|
}
|
|
8861
8926
|
return o;
|
|
8862
|
-
},
|
|
8927
|
+
}, Om = { get: (e, t, n, r) => {
|
|
8863
8928
|
let i = r || {};
|
|
8864
|
-
return
|
|
8865
|
-
} },
|
|
8866
|
-
function
|
|
8929
|
+
return Dm(Em(e, t, n || Tm, i), e, t, i);
|
|
8930
|
+
} }, km = 3;
|
|
8931
|
+
function Am(e, t, n, r) {
|
|
8867
8932
|
for (let i = 0; i < n; i++) {
|
|
8868
8933
|
let n = e[i];
|
|
8869
8934
|
for (let e = 0; e < r; e++) {
|
|
@@ -8873,7 +8938,7 @@ function Tm(e, t, n, r) {
|
|
|
8873
8938
|
}
|
|
8874
8939
|
return !1;
|
|
8875
8940
|
}
|
|
8876
|
-
function
|
|
8941
|
+
function jm(e, t, n, r, i) {
|
|
8877
8942
|
let a = e[n], o = t[r];
|
|
8878
8943
|
if (a === o) return !0;
|
|
8879
8944
|
if (typeof a != "object" || typeof o != "object") return !1;
|
|
@@ -8886,15 +8951,15 @@ function Em(e, t, n, r, i) {
|
|
|
8886
8951
|
let l = i.hashCache2[r];
|
|
8887
8952
|
return l === void 0 && (i.hashCache2[r] = l = s(o, r)), l !== void 0 && c === l;
|
|
8888
8953
|
}
|
|
8889
|
-
var
|
|
8954
|
+
var Mm = function(e) {
|
|
8890
8955
|
var t, n, r, i, a;
|
|
8891
8956
|
if (!e.leftIsArray) return;
|
|
8892
8957
|
let o = {
|
|
8893
8958
|
objectHash: (t = e.options) == null ? void 0 : t.objectHash,
|
|
8894
8959
|
matchByPosition: (n = e.options) == null ? void 0 : n.matchByPosition
|
|
8895
8960
|
}, s = 0, c = 0, l, u, d, f = e.left, p = e.right, m = f.length, h = p.length, g;
|
|
8896
|
-
for (m > 0 && h > 0 && !o.objectHash && typeof o.matchByPosition != "boolean" && (o.matchByPosition = !
|
|
8897
|
-
for (; c + s < m && c + s < h &&
|
|
8961
|
+
for (m > 0 && h > 0 && !o.objectHash && typeof o.matchByPosition != "boolean" && (o.matchByPosition = !Am(f, p, m, h)); s < m && s < h && jm(f, p, s, s, o);) l = s, g = new bm(f[l], p[l]), e.push(g, l), s++;
|
|
8962
|
+
for (; c + s < m && c + s < h && jm(f, p, m - 1 - c, h - 1 - c, o);) u = m - 1 - c, d = h - 1 - c, g = new bm(f[u], p[d]), e.push(g, d), c++;
|
|
8898
8963
|
let _;
|
|
8899
8964
|
if (s + c === m) {
|
|
8900
8965
|
if (m === h) {
|
|
@@ -8918,7 +8983,7 @@ var Dm = function(e) {
|
|
|
8918
8983
|
return;
|
|
8919
8984
|
}
|
|
8920
8985
|
o.hashCache1 = void 0, o.hashCache2 = void 0;
|
|
8921
|
-
let v = f.slice(s, m - c), y = p.slice(s, h - c), b =
|
|
8986
|
+
let v = f.slice(s, m - c), y = p.slice(s, h - c), b = Om.get(v, y, jm, o), x = [];
|
|
8922
8987
|
for (_ = _ || { _t: "a" }, l = s; l < m - c; l++) if (b.indices1.indexOf(l - s) < 0) {
|
|
8923
8988
|
let t = `_${l}`;
|
|
8924
8989
|
_[t] = [
|
|
@@ -8939,8 +9004,8 @@ var Dm = function(e) {
|
|
|
8939
9004
|
if (S && w > 0) for (let n = 0; n < w; n++) {
|
|
8940
9005
|
u = x[n];
|
|
8941
9006
|
let r = u === void 0 ? void 0 : _[`_${u}`];
|
|
8942
|
-
if (u !== void 0 && r &&
|
|
8943
|
-
r.splice(1, 2, l,
|
|
9007
|
+
if (u !== void 0 && r && jm(v, y, u - s, l - s, o)) {
|
|
9008
|
+
r.splice(1, 2, l, km), r.splice(1, 2, l, km), C || (r[0] = ""), d = l, g = new bm(f[u], p[d]), e.push(g, d), x.splice(n, 1), t = !0;
|
|
8944
9009
|
break;
|
|
8945
9010
|
}
|
|
8946
9011
|
}
|
|
@@ -8948,20 +9013,20 @@ var Dm = function(e) {
|
|
|
8948
9013
|
} else {
|
|
8949
9014
|
if (b.indices1[t] === void 0) throw Error(`Invalid indexOnArray2: ${t}, seq.indices1: ${b.indices1}`);
|
|
8950
9015
|
if (u = b.indices1[t] + s, b.indices2[t] === void 0) throw Error(`Invalid indexOnArray2: ${t}, seq.indices2: ${b.indices2}`);
|
|
8951
|
-
d = b.indices2[t] + s, g = new
|
|
9016
|
+
d = b.indices2[t] + s, g = new bm(f[u], p[d]), e.push(g, d);
|
|
8952
9017
|
}
|
|
8953
9018
|
}
|
|
8954
9019
|
e.setResult(_).exit();
|
|
8955
9020
|
};
|
|
8956
|
-
|
|
8957
|
-
var
|
|
9021
|
+
Mm.filterName = "arrays";
|
|
9022
|
+
var Nm = {
|
|
8958
9023
|
numerically(e, t) {
|
|
8959
9024
|
return e - t;
|
|
8960
9025
|
},
|
|
8961
9026
|
numericallyBy(e) {
|
|
8962
9027
|
return (t, n) => t[e] - n[e];
|
|
8963
9028
|
}
|
|
8964
|
-
},
|
|
9029
|
+
}, Pm = function(e) {
|
|
8965
9030
|
var t;
|
|
8966
9031
|
if (!e.nested) return;
|
|
8967
9032
|
let n = e.delta;
|
|
@@ -8970,7 +9035,7 @@ var Om = {
|
|
|
8970
9035
|
for (r in a) if (r !== "_t") {
|
|
8971
9036
|
if (r[0] === "_") {
|
|
8972
9037
|
let e = r;
|
|
8973
|
-
if (a[e] !== void 0 && (a[e][2] === 0 || a[e][2] ===
|
|
9038
|
+
if (a[e] !== void 0 && (a[e][2] === 0 || a[e][2] === km)) s.push(Number.parseInt(r.slice(1), 10));
|
|
8974
9039
|
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]}`);
|
|
8975
9040
|
} else {
|
|
8976
9041
|
let e = r;
|
|
@@ -8983,15 +9048,15 @@ var Om = {
|
|
|
8983
9048
|
});
|
|
8984
9049
|
}
|
|
8985
9050
|
}
|
|
8986
|
-
for (s = s.sort(
|
|
9051
|
+
for (s = s.sort(Nm.numerically), r = s.length - 1; r >= 0; r--) {
|
|
8987
9052
|
if (i = s[r], i === void 0) continue;
|
|
8988
9053
|
let e = a[`_${i}`], t = o.splice(i, 1)[0];
|
|
8989
|
-
(e == null ? void 0 : e[2]) ===
|
|
9054
|
+
(e == null ? void 0 : e[2]) === km && c.push({
|
|
8990
9055
|
index: e[1],
|
|
8991
9056
|
value: t
|
|
8992
9057
|
});
|
|
8993
9058
|
}
|
|
8994
|
-
c = c.sort(
|
|
9059
|
+
c = c.sort(Nm.numericallyBy("index"));
|
|
8995
9060
|
let u = c.length;
|
|
8996
9061
|
for (r = 0; r < u; r++) {
|
|
8997
9062
|
let e = c[r];
|
|
@@ -9001,7 +9066,7 @@ var Om = {
|
|
|
9001
9066
|
if (d > 0) for (r = 0; r < d; r++) {
|
|
9002
9067
|
let t = l[r];
|
|
9003
9068
|
if (t === void 0) continue;
|
|
9004
|
-
let n = new
|
|
9069
|
+
let n = new xm(o[t.index], t.delta);
|
|
9005
9070
|
e.push(n, t.index);
|
|
9006
9071
|
}
|
|
9007
9072
|
if (!e.children) {
|
|
@@ -9010,8 +9075,8 @@ var Om = {
|
|
|
9010
9075
|
}
|
|
9011
9076
|
e.exit();
|
|
9012
9077
|
};
|
|
9013
|
-
|
|
9014
|
-
var
|
|
9078
|
+
Pm.filterName = "arrays";
|
|
9079
|
+
var Fm = function(e) {
|
|
9015
9080
|
if (!e || !e.children || e.delta._t !== "a") return;
|
|
9016
9081
|
let t = e.left, n = e.children.length;
|
|
9017
9082
|
for (let r = 0; r < n; r++) {
|
|
@@ -9022,16 +9087,16 @@ var Am = function(e) {
|
|
|
9022
9087
|
}
|
|
9023
9088
|
e.setResult(t).exit();
|
|
9024
9089
|
};
|
|
9025
|
-
|
|
9026
|
-
var
|
|
9090
|
+
Fm.filterName = "arraysCollectChildren";
|
|
9091
|
+
var Im = function(e) {
|
|
9027
9092
|
if (!e.nested) {
|
|
9028
9093
|
let t = e.delta;
|
|
9029
|
-
if (t[2] ===
|
|
9094
|
+
if (t[2] === km) {
|
|
9030
9095
|
let n = t;
|
|
9031
9096
|
e.newName = `_${n[1]}`, e.setResult([
|
|
9032
9097
|
n[0],
|
|
9033
9098
|
Number.parseInt(e.childName.substring(1), 10),
|
|
9034
|
-
|
|
9099
|
+
km
|
|
9035
9100
|
]).exit();
|
|
9036
9101
|
}
|
|
9037
9102
|
return;
|
|
@@ -9041,20 +9106,20 @@ var jm = function(e) {
|
|
|
9041
9106
|
let n = t;
|
|
9042
9107
|
for (let t in n) {
|
|
9043
9108
|
if (t === "_t") continue;
|
|
9044
|
-
let r = new
|
|
9109
|
+
let r = new Sm(n[t]);
|
|
9045
9110
|
e.push(r, t);
|
|
9046
9111
|
}
|
|
9047
9112
|
e.exit();
|
|
9048
9113
|
};
|
|
9049
|
-
|
|
9050
|
-
var
|
|
9114
|
+
Im.filterName = "arrays";
|
|
9115
|
+
var Lm = (e, t, n) => {
|
|
9051
9116
|
if (typeof t == "string" && t[0] === "_") return Number.parseInt(t.substring(1), 10);
|
|
9052
9117
|
if (Array.isArray(n) && n[2] === 0) return `_${t}`;
|
|
9053
9118
|
let r = +t;
|
|
9054
9119
|
for (let n in e) {
|
|
9055
9120
|
let i = e[n];
|
|
9056
9121
|
if (Array.isArray(i)) {
|
|
9057
|
-
if (i[2] ===
|
|
9122
|
+
if (i[2] === km) {
|
|
9058
9123
|
let e = Number.parseInt(n.substring(1), 10), a = i[1];
|
|
9059
9124
|
if (a === +t) return e;
|
|
9060
9125
|
e <= r && a > r ? r++ : e >= r && a < r && r--;
|
|
@@ -9062,7 +9127,7 @@ var Mm = (e, t, n) => {
|
|
|
9062
9127
|
}
|
|
9063
9128
|
}
|
|
9064
9129
|
return r;
|
|
9065
|
-
},
|
|
9130
|
+
}, Rm = (e) => {
|
|
9066
9131
|
if (!e || !e.children) return;
|
|
9067
9132
|
let t = e.delta;
|
|
9068
9133
|
if (t._t !== "a") return;
|
|
@@ -9073,22 +9138,22 @@ var Mm = (e, t, n) => {
|
|
|
9073
9138
|
let a = r.newName;
|
|
9074
9139
|
if (a === void 0) {
|
|
9075
9140
|
if (r.childName === void 0) throw Error("child.childName is undefined");
|
|
9076
|
-
a =
|
|
9141
|
+
a = Lm(n, r.childName, r.result);
|
|
9077
9142
|
}
|
|
9078
9143
|
i[a] !== r.result && (i[a] = r.result);
|
|
9079
9144
|
}
|
|
9080
9145
|
e.setResult(i).exit();
|
|
9081
9146
|
};
|
|
9082
|
-
|
|
9147
|
+
Rm.filterName = "arraysCollectChildren";
|
|
9083
9148
|
//#endregion
|
|
9084
9149
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/dates.js
|
|
9085
|
-
var
|
|
9150
|
+
var zm = function(e) {
|
|
9086
9151
|
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();
|
|
9087
9152
|
};
|
|
9088
|
-
|
|
9153
|
+
zm.filterName = "dates";
|
|
9089
9154
|
//#endregion
|
|
9090
9155
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/nested.js
|
|
9091
|
-
var
|
|
9156
|
+
var Bm = /* @__PURE__ */ new Set(["__proto__"]), Vm = (e) => {
|
|
9092
9157
|
if (!e || !e.children) return;
|
|
9093
9158
|
let t = e.children.length, n = e.result;
|
|
9094
9159
|
for (let r = 0; r < t; r++) {
|
|
@@ -9100,18 +9165,18 @@ var Fm = /* @__PURE__ */ new Set(["__proto__"]), Im = (e) => {
|
|
|
9100
9165
|
}
|
|
9101
9166
|
n && e.leftIsArray && (n._t = "a"), e.setResult(n).exit();
|
|
9102
9167
|
};
|
|
9103
|
-
|
|
9104
|
-
var
|
|
9168
|
+
Vm.filterName = "collectChildren";
|
|
9169
|
+
var Hm = (e) => {
|
|
9105
9170
|
var t;
|
|
9106
9171
|
if (e.leftIsArray || e.leftType !== "object") return;
|
|
9107
9172
|
let n = e.left, r = e.right, i = (t = e.options) == null ? void 0 : t.propertyFilter;
|
|
9108
9173
|
for (let t in n) {
|
|
9109
9174
|
if (!Object.prototype.hasOwnProperty.call(n, t) || i && !i(t, e)) continue;
|
|
9110
|
-
let a = new
|
|
9175
|
+
let a = new bm(n[t], r[t]);
|
|
9111
9176
|
e.push(a, t);
|
|
9112
9177
|
}
|
|
9113
9178
|
for (let t in r) if (Object.prototype.hasOwnProperty.call(r, t) && !(i && !i(t, e)) && n[t] === void 0) {
|
|
9114
|
-
let n = new
|
|
9179
|
+
let n = new bm(void 0, r[t]);
|
|
9115
9180
|
e.push(n, t);
|
|
9116
9181
|
}
|
|
9117
9182
|
if (!e.children || e.children.length === 0) {
|
|
@@ -9120,15 +9185,15 @@ var Lm = (e) => {
|
|
|
9120
9185
|
}
|
|
9121
9186
|
e.exit();
|
|
9122
9187
|
};
|
|
9123
|
-
|
|
9124
|
-
var
|
|
9188
|
+
Hm.filterName = "objects";
|
|
9189
|
+
var Um = function(e) {
|
|
9125
9190
|
if (!e.nested) return;
|
|
9126
9191
|
let t = e.delta;
|
|
9127
9192
|
if (t._t) return;
|
|
9128
9193
|
let n = t, r = !1;
|
|
9129
9194
|
for (let t in n) {
|
|
9130
|
-
if (
|
|
9131
|
-
let i = e.left, a = new
|
|
9195
|
+
if (Bm.has(t) || !Object.prototype.hasOwnProperty.call(n, t)) continue;
|
|
9196
|
+
let i = e.left, a = new xm(typeof i == "object" && i && Object.prototype.hasOwnProperty.call(i, t) ? i[t] : void 0, n[t]);
|
|
9132
9197
|
e.push(a, t), r = !0;
|
|
9133
9198
|
}
|
|
9134
9199
|
if (!r) {
|
|
@@ -9137,8 +9202,8 @@ var Rm = function(e) {
|
|
|
9137
9202
|
}
|
|
9138
9203
|
e.exit();
|
|
9139
9204
|
};
|
|
9140
|
-
|
|
9141
|
-
var
|
|
9205
|
+
Um.filterName = "objects";
|
|
9206
|
+
var Wm = function(e) {
|
|
9142
9207
|
if (!e || !e.children || e.delta._t) return;
|
|
9143
9208
|
if (e.left === null || typeof e.left != "object") {
|
|
9144
9209
|
e.setResult(e.left).exit();
|
|
@@ -9149,17 +9214,17 @@ var zm = function(e) {
|
|
|
9149
9214
|
let n = e.children[r];
|
|
9150
9215
|
if (n === void 0) continue;
|
|
9151
9216
|
let i = n.childName;
|
|
9152
|
-
|
|
9217
|
+
Bm.has(i) || (Object.prototype.hasOwnProperty.call(e.left, i) && n.result === void 0 ? delete t[i] : t[i] !== n.result && (t[i] = n.result));
|
|
9153
9218
|
}
|
|
9154
9219
|
e.setResult(t).exit();
|
|
9155
9220
|
};
|
|
9156
|
-
|
|
9157
|
-
var
|
|
9221
|
+
Wm.filterName = "collectChildren";
|
|
9222
|
+
var Gm = function(e) {
|
|
9158
9223
|
if (!e.nested || e.delta._t) return;
|
|
9159
9224
|
let t = e.delta, n = !1;
|
|
9160
9225
|
for (let r in t) {
|
|
9161
|
-
if (
|
|
9162
|
-
let i = new
|
|
9226
|
+
if (Bm.has(r) || !Object.prototype.hasOwnProperty.call(t, r)) continue;
|
|
9227
|
+
let i = new Sm(t[r]);
|
|
9163
9228
|
e.push(i, r), n = !0;
|
|
9164
9229
|
}
|
|
9165
9230
|
if (!n) {
|
|
@@ -9168,25 +9233,25 @@ var Bm = function(e) {
|
|
|
9168
9233
|
}
|
|
9169
9234
|
e.exit();
|
|
9170
9235
|
};
|
|
9171
|
-
|
|
9172
|
-
var
|
|
9236
|
+
Gm.filterName = "objects";
|
|
9237
|
+
var Km = (e) => {
|
|
9173
9238
|
if (!e || !e.children || e.delta._t) return;
|
|
9174
9239
|
let t = e.children.length, n = {};
|
|
9175
9240
|
for (let r = 0; r < t; r++) {
|
|
9176
9241
|
let t = e.children[r];
|
|
9177
9242
|
if (t === void 0) continue;
|
|
9178
9243
|
let i = t.childName;
|
|
9179
|
-
|
|
9244
|
+
Bm.has(i) || n[i] !== t.result && (n[i] = t.result);
|
|
9180
9245
|
}
|
|
9181
9246
|
e.setResult(n).exit();
|
|
9182
9247
|
};
|
|
9183
|
-
|
|
9248
|
+
Km.filterName = "collectChildren";
|
|
9184
9249
|
//#endregion
|
|
9185
9250
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/texts.js
|
|
9186
|
-
var
|
|
9187
|
-
function
|
|
9251
|
+
var qm = 2, Jm = 60, Ym = null;
|
|
9252
|
+
function Xm(e, t) {
|
|
9188
9253
|
var n;
|
|
9189
|
-
if (!
|
|
9254
|
+
if (!Ym) {
|
|
9190
9255
|
let r;
|
|
9191
9256
|
if ((n = e == null ? void 0 : e.textDiff) != null && n.diffMatchPatch) r = new e.textDiff.diffMatchPatch();
|
|
9192
9257
|
else {
|
|
@@ -9194,7 +9259,7 @@ function Gm(e, t) {
|
|
|
9194
9259
|
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.");
|
|
9195
9260
|
throw e.diff_match_patch_not_found = !0, e;
|
|
9196
9261
|
}
|
|
9197
|
-
|
|
9262
|
+
Ym = {
|
|
9198
9263
|
diff: (e, t) => r.patch_toText(r.patch_make(e, t)),
|
|
9199
9264
|
patch: (e, t) => {
|
|
9200
9265
|
let n = r.patch_apply(r.patch_fromText(t), e);
|
|
@@ -9206,17 +9271,17 @@ function Gm(e, t) {
|
|
|
9206
9271
|
}
|
|
9207
9272
|
};
|
|
9208
9273
|
}
|
|
9209
|
-
return
|
|
9274
|
+
return Ym;
|
|
9210
9275
|
}
|
|
9211
|
-
var
|
|
9276
|
+
var Zm = function(e) {
|
|
9212
9277
|
var t, n;
|
|
9213
9278
|
if (e.leftType !== "string") return;
|
|
9214
|
-
let r = e.left, i = e.right, a = ((n = (t = e.options) == null ? void 0 : t.textDiff) == null ? void 0 : n.minLength) ||
|
|
9279
|
+
let r = e.left, i = e.right, a = ((n = (t = e.options) == null ? void 0 : t.textDiff) == null ? void 0 : n.minLength) || Jm;
|
|
9215
9280
|
if (r.length < a || i.length < a) {
|
|
9216
9281
|
e.setResult([r, i]).exit();
|
|
9217
9282
|
return;
|
|
9218
9283
|
}
|
|
9219
|
-
let o =
|
|
9284
|
+
let o = Xm(e.options);
|
|
9220
9285
|
if (!o) {
|
|
9221
9286
|
e.setResult([r, i]).exit();
|
|
9222
9287
|
return;
|
|
@@ -9225,19 +9290,19 @@ var Km = function(e) {
|
|
|
9225
9290
|
e.setResult([
|
|
9226
9291
|
s(r, i),
|
|
9227
9292
|
0,
|
|
9228
|
-
|
|
9293
|
+
qm
|
|
9229
9294
|
]).exit();
|
|
9230
9295
|
};
|
|
9231
|
-
|
|
9232
|
-
var
|
|
9296
|
+
Zm.filterName = "texts";
|
|
9297
|
+
var Qm = function(e) {
|
|
9233
9298
|
if (e.nested) return;
|
|
9234
9299
|
let t = e.delta;
|
|
9235
|
-
if (t[2] !==
|
|
9236
|
-
let n = t, r =
|
|
9300
|
+
if (t[2] !== qm) return;
|
|
9301
|
+
let n = t, r = Xm(e.options, !0).patch;
|
|
9237
9302
|
e.setResult(r(e.left, n[0])).exit();
|
|
9238
9303
|
};
|
|
9239
|
-
|
|
9240
|
-
var
|
|
9304
|
+
Qm.filterName = "texts";
|
|
9305
|
+
var $m = (e) => {
|
|
9241
9306
|
var t, n, r;
|
|
9242
9307
|
let i = /^@@ +-(\d+),(\d+) +\+(\d+),(\d+) +@@$/, a = e.split("\n");
|
|
9243
9308
|
for (let e = 0; e < a.length; e++) {
|
|
@@ -9258,21 +9323,21 @@ var Jm = (e) => {
|
|
|
9258
9323
|
} else s === "-" && (a[e] = `+${(r = a[e]) == null ? void 0 : r.slice(1)}`);
|
|
9259
9324
|
}
|
|
9260
9325
|
return a.join("\n");
|
|
9261
|
-
},
|
|
9326
|
+
}, eh = function(e) {
|
|
9262
9327
|
if (e.nested) return;
|
|
9263
9328
|
let t = e.delta;
|
|
9264
|
-
if (t[2] !==
|
|
9329
|
+
if (t[2] !== qm) return;
|
|
9265
9330
|
let n = t;
|
|
9266
9331
|
e.setResult([
|
|
9267
|
-
|
|
9332
|
+
$m(n[0]),
|
|
9268
9333
|
0,
|
|
9269
|
-
|
|
9334
|
+
qm
|
|
9270
9335
|
]).exit();
|
|
9271
9336
|
};
|
|
9272
|
-
|
|
9337
|
+
eh.filterName = "texts";
|
|
9273
9338
|
//#endregion
|
|
9274
9339
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/trivial.js
|
|
9275
|
-
var
|
|
9340
|
+
var th = function(e) {
|
|
9276
9341
|
if (e.left === e.right) {
|
|
9277
9342
|
e.setResult(void 0).exit();
|
|
9278
9343
|
return;
|
|
@@ -9305,8 +9370,8 @@ var Xm = function(e) {
|
|
|
9305
9370
|
}
|
|
9306
9371
|
e.left instanceof RegExp && (e.right instanceof RegExp ? e.setResult([e.left.toString(), e.right.toString()]).exit() : e.setResult([e.left, e.right]).exit());
|
|
9307
9372
|
};
|
|
9308
|
-
|
|
9309
|
-
var
|
|
9373
|
+
th.filterName = "trivial";
|
|
9374
|
+
var nh = function(e) {
|
|
9310
9375
|
if (e.delta === void 0) {
|
|
9311
9376
|
e.setResult(e.left).exit();
|
|
9312
9377
|
return;
|
|
@@ -9330,8 +9395,8 @@ var Zm = function(e) {
|
|
|
9330
9395
|
}
|
|
9331
9396
|
t.length === 3 && t[2] === 0 && e.setResult(void 0).exit();
|
|
9332
9397
|
};
|
|
9333
|
-
|
|
9334
|
-
var
|
|
9398
|
+
nh.filterName = "trivial";
|
|
9399
|
+
var rh = function(e) {
|
|
9335
9400
|
if (e.delta === void 0) {
|
|
9336
9401
|
e.setResult(e.delta).exit();
|
|
9337
9402
|
return;
|
|
@@ -9352,36 +9417,36 @@ var Qm = function(e) {
|
|
|
9352
9417
|
}
|
|
9353
9418
|
t.length === 3 && t[2] === 0 && e.setResult([t[0]]).exit();
|
|
9354
9419
|
};
|
|
9355
|
-
|
|
9420
|
+
rh.filterName = "trivial";
|
|
9356
9421
|
//#endregion
|
|
9357
9422
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/diffpatcher.js
|
|
9358
|
-
var
|
|
9423
|
+
var ih = class {
|
|
9359
9424
|
constructor(e) {
|
|
9360
|
-
this.processor = new
|
|
9425
|
+
this.processor = new wm(e), this.processor.pipe(new Cm("diff").append(Vm, th, zm, Zm, Hm, Mm).shouldHaveResult()), this.processor.pipe(new Cm("patch").append(Wm, Fm, nh, Qm, Um, Pm).shouldHaveResult()), this.processor.pipe(new Cm("reverse").append(Km, Rm, rh, eh, Gm, Im).shouldHaveResult());
|
|
9361
9426
|
}
|
|
9362
9427
|
options(e) {
|
|
9363
9428
|
return this.processor.options(e);
|
|
9364
9429
|
}
|
|
9365
9430
|
diff(e, t) {
|
|
9366
|
-
return this.processor.process(new
|
|
9431
|
+
return this.processor.process(new bm(e, t));
|
|
9367
9432
|
}
|
|
9368
9433
|
patch(e, t) {
|
|
9369
|
-
return this.processor.process(new
|
|
9434
|
+
return this.processor.process(new xm(e, t));
|
|
9370
9435
|
}
|
|
9371
9436
|
reverse(e) {
|
|
9372
|
-
return this.processor.process(new
|
|
9437
|
+
return this.processor.process(new Sm(e));
|
|
9373
9438
|
}
|
|
9374
9439
|
unpatch(e, t) {
|
|
9375
9440
|
return this.patch(e, this.reverse(t));
|
|
9376
9441
|
}
|
|
9377
9442
|
clone(e) {
|
|
9378
|
-
return
|
|
9443
|
+
return gm(e);
|
|
9379
9444
|
}
|
|
9380
9445
|
};
|
|
9381
9446
|
//#endregion
|
|
9382
9447
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/index.js
|
|
9383
|
-
function
|
|
9384
|
-
return new
|
|
9448
|
+
function ah(e) {
|
|
9449
|
+
return new ih(e);
|
|
9385
9450
|
}
|
|
9386
9451
|
//#endregion
|
|
9387
9452
|
//#region node_modules/.pnpm/@dmsnell+diff-match-patch@1.1.0/node_modules/@dmsnell/diff-match-patch/index.js
|
|
@@ -9943,46 +10008,46 @@ $.Diff = function(e, t) {
|
|
|
9943
10008
|
};
|
|
9944
10009
|
//#endregion
|
|
9945
10010
|
//#region src/components/audit-log/create-diff-patcher.tsx
|
|
9946
|
-
var
|
|
10011
|
+
var oh = (e = {}) => ah({
|
|
9947
10012
|
...e,
|
|
9948
10013
|
textDiff: {
|
|
9949
10014
|
diffMatchPatch: $,
|
|
9950
10015
|
minLength: 120
|
|
9951
10016
|
},
|
|
9952
10017
|
cloneDiffValues: !0
|
|
9953
|
-
}),
|
|
10018
|
+
}), sh = ["user", "unittemplate"], ch = oh(), lh = (e, t, n) => {
|
|
9954
10019
|
let r = Object.fromEntries(e.map((e) => [e.sectionKey, e.sectionLabel]));
|
|
9955
10020
|
for (let e = t.length - 1; e >= 0; e--) {
|
|
9956
10021
|
let n = r[t[e]];
|
|
9957
10022
|
if (n) return n;
|
|
9958
10023
|
}
|
|
9959
10024
|
return n || "";
|
|
9960
|
-
},
|
|
10025
|
+
}, uh = (e) => {
|
|
9961
10026
|
let t = (e) => rr(e) ? hr(e) : String(e);
|
|
9962
10027
|
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);
|
|
9963
|
-
},
|
|
10028
|
+
}, dh = (e) => {
|
|
9964
10029
|
switch (e.length) {
|
|
9965
10030
|
case 1: {
|
|
9966
10031
|
let [t] = e;
|
|
9967
10032
|
return {
|
|
9968
10033
|
type: "created",
|
|
9969
10034
|
before: "",
|
|
9970
|
-
after:
|
|
10035
|
+
after: uh(t)
|
|
9971
10036
|
};
|
|
9972
10037
|
}
|
|
9973
10038
|
case 2: {
|
|
9974
10039
|
let [t, n] = e;
|
|
9975
10040
|
return {
|
|
9976
10041
|
type: "modified",
|
|
9977
|
-
before:
|
|
9978
|
-
after:
|
|
10042
|
+
before: uh(t),
|
|
10043
|
+
after: uh(n)
|
|
9979
10044
|
};
|
|
9980
10045
|
}
|
|
9981
10046
|
case 3: {
|
|
9982
10047
|
let [t] = e;
|
|
9983
10048
|
return {
|
|
9984
10049
|
type: "deleted",
|
|
9985
|
-
before:
|
|
10050
|
+
before: uh(t),
|
|
9986
10051
|
after: ""
|
|
9987
10052
|
};
|
|
9988
10053
|
}
|
|
@@ -9992,15 +10057,15 @@ var th = (e = {}) => eh({
|
|
|
9992
10057
|
after: ""
|
|
9993
10058
|
};
|
|
9994
10059
|
}
|
|
9995
|
-
},
|
|
9996
|
-
let r =
|
|
10060
|
+
}, fh = (e) => Array.isArray(e), ph = (e, t) => t ? fh(t) ? t.length === 0 ? e : t.reduce((e, t) => ch.unpatch(nn(e), nn(t)), nn(e)) : ch.unpatch(nn(e), nn(t)) : e, mh = (e) => e.createdAt || e.date, hh = (e, t, n) => {
|
|
10061
|
+
let r = mh(e);
|
|
9997
10062
|
if (!r) return {
|
|
9998
10063
|
oldJson: "",
|
|
9999
10064
|
newJson: "",
|
|
10000
10065
|
error: `Cannot create comparison view: missing date for audit log ${e.id}`
|
|
10001
10066
|
};
|
|
10002
10067
|
let i = t.filter((e) => {
|
|
10003
|
-
let t =
|
|
10068
|
+
let t = mh(e);
|
|
10004
10069
|
return !!(e.diffs && t && t >= r);
|
|
10005
10070
|
}), a = Array.from({ length: i.length + 1 });
|
|
10006
10071
|
a[0] = nn(n);
|
|
@@ -10013,7 +10078,7 @@ var th = (e = {}) => eh({
|
|
|
10013
10078
|
a[e + 1] = a[e];
|
|
10014
10079
|
continue;
|
|
10015
10080
|
}
|
|
10016
|
-
a[e + 1] =
|
|
10081
|
+
a[e + 1] = ph(a[e], t);
|
|
10017
10082
|
}
|
|
10018
10083
|
let e = i.length > 0 ? a[i.length - 1] : n, t = i.length > 0 ? a[i.length] : n;
|
|
10019
10084
|
o = JSON.stringify(t == null ? "" : t, null, 2), s = JSON.stringify(e == null ? "" : e, null, 2);
|
|
@@ -10028,10 +10093,10 @@ var th = (e = {}) => eh({
|
|
|
10028
10093
|
oldJson: o,
|
|
10029
10094
|
newJson: s
|
|
10030
10095
|
};
|
|
10031
|
-
},
|
|
10096
|
+
}, gh = (e, t, n = {}, r = []) => {
|
|
10032
10097
|
var i;
|
|
10033
10098
|
if (!e) return;
|
|
10034
|
-
let a = [...
|
|
10099
|
+
let a = [...sh, ...(i = n.hiddenKeys) == null ? [] : i];
|
|
10035
10100
|
Object.keys(e).forEach((i) => {
|
|
10036
10101
|
var o;
|
|
10037
10102
|
let s = e[i];
|
|
@@ -10044,12 +10109,12 @@ var th = (e = {}) => eh({
|
|
|
10044
10109
|
cn(s) ? t.push({
|
|
10045
10110
|
deltaFormat: [...s],
|
|
10046
10111
|
path: c
|
|
10047
|
-
}) : gn(s) &&
|
|
10112
|
+
}) : gn(s) && gh(s, t, n, c);
|
|
10048
10113
|
});
|
|
10049
|
-
},
|
|
10114
|
+
}, _h = (e, t = {}) => {
|
|
10050
10115
|
let n = [];
|
|
10051
|
-
return e ? (
|
|
10052
|
-
},
|
|
10116
|
+
return e ? (gh(e, n, t), n) : [];
|
|
10117
|
+
}, vh = (e) => e.replace(/\[\d+\]/g, "").replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/[_-]/g, " ").replace(/\s+/g, " ").trim().replace(/^./, (e) => e.toUpperCase()), yh = (e) => {
|
|
10053
10118
|
if (e == null || e === "") return "empty";
|
|
10054
10119
|
if (typeof e == "boolean") return e ? "true" : "false";
|
|
10055
10120
|
if (typeof e == "string") return e;
|
|
@@ -10060,27 +10125,27 @@ var th = (e = {}) => eh({
|
|
|
10060
10125
|
} catch {
|
|
10061
10126
|
return String(e);
|
|
10062
10127
|
}
|
|
10063
|
-
},
|
|
10128
|
+
}, bh = (e, t = e.length - 1) => {
|
|
10064
10129
|
if (t >= e.length) return "Value";
|
|
10065
10130
|
let n = e[t];
|
|
10066
|
-
return !n || er(n) ?
|
|
10067
|
-
},
|
|
10068
|
-
let o =
|
|
10131
|
+
return !n || er(n) ? bh(e, t - 1) : vh(n);
|
|
10132
|
+
}, xh = ({ userName: e, type: t, property: n, before: r, after: i, sectionName: a }) => {
|
|
10133
|
+
let o = yh(r), s = yh(i), c = a ? ` in ${a}` : "";
|
|
10069
10134
|
switch (t) {
|
|
10070
10135
|
case "modified": return `${e} updated ${n} from ${o} to ${s}${c}.`;
|
|
10071
10136
|
case "created": return `${e} created ${s}${c}.`;
|
|
10072
10137
|
case "deleted": return `${e} deleted ${o}${c}.`;
|
|
10073
10138
|
default: return `${e} changed ${n}${c}.`;
|
|
10074
10139
|
}
|
|
10075
|
-
},
|
|
10140
|
+
}, Sh = ({ sectionNames: e, userName: t, diffs: n, defaultSectionName: r }) => {
|
|
10076
10141
|
let i = {
|
|
10077
10142
|
headers: [{ cells: [{ value: "Changes" }] }],
|
|
10078
10143
|
rows: n.map((n) => {
|
|
10079
|
-
let { deltaFormat: i, path: a } = n, o =
|
|
10080
|
-
return { cells: [{ value:
|
|
10144
|
+
let { deltaFormat: i, path: a } = n, o = lh(e, a, r), { type: s, before: c, after: l } = dh(i);
|
|
10145
|
+
return { cells: [{ value: xh({
|
|
10081
10146
|
userName: t,
|
|
10082
10147
|
type: s,
|
|
10083
|
-
property:
|
|
10148
|
+
property: bh(a),
|
|
10084
10149
|
before: c,
|
|
10085
10150
|
after: l,
|
|
10086
10151
|
sectionName: o
|
|
@@ -10088,7 +10153,7 @@ var th = (e = {}) => eh({
|
|
|
10088
10153
|
})
|
|
10089
10154
|
};
|
|
10090
10155
|
return /* @__PURE__ */ S($l, { table: i });
|
|
10091
|
-
},
|
|
10156
|
+
}, Ch = Object.freeze({
|
|
10092
10157
|
summary: {
|
|
10093
10158
|
label: "Summary",
|
|
10094
10159
|
value: "summary"
|
|
@@ -10097,13 +10162,13 @@ var th = (e = {}) => eh({
|
|
|
10097
10162
|
label: "Compare",
|
|
10098
10163
|
value: "compare"
|
|
10099
10164
|
}
|
|
10100
|
-
}),
|
|
10101
|
-
let c = [
|
|
10165
|
+
}), wh = ({ auditLog: e, auditLogs: t, data: n, isOpen: r, transformDiffsConfig: i, sectionNames: a, defaultSectionName: o, onClose: s }) => {
|
|
10166
|
+
let c = [Ch.summary, Ch.compare].map(({ label: e, value: t }) => ({
|
|
10102
10167
|
label: e,
|
|
10103
10168
|
value: t
|
|
10104
10169
|
})), [l, u] = v(c[0]), { diffs: d = void 0 } = e || {};
|
|
10105
10170
|
if (!d) return null;
|
|
10106
|
-
let { oldJson: f, newJson: p, error: m } =
|
|
10171
|
+
let { oldJson: f, newJson: p, error: m } = hh(e, t, n);
|
|
10107
10172
|
return /* @__PURE__ */ S(xs, {
|
|
10108
10173
|
visible: r,
|
|
10109
10174
|
centered: !0,
|
|
@@ -10111,20 +10176,20 @@ var th = (e = {}) => eh({
|
|
|
10111
10176
|
children: /* @__PURE__ */ S($o, { dialog: {
|
|
10112
10177
|
scroll: !0,
|
|
10113
10178
|
heading: "Comparison view",
|
|
10114
|
-
content: /* @__PURE__ */ C(x, { children: [/* @__PURE__ */ S(
|
|
10179
|
+
content: /* @__PURE__ */ C(x, { children: [/* @__PURE__ */ S(op, {
|
|
10115
10180
|
name: "ViewTab",
|
|
10116
10181
|
onChange: (e) => u(c.find((t) => t.value === e.target.value)),
|
|
10117
10182
|
options: c,
|
|
10118
10183
|
value: l
|
|
10119
|
-
}), l.value === "summary" ? /* @__PURE__ */ S(
|
|
10184
|
+
}), l.value === "summary" ? /* @__PURE__ */ S(Sh, {
|
|
10120
10185
|
userName: e.userName,
|
|
10121
10186
|
sectionNames: a,
|
|
10122
|
-
diffs:
|
|
10187
|
+
diffs: _h(d, i),
|
|
10123
10188
|
defaultSectionName: o
|
|
10124
10189
|
}) : m ? /* @__PURE__ */ S("div", {
|
|
10125
10190
|
style: { padding: 16 },
|
|
10126
10191
|
children: m
|
|
10127
|
-
}) : /* @__PURE__ */ S(
|
|
10192
|
+
}) : /* @__PURE__ */ S(om, {
|
|
10128
10193
|
oldJson: f,
|
|
10129
10194
|
newJson: p
|
|
10130
10195
|
})] }),
|
|
@@ -10137,7 +10202,7 @@ var th = (e = {}) => eh({
|
|
|
10137
10202
|
height: "90vh"
|
|
10138
10203
|
} })
|
|
10139
10204
|
});
|
|
10140
|
-
},
|
|
10205
|
+
}, Th = [
|
|
10141
10206
|
{
|
|
10142
10207
|
label: "10 / page",
|
|
10143
10208
|
value: 10
|
|
@@ -10150,15 +10215,15 @@ var th = (e = {}) => eh({
|
|
|
10150
10215
|
label: "50 / page",
|
|
10151
10216
|
value: 50
|
|
10152
10217
|
}
|
|
10153
|
-
],
|
|
10154
|
-
let { diffs: r, userName: i, source: a, operation: o, operationMetaData: s } = e, c =
|
|
10218
|
+
], Eh = (e, t, n = {}) => {
|
|
10219
|
+
let { diffs: r, userName: i, source: a, operation: o, operationMetaData: s } = e, c = _h(r, n).length, l = c ? `${c} change${c === 1 ? "" : "s"}` : "no field changes";
|
|
10155
10220
|
if (a === "API" && !i) return o === "Created" ? "Created through API" : "Changed through API";
|
|
10156
10221
|
switch (o) {
|
|
10157
10222
|
case "Created": return "Created";
|
|
10158
10223
|
case "Cloned": return `Cloned (from design ID ${s})`;
|
|
10159
10224
|
case "Reverted": {
|
|
10160
|
-
let e = t.find((e) => e.id === s), n = e ?
|
|
10161
|
-
date:
|
|
10225
|
+
let e = t.find((e) => e.id === s), n = e ? mm({
|
|
10226
|
+
date: mh(e),
|
|
10162
10227
|
showTime: !0
|
|
10163
10228
|
}) : null;
|
|
10164
10229
|
return `Reverted${n ? ` (to ${n})` : ""}`;
|
|
@@ -10168,7 +10233,7 @@ var th = (e = {}) => eh({
|
|
|
10168
10233
|
case "Updated": return `Updated (${l})`;
|
|
10169
10234
|
default: return "Updated";
|
|
10170
10235
|
}
|
|
10171
|
-
},
|
|
10236
|
+
}, 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, onClickNavigateToDesgin: g }) => {
|
|
10172
10237
|
let [_, y] = v(!1), [b, w] = v(null), T = (e) => {
|
|
10173
10238
|
if (e.snapshot) {
|
|
10174
10239
|
f == null || f(e.snapshot, e);
|
|
@@ -10187,7 +10252,7 @@ var th = (e = {}) => eh({
|
|
|
10187
10252
|
return {
|
|
10188
10253
|
cells: [
|
|
10189
10254
|
{
|
|
10190
|
-
value: t.snapshot ? `Snapshot: ${t.snapshot}` :
|
|
10255
|
+
value: t.snapshot ? `Snapshot: ${t.snapshot}` : Eh(t, e, l),
|
|
10191
10256
|
type: "Link",
|
|
10192
10257
|
disabled: a,
|
|
10193
10258
|
onClick: a ? void 0 : r && g ? () => g(t.operationMetaData) : () => T(t),
|
|
@@ -10206,8 +10271,8 @@ var th = (e = {}) => eh({
|
|
|
10206
10271
|
type: "Static"
|
|
10207
10272
|
},
|
|
10208
10273
|
{
|
|
10209
|
-
value:
|
|
10210
|
-
date:
|
|
10274
|
+
value: mm({
|
|
10275
|
+
date: mh(t),
|
|
10211
10276
|
showTime: !0
|
|
10212
10277
|
}),
|
|
10213
10278
|
type: "Static"
|
|
@@ -10250,14 +10315,14 @@ var th = (e = {}) => eh({
|
|
|
10250
10315
|
onChange: (e) => {
|
|
10251
10316
|
u(Number(e.target.value));
|
|
10252
10317
|
},
|
|
10253
|
-
options:
|
|
10318
|
+
options: Th,
|
|
10254
10319
|
value: a
|
|
10255
10320
|
},
|
|
10256
10321
|
onSelectPage: (e) => d(e),
|
|
10257
10322
|
small: !0
|
|
10258
10323
|
} }
|
|
10259
10324
|
} })
|
|
10260
|
-
}), _ && b && b.diffs && /* @__PURE__ */ S(
|
|
10325
|
+
}), _ && b && b.diffs && /* @__PURE__ */ S(wh, {
|
|
10261
10326
|
sectionNames: o,
|
|
10262
10327
|
isOpen: _,
|
|
10263
10328
|
onClose: () => y(!1),
|
|
@@ -10267,7 +10332,7 @@ var th = (e = {}) => eh({
|
|
|
10267
10332
|
data: t,
|
|
10268
10333
|
transformDiffsConfig: l
|
|
10269
10334
|
})] });
|
|
10270
|
-
},
|
|
10335
|
+
}, Oh = ({ pathName: e, moduleName: t, onNavigate: n, onStartTimingEvent: r }) => {
|
|
10271
10336
|
let i = window.location.href, a = _(i);
|
|
10272
10337
|
return d(() => {
|
|
10273
10338
|
a.current = i;
|
|
@@ -10290,20 +10355,20 @@ var th = (e = {}) => eh({
|
|
|
10290
10355
|
});
|
|
10291
10356
|
};
|
|
10292
10357
|
}, [e, t]), null;
|
|
10293
|
-
},
|
|
10358
|
+
}, kh = {
|
|
10294
10359
|
errorBoundary: "_errorBoundary_hmco0_1",
|
|
10295
10360
|
sidebarErrorBoundary: "_sidebarErrorBoundary_hmco0_5",
|
|
10296
10361
|
rightSidebarErrorBoundary: "_rightSidebarErrorBoundary_hmco0_6"
|
|
10297
|
-
},
|
|
10298
|
-
let { ErrorComponent: t, isSideBar: n, isRightSideBar: r, isPage: i, style: a } = e == null ? {} : e, { translations: o } =
|
|
10362
|
+
}, Ah = ({ options: e }) => {
|
|
10363
|
+
let { ErrorComponent: t, isSideBar: n, isRightSideBar: r, isPage: i, style: a } = e == null ? {} : e, { translations: o } = Vp();
|
|
10299
10364
|
if (t) return /* @__PURE__ */ S(t, {});
|
|
10300
10365
|
if (n || r) return /* @__PURE__ */ S("div", {
|
|
10301
|
-
className: b(n ?
|
|
10366
|
+
className: b(n ? kh.sidebarErrorBoundary : "", r ? kh.rightSidebarErrorBoundary : ""),
|
|
10302
10367
|
style: a,
|
|
10303
10368
|
children: o == null ? void 0 : o.unexpectedError
|
|
10304
10369
|
});
|
|
10305
10370
|
let s = /* @__PURE__ */ S("div", {
|
|
10306
|
-
className:
|
|
10371
|
+
className: kh.errorBoundary,
|
|
10307
10372
|
style: a,
|
|
10308
10373
|
children: /* @__PURE__ */ S(Vs, { message: {
|
|
10309
10374
|
icon: !0,
|
|
@@ -10318,19 +10383,19 @@ var th = (e = {}) => eh({
|
|
|
10318
10383
|
padding: 0,
|
|
10319
10384
|
children: s
|
|
10320
10385
|
}) : s;
|
|
10321
|
-
},
|
|
10322
|
-
fallback: /* @__PURE__ */ S(
|
|
10386
|
+
}, jh = ({ children: e, options: t }) => /* @__PURE__ */ S(Oi.ErrorBoundary, {
|
|
10387
|
+
fallback: /* @__PURE__ */ S(Ah, { options: t }),
|
|
10323
10388
|
onError: (e, t) => {
|
|
10324
10389
|
console.error("Error caught by boundary:", e, t);
|
|
10325
10390
|
},
|
|
10326
10391
|
children: e
|
|
10327
|
-
}),
|
|
10392
|
+
}), Mh = (e, t = {}) => (n) => /* @__PURE__ */ S(jh, {
|
|
10328
10393
|
options: t,
|
|
10329
10394
|
children: /* @__PURE__ */ S(e, { ...n })
|
|
10330
|
-
}),
|
|
10331
|
-
Lp
|
|
10332
|
-
e ===
|
|
10395
|
+
}), Nh = (e = {}) => (t) => Mh(t, e), Ph = (e) => typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === null, Fh = (e) => {
|
|
10396
|
+
Hp(Lp.LanguageKey, e.languageKey), Object.entries(e).forEach(([e, t]) => {
|
|
10397
|
+
e === Lp.Translations ? Hp(e, zp(t)) : Hp(e, Ph(t) ? t : { ...t });
|
|
10333
10398
|
});
|
|
10334
10399
|
};
|
|
10335
10400
|
//#endregion
|
|
10336
|
-
export { $i as Accordion, ka as AccordionWithDefaultToggle, so as Actions, ji as Align,
|
|
10401
|
+
export { $i as Accordion, ka as AccordionWithDefaultToggle, so as Actions, ji as Align, Dh as AuditLog, Qa as Badge, fo as Breadcrumb, lo as BreadcrumbLinkType, q as Button, mo as ButtonGroup, Mi as ButtonPosition, Na as ButtonType, go as Card, Ta as CheckBox, qi as Chevron, Xi as Collapse, Ai as Color, Lo as ColorInput, Io as ColorInputPopover, Ho as Column, $o as Dialog, nm as DiffCode, pm as DiffTable, om as DiffViewer, W as DisabledContext, qo as Divider, os as Drawer, pp as ElementType, uu as Empty, jh as ErrorBoundary, vd as Field, md as FileButton, gs as FileInput, yd as Flex, xd as FormRow, So as Grid, H as GroupOrder, Xo as Heading, wa as HelpIcon, G as Icon, U as IconType, ds as Input, ls as InputGroup, rl as InputGroupAddon, ps as InputReaderMethods, Fi as InputType, gd as Label, Pd as List, Cd as ListHeading, kd as ListSubheading, Id as Loader, yf as Mention, ao as Menu, Ha as MenuCarat, Va as MenuType, Vs as Message, Fs as MessageType, xs as Modal, qs as NativeSelect, vl as NumberInput, Ud as OptionDropdown, Gd as Page, il as Pagination, yp as PopConfirm, vo as Popover, Kd as Portal, Jd as PrintHeader, ws as ProgressBar, Yd as RadioButton, Ef as Resizable, vf as RichTextInput, xf as Row, Zc as Select, Yp as SettingField, jf as SideBar, Nf as Skeleton, Ol as Slider, ks as SmartUploadModal, _s as Spacer, Ma as Spinner, $l as Table, pd as TableImportExport, op as Tabs, Go as Text, lp as TextArea, sp as TextLink, Ni as TextTransform, Pi as Theme, Gr as Toaster, Zu as Toggle, K as Tooltip, gp as TopBar, wp as Tree, Ip as TreeTable, ki as TriggerType, $f as UnitInput, rp as UnitSlider, qp as UnitTable, Oh as UsageTracker, Ju as dismissToast, Xf as initializeContext, Fh as initializeGuiLibrary, ms as readFile, qu as toast, Js as useFocus, vs as useKeyboardEvent, Zs as useWindowWidth, Nh as withChainableErrorBoundary, Mh as withErrorBoundary };
|