@oliasoft-open-source/react-ui-library 10.3.1 → 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 +23 -1
- package/dist/index.js +472 -406
- 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,76 +7539,77 @@ 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 }),
|
|
7478
|
-
tabs: "
|
|
7479
|
-
padding: "
|
|
7480
|
-
margin: "
|
|
7481
|
-
contentPadding: "
|
|
7482
|
-
item: "
|
|
7483
|
-
|
|
7484
|
-
|
|
7485
|
-
|
|
7486
|
-
|
|
7487
|
-
|
|
7542
|
+
}) : /* @__PURE__ */ S(x, { children: e }), ap = {
|
|
7543
|
+
tabs: "_tabs_1olt8_1",
|
|
7544
|
+
padding: "_padding_1olt8_7",
|
|
7545
|
+
margin: "_margin_1olt8_11",
|
|
7546
|
+
contentPadding: "_contentPadding_1olt8_14",
|
|
7547
|
+
item: "_item_1olt8_17",
|
|
7548
|
+
small: "_small_1olt8_35",
|
|
7549
|
+
left: "_left_1olt8_67",
|
|
7550
|
+
right: "_right_1olt8_67",
|
|
7551
|
+
selectionIndicator: "_selectionIndicator_1olt8_70"
|
|
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 }) => {
|
|
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) => {
|
|
7488
7554
|
var t;
|
|
7489
|
-
return (t = e.component) == null ?
|
|
7490
|
-
},
|
|
7555
|
+
return (t = e.component) == null ? c : t;
|
|
7556
|
+
}, g = (e) => !!(e.to && h(e)), _ = (t) => {
|
|
7491
7557
|
var n;
|
|
7492
|
-
let i = (n =
|
|
7558
|
+
let i = (n = f == null ? void 0 : f.findIndex((e) => e.value === t)) == null ? -1 : n;
|
|
7493
7559
|
if (i === -1) return;
|
|
7494
|
-
let a =
|
|
7495
|
-
a.disabled ||
|
|
7560
|
+
let a = f[i];
|
|
7561
|
+
a.disabled || l || r({ target: {
|
|
7496
7562
|
name: e == null ? "" : e,
|
|
7497
7563
|
value: a.value,
|
|
7498
7564
|
label: String(a.label)
|
|
7499
7565
|
} });
|
|
7500
|
-
},
|
|
7501
|
-
let t =
|
|
7502
|
-
t &&
|
|
7503
|
-
},
|
|
7504
|
-
e.metaKey || e.ctrlKey || e.altKey || e.shiftKey ||
|
|
7505
|
-
},
|
|
7506
|
-
let { label: t, url: n, to: r, disabled: i, value: a, right:
|
|
7566
|
+
}, v = (e) => {
|
|
7567
|
+
let t = f == null ? void 0 : f.find((t) => g(t) && t.to === e);
|
|
7568
|
+
t && _(t.value);
|
|
7569
|
+
}, y = (e, t) => {
|
|
7570
|
+
e.metaKey || e.ctrlKey || e.altKey || e.shiftKey || _(t);
|
|
7571
|
+
}, x = f.filter((e) => !e.hidden || e.value === m), w = f.some(g), T = (e) => {
|
|
7572
|
+
let { label: t, url: n, to: r, disabled: i, value: a, right: s, invalid: c, badge: u, testId: d } = e, f = g(e), p = h(e), m = f ? r : n;
|
|
7507
7573
|
return /* @__PURE__ */ C(yi, {
|
|
7508
7574
|
id: a,
|
|
7509
|
-
...
|
|
7575
|
+
...m ? { href: m } : {},
|
|
7510
7576
|
shouldSelectOnPressUp: !0,
|
|
7511
|
-
isDisabled: i ||
|
|
7512
|
-
className: b(
|
|
7513
|
-
"data-testid":
|
|
7514
|
-
render:
|
|
7577
|
+
isDisabled: i || l,
|
|
7578
|
+
className: b(ap.item, s ? ap.right : ap.left, o ? ap.small : ""),
|
|
7579
|
+
"data-testid": d,
|
|
7580
|
+
render: f && p ? (e) => "href" in e ? /* @__PURE__ */ S(p, {
|
|
7515
7581
|
...e,
|
|
7516
7582
|
to: r,
|
|
7517
7583
|
onClick: (t) => {
|
|
7518
7584
|
var n;
|
|
7519
|
-
(n = e.onClick) == null || n.call(e, t),
|
|
7585
|
+
(n = e.onClick) == null || n.call(e, t), y(t, a);
|
|
7520
7586
|
}
|
|
7521
7587
|
}) : /* @__PURE__ */ S("div", { ...e }) : void 0,
|
|
7522
|
-
children: [/* @__PURE__ */ S(
|
|
7588
|
+
children: [/* @__PURE__ */ S(ip, {
|
|
7523
7589
|
label: t,
|
|
7524
|
-
invalid:
|
|
7525
|
-
badge:
|
|
7526
|
-
}), /* @__PURE__ */ S(vi, { className:
|
|
7590
|
+
invalid: c,
|
|
7591
|
+
badge: u
|
|
7592
|
+
}), /* @__PURE__ */ S(vi, { className: ap.selectionIndicator })]
|
|
7527
7593
|
}, a);
|
|
7528
7594
|
};
|
|
7529
|
-
if (
|
|
7595
|
+
if (f) {
|
|
7530
7596
|
let t = /* @__PURE__ */ S(xi, {
|
|
7531
|
-
selectedKey:
|
|
7532
|
-
onSelectionChange:
|
|
7533
|
-
"data-testid":
|
|
7597
|
+
selectedKey: m,
|
|
7598
|
+
onSelectionChange: _,
|
|
7599
|
+
"data-testid": s,
|
|
7534
7600
|
children: /* @__PURE__ */ S(bi, {
|
|
7535
7601
|
"aria-label": e == null ? "Tabs" : e,
|
|
7536
|
-
className: b(
|
|
7537
|
-
children:
|
|
7602
|
+
className: b(ap.tabs, i ? ap.padding : "", a ? ap.margin : ""),
|
|
7603
|
+
children: x.map(T)
|
|
7538
7604
|
})
|
|
7539
7605
|
});
|
|
7540
|
-
return
|
|
7541
|
-
navigate:
|
|
7606
|
+
return w ? /* @__PURE__ */ S(Yt, {
|
|
7607
|
+
navigate: v,
|
|
7542
7608
|
children: t
|
|
7543
7609
|
}) : t;
|
|
7544
7610
|
}
|
|
7545
7611
|
return null;
|
|
7546
|
-
},
|
|
7612
|
+
}, sp = ({ children: e, href: t = void 0, target: n = void 0, testId: r, onClick: i, component: a = "a" }) => /* @__PURE__ */ S(a, {
|
|
7547
7613
|
href: t,
|
|
7548
7614
|
to: t,
|
|
7549
7615
|
target: n,
|
|
@@ -7553,7 +7619,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7553
7619
|
link: !0,
|
|
7554
7620
|
children: e
|
|
7555
7621
|
})
|
|
7556
|
-
}),
|
|
7622
|
+
}), cp = {
|
|
7557
7623
|
inputInTable: "_inputInTable_qbe2o_1",
|
|
7558
7624
|
inputHover: "_inputHover_qbe2o_13",
|
|
7559
7625
|
inputFocus: "_inputFocus_qbe2o_18",
|
|
@@ -7565,9 +7631,9 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7565
7631
|
textarea: "_textarea_qbe2o_81",
|
|
7566
7632
|
small: "_small_qbe2o_120",
|
|
7567
7633
|
monospace: "_monospace_qbe2o_159"
|
|
7568
|
-
},
|
|
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 }) => {
|
|
7569
7635
|
let x = u(W), C = /* @__PURE__ */ S("textarea", {
|
|
7570
|
-
className: b(
|
|
7636
|
+
className: b(cp.textarea, f ? cp.error : "", p ? cp.warning : "", _ ? cp.monospace : "", v ? cp.small : ""),
|
|
7571
7637
|
name: e,
|
|
7572
7638
|
value: t,
|
|
7573
7639
|
placeholder: n,
|
|
@@ -7609,10 +7675,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7609
7675
|
menu: "_menu_oyr59_139",
|
|
7610
7676
|
active: "_active_oyr59_168",
|
|
7611
7677
|
alert: "_alert_oyr59_193"
|
|
7612
|
-
},
|
|
7678
|
+
}, up = ({ warning: e }) => /* @__PURE__ */ S("div", {
|
|
7613
7679
|
className: Q.alert,
|
|
7614
7680
|
children: e
|
|
7615
|
-
}),
|
|
7681
|
+
}), dp = ({ icon: e, url: t, onClick: n }) => {
|
|
7616
7682
|
let r = /* @__PURE__ */ S(G, { icon: e });
|
|
7617
7683
|
return t ? /* @__PURE__ */ S("a", {
|
|
7618
7684
|
href: t,
|
|
@@ -7624,7 +7690,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7624
7690
|
className: Q.appSwitcher,
|
|
7625
7691
|
children: r
|
|
7626
7692
|
});
|
|
7627
|
-
},
|
|
7693
|
+
}, fp = ({ label: e, logo: t, url: n, version: r, onClick: i }) => {
|
|
7628
7694
|
let a = /* @__PURE__ */ C("div", {
|
|
7629
7695
|
className: Q.title,
|
|
7630
7696
|
children: [
|
|
@@ -7653,9 +7719,9 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7653
7719
|
children: a
|
|
7654
7720
|
})
|
|
7655
7721
|
});
|
|
7656
|
-
},
|
|
7722
|
+
}, pp = /* @__PURE__ */ function(e) {
|
|
7657
7723
|
return e.LINK = "Link", e.BUTTON = "Button", e.MENU = "Menu", e.COMPONENT = "Component", e;
|
|
7658
|
-
}({}),
|
|
7724
|
+
}({}), mp = ({ label: e, url: t, icon: n, onClick: r, active: i, disabled: a, testId: o, component: s = "a" }) => {
|
|
7659
7725
|
let c = u(W);
|
|
7660
7726
|
return /* @__PURE__ */ C(s, {
|
|
7661
7727
|
className: b(Q.link, i ? Q.active : ""),
|
|
@@ -7672,11 +7738,11 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7672
7738
|
children: e
|
|
7673
7739
|
})]
|
|
7674
7740
|
});
|
|
7675
|
-
},
|
|
7741
|
+
}, hp = ({ element: e }) => {
|
|
7676
7742
|
switch (e.type) {
|
|
7677
|
-
case
|
|
7743
|
+
case pp.LINK: return /* @__PURE__ */ S("div", {
|
|
7678
7744
|
className: Q.item,
|
|
7679
|
-
children: /* @__PURE__ */ S(
|
|
7745
|
+
children: /* @__PURE__ */ S(mp, {
|
|
7680
7746
|
label: e.label,
|
|
7681
7747
|
url: e.url,
|
|
7682
7748
|
icon: e.icon,
|
|
@@ -7687,7 +7753,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7687
7753
|
component: e.component
|
|
7688
7754
|
})
|
|
7689
7755
|
});
|
|
7690
|
-
case
|
|
7756
|
+
case pp.BUTTON: return /* @__PURE__ */ S("div", {
|
|
7691
7757
|
className: b(Q.item, Q.button),
|
|
7692
7758
|
children: /* @__PURE__ */ S(q, {
|
|
7693
7759
|
label: e.label,
|
|
@@ -7699,14 +7765,14 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7699
7765
|
testId: e.testId
|
|
7700
7766
|
})
|
|
7701
7767
|
});
|
|
7702
|
-
case
|
|
7768
|
+
case pp.MENU: return /* @__PURE__ */ S("div", {
|
|
7703
7769
|
className: b(Q.item, Q.menu),
|
|
7704
7770
|
children: /* @__PURE__ */ S(ao, {
|
|
7705
7771
|
maxHeight: "100%",
|
|
7706
7772
|
menu: {
|
|
7707
7773
|
trigger: ki.COMPONENT,
|
|
7708
7774
|
placement: "bottom-start",
|
|
7709
|
-
component: /* @__PURE__ */ S(
|
|
7775
|
+
component: /* @__PURE__ */ S(mp, {
|
|
7710
7776
|
label: e.label,
|
|
7711
7777
|
icon: e.icon,
|
|
7712
7778
|
onClick: e.onClick
|
|
@@ -7715,50 +7781,50 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7715
7781
|
}
|
|
7716
7782
|
})
|
|
7717
7783
|
});
|
|
7718
|
-
case
|
|
7784
|
+
case pp.COMPONENT: return /* @__PURE__ */ S("div", {
|
|
7719
7785
|
className: Q.item,
|
|
7720
7786
|
children: e.component
|
|
7721
7787
|
});
|
|
7722
7788
|
default: return null;
|
|
7723
7789
|
}
|
|
7724
|
-
},
|
|
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", {
|
|
7725
7791
|
className: b(Q.topbar, o ? Q.fixed : ""),
|
|
7726
7792
|
style: { height: a },
|
|
7727
7793
|
children: [
|
|
7728
|
-
!!t && /* @__PURE__ */ S(
|
|
7794
|
+
!!t && /* @__PURE__ */ S(dp, {
|
|
7729
7795
|
icon: t.icon,
|
|
7730
7796
|
url: t.url,
|
|
7731
7797
|
onClick: t.onClick
|
|
7732
7798
|
}),
|
|
7733
7799
|
/* @__PURE__ */ C("div", {
|
|
7734
7800
|
className: Q.left,
|
|
7735
|
-
children: [e && /* @__PURE__ */ S(
|
|
7801
|
+
children: [e && /* @__PURE__ */ S(fp, {
|
|
7736
7802
|
label: e.label,
|
|
7737
7803
|
logo: e.logo,
|
|
7738
7804
|
url: e.url,
|
|
7739
7805
|
version: e.version,
|
|
7740
7806
|
onClick: e.onClick
|
|
7741
|
-
}), n.map((e, t) => e ? /* @__PURE__ */ S(
|
|
7807
|
+
}), n.map((e, t) => e ? /* @__PURE__ */ S(hp, { element: e }, t) : null)]
|
|
7742
7808
|
}),
|
|
7743
7809
|
/* @__PURE__ */ S("div", {
|
|
7744
7810
|
className: Q.right,
|
|
7745
|
-
children: r.map((e, t) => e ? /* @__PURE__ */ S(
|
|
7811
|
+
children: r.map((e, t) => e ? /* @__PURE__ */ S(hp, { element: e }, t) : null)
|
|
7746
7812
|
})
|
|
7747
7813
|
]
|
|
7748
|
-
})] }),
|
|
7814
|
+
})] }), _p = {
|
|
7749
7815
|
popConfirm: "_popConfirm_1x6ye_1",
|
|
7750
7816
|
content: "_content_1x6ye_7",
|
|
7751
7817
|
buttons: "_buttons_1x6ye_13"
|
|
7752
|
-
},
|
|
7753
|
-
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,
|
|
7754
7820
|
children: [e && /* @__PURE__ */ S("div", {
|
|
7755
|
-
className:
|
|
7821
|
+
className: _p.content,
|
|
7756
7822
|
children: /* @__PURE__ */ S(Go, {
|
|
7757
7823
|
small: !0,
|
|
7758
7824
|
children: e
|
|
7759
7825
|
})
|
|
7760
7826
|
}), /* @__PURE__ */ C("div", {
|
|
7761
|
-
className:
|
|
7827
|
+
className: _p.buttons,
|
|
7762
7828
|
children: [/* @__PURE__ */ S(q, {
|
|
7763
7829
|
small: !0,
|
|
7764
7830
|
colored: !0,
|
|
@@ -7773,8 +7839,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7773
7839
|
testId: `${s}-cancel-button`
|
|
7774
7840
|
})]
|
|
7775
7841
|
})]
|
|
7776
|
-
}),
|
|
7777
|
-
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, {
|
|
7778
7844
|
title: i,
|
|
7779
7845
|
okText: s,
|
|
7780
7846
|
onClickOk: c,
|
|
@@ -7788,14 +7854,14 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7788
7854
|
fullWidth: r,
|
|
7789
7855
|
testId: u,
|
|
7790
7856
|
children: e
|
|
7791
|
-
}),
|
|
7857
|
+
}), bp = {
|
|
7792
7858
|
tree: "_tree_coxxe_1",
|
|
7793
7859
|
toggle: "_toggle_coxxe_8",
|
|
7794
7860
|
dropTarget: "_dropTarget_coxxe_15",
|
|
7795
7861
|
placeholder: "_placeholder_coxxe_30",
|
|
7796
7862
|
draggingSource: "_draggingSource_coxxe_36",
|
|
7797
7863
|
placeholderContainer: "_placeholderContainer_coxxe_39"
|
|
7798
|
-
},
|
|
7864
|
+
}, xp = ({ node: t, depth: n, isOpen: r, onToggle: i, hasChild: a, draggable: o, icons: s, onDrop: c }) => {
|
|
7799
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) => {
|
|
7800
7866
|
e.stopPropagation(), i(l);
|
|
7801
7867
|
}, w = (e) => {
|
|
@@ -7822,7 +7888,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7822
7888
|
className: b(Z.itemHeader, g ? Z.noPointerEvents : ""),
|
|
7823
7889
|
children: [
|
|
7824
7890
|
a && /* @__PURE__ */ S("div", {
|
|
7825
|
-
className:
|
|
7891
|
+
className: bp.toggle,
|
|
7826
7892
|
children: /* @__PURE__ */ S(q, {
|
|
7827
7893
|
basic: !0,
|
|
7828
7894
|
colored: r ? !0 : Ai.MUTED,
|
|
@@ -7847,13 +7913,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7847
7913
|
]
|
|
7848
7914
|
})
|
|
7849
7915
|
});
|
|
7850
|
-
},
|
|
7851
|
-
className:
|
|
7916
|
+
}, Sp = ({ depth: e, indent: t = "var(--size-sm)" }) => /* @__PURE__ */ S("div", {
|
|
7917
|
+
className: bp.placeholder,
|
|
7852
7918
|
style: { left: `calc(${t} * ${e})` }
|
|
7853
|
-
}),
|
|
7919
|
+
}), Cp = (e, t) => {
|
|
7854
7920
|
var n;
|
|
7855
7921
|
return e && (t == null || (n = t.data) == null ? void 0 : n.draggable) !== !1;
|
|
7856
|
-
},
|
|
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 }) => {
|
|
7857
7923
|
var y, b;
|
|
7858
7924
|
let x = c == null ? _(null) : c, w = (e) => {
|
|
7859
7925
|
i && i(e);
|
|
@@ -7934,7 +8000,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7934
8000
|
tree: N,
|
|
7935
8001
|
sort: !1,
|
|
7936
8002
|
insertDroppableFirst: !1,
|
|
7937
|
-
canDrag: (e) =>
|
|
8003
|
+
canDrag: (e) => Cp(n, e),
|
|
7938
8004
|
canDrop: t || ((e, { dragSource: t, dropTargetId: n }) => {
|
|
7939
8005
|
if ((t == null ? void 0 : t.parent) === n) return !0;
|
|
7940
8006
|
}),
|
|
@@ -7948,7 +8014,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7948
8014
|
hasChild: n,
|
|
7949
8015
|
isOpen: i,
|
|
7950
8016
|
onToggle: a
|
|
7951
|
-
}) : /* @__PURE__ */ S(
|
|
8017
|
+
}) : /* @__PURE__ */ S(xp, {
|
|
7952
8018
|
hasChild: l ? l(e) : n,
|
|
7953
8019
|
node: e,
|
|
7954
8020
|
depth: t,
|
|
@@ -7964,7 +8030,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7964
8030
|
onDrop: M,
|
|
7965
8031
|
onChangeOpen: w,
|
|
7966
8032
|
dropTargetOffset: 10,
|
|
7967
|
-
placeholderRender: (e, { depth: t }) => /* @__PURE__ */ S(
|
|
8033
|
+
placeholderRender: (e, { depth: t }) => /* @__PURE__ */ S(Sp, {
|
|
7968
8034
|
depth: t,
|
|
7969
8035
|
indent: v
|
|
7970
8036
|
}),
|
|
@@ -7972,17 +8038,17 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7972
8038
|
listComponent: "div",
|
|
7973
8039
|
listItemComponent: "div",
|
|
7974
8040
|
classes: {
|
|
7975
|
-
root:
|
|
7976
|
-
draggingSource:
|
|
7977
|
-
dropTarget:
|
|
7978
|
-
placeholder:
|
|
8041
|
+
root: bp.tree,
|
|
8042
|
+
draggingSource: bp.draggingSource,
|
|
8043
|
+
dropTarget: bp.dropTarget,
|
|
8044
|
+
placeholder: bp.placeholderContainer
|
|
7979
8045
|
},
|
|
7980
8046
|
initialOpen: o,
|
|
7981
8047
|
enableAnimateExpand: !0
|
|
7982
8048
|
})
|
|
7983
8049
|
})]
|
|
7984
8050
|
});
|
|
7985
|
-
},
|
|
8051
|
+
}, Tp = {
|
|
7986
8052
|
treeTable: "_treeTable_1ywvy_1",
|
|
7987
8053
|
treeTableHeader: "_treeTableHeader_1ywvy_22",
|
|
7988
8054
|
folderCell: "_folderCell_1ywvy_30",
|
|
@@ -7990,48 +8056,48 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
7990
8056
|
drag: "_drag_1ywvy_31",
|
|
7991
8057
|
folder: "_folder_1ywvy_30",
|
|
7992
8058
|
active: "_active_1ywvy_61"
|
|
7993
|
-
},
|
|
8059
|
+
}, Ep = (e, t) => e.filter((e) => e.parent === t).flatMap((t) => [t.id, ...Ep(e, t.id)]), Dp = (e, t) => {
|
|
7994
8060
|
let n = new Set(t);
|
|
7995
8061
|
return e.filter((e) => !n.has(e.id)).map((e) => e.id);
|
|
7996
|
-
},
|
|
8062
|
+
}, Op = (e, t, n) => e.filter((e) => n.has(e) || !t.has(e)), kp = (e, t, n, r = []) => {
|
|
7997
8063
|
let i = new Set(n), a = new Set(r), o = e.filter((e) => e.parent === t && !a.has(e.id));
|
|
7998
8064
|
if (o.length === 0) return {
|
|
7999
8065
|
checked: i.has(t),
|
|
8000
8066
|
indeterminate: !1
|
|
8001
8067
|
};
|
|
8002
|
-
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;
|
|
8003
8069
|
return {
|
|
8004
8070
|
checked: u,
|
|
8005
8071
|
indeterminate: c + l > 0 && !u
|
|
8006
8072
|
};
|
|
8007
|
-
},
|
|
8008
|
-
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;
|
|
8009
8075
|
return {
|
|
8010
8076
|
checked: r.length > 0 && a === r.length,
|
|
8011
8077
|
indeterminate: a > 0 && a < r.length
|
|
8012
8078
|
};
|
|
8013
|
-
},
|
|
8079
|
+
}, jp = i(null), Mp = () => u(jp), Np = ({ children: e, rowCheckboxes: t, rows: n }) => {
|
|
8014
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(() => {
|
|
8015
8081
|
if (!r) return null;
|
|
8016
8082
|
let e = /* @__PURE__ */ new Map();
|
|
8017
|
-
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));
|
|
8018
8084
|
return e;
|
|
8019
8085
|
}, [
|
|
8020
8086
|
i,
|
|
8021
8087
|
a,
|
|
8022
8088
|
r,
|
|
8023
8089
|
n
|
|
8024
|
-
]), d = h(() => r ?
|
|
8090
|
+
]), d = h(() => r ? Ap(n, i, a) : void 0, [
|
|
8025
8091
|
i,
|
|
8026
8092
|
a,
|
|
8027
8093
|
r,
|
|
8028
8094
|
n
|
|
8029
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) => {
|
|
8030
8096
|
if (!r || c.has(e)) return;
|
|
8031
|
-
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);
|
|
8032
8098
|
if (u) {
|
|
8033
8099
|
let e = new Set(l);
|
|
8034
|
-
s == null || s(
|
|
8100
|
+
s == null || s(Op(i, e, c));
|
|
8035
8101
|
} else s == null || s([.../* @__PURE__ */ new Set([...i, ...o])]);
|
|
8036
8102
|
}, [
|
|
8037
8103
|
i,
|
|
@@ -8042,7 +8108,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8042
8108
|
n
|
|
8043
8109
|
]), _ = l(() => {
|
|
8044
8110
|
if (!r) return;
|
|
8045
|
-
let e =
|
|
8111
|
+
let e = Dp(n, a), { checked: t } = Ap(n, i, a);
|
|
8046
8112
|
t ? s == null || s(i.filter((e) => c.has(e))) : s == null || s([.../* @__PURE__ */ new Set([...i, ...e])]);
|
|
8047
8113
|
}, [
|
|
8048
8114
|
i,
|
|
@@ -8068,12 +8134,12 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8068
8134
|
_,
|
|
8069
8135
|
g
|
|
8070
8136
|
]);
|
|
8071
|
-
return /* @__PURE__ */ S(
|
|
8137
|
+
return /* @__PURE__ */ S(jp.Provider, {
|
|
8072
8138
|
value: v,
|
|
8073
8139
|
children: e
|
|
8074
8140
|
});
|
|
8075
|
-
},
|
|
8076
|
-
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) => {
|
|
8077
8143
|
let r = t ? t[e] : void 0;
|
|
8078
8144
|
return e === 0 ? `calc(${r} - ${`calc(var(--size) * ${N ? n + 1 : n})`})` : r;
|
|
8079
8145
|
};
|
|
@@ -8086,7 +8152,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8086
8152
|
onDragLeave: p,
|
|
8087
8153
|
children: /* @__PURE__ */ S("tbody", { children: /* @__PURE__ */ C("tr", {
|
|
8088
8154
|
onClick: M,
|
|
8089
|
-
className: b(
|
|
8155
|
+
className: b(Tp.treeTableRow, j ? Tp.active : void 0),
|
|
8090
8156
|
children: [
|
|
8091
8157
|
w && /* @__PURE__ */ S(Hl, {
|
|
8092
8158
|
isHeader: !1,
|
|
@@ -8100,19 +8166,19 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8100
8166
|
}
|
|
8101
8167
|
}),
|
|
8102
8168
|
r && /* @__PURE__ */ S("td", {
|
|
8103
|
-
className:
|
|
8169
|
+
className: Tp.dragCell,
|
|
8104
8170
|
children: c && /* @__PURE__ */ S("div", {
|
|
8105
|
-
className:
|
|
8171
|
+
className: Tp.drag,
|
|
8106
8172
|
onClick: (e) => e.stopPropagation(),
|
|
8107
8173
|
ref: i,
|
|
8108
8174
|
children: /* @__PURE__ */ S(G, { icon: U.DRAG })
|
|
8109
8175
|
})
|
|
8110
8176
|
}),
|
|
8111
|
-
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)),
|
|
8112
8178
|
N && /* @__PURE__ */ S("td", {
|
|
8113
|
-
className:
|
|
8179
|
+
className: Tp.folderCell,
|
|
8114
8180
|
children: /* @__PURE__ */ S("div", {
|
|
8115
|
-
className:
|
|
8181
|
+
className: Tp.folder,
|
|
8116
8182
|
onClick: () => h(D),
|
|
8117
8183
|
onMouseDown: (e) => e.stopPropagation(),
|
|
8118
8184
|
children: /* @__PURE__ */ S(q, {
|
|
@@ -8144,10 +8210,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8144
8210
|
]
|
|
8145
8211
|
}) })
|
|
8146
8212
|
});
|
|
8147
|
-
},
|
|
8148
|
-
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;
|
|
8149
8215
|
return /* @__PURE__ */ S("table", {
|
|
8150
|
-
className: b(Hs.table,
|
|
8216
|
+
className: b(Hs.table, Tp.treeTableHeader),
|
|
8151
8217
|
children: /* @__PURE__ */ S("thead", { children: i.map((i, c) => /* @__PURE__ */ C("tr", { children: [
|
|
8152
8218
|
s && c === 0 ? /* @__PURE__ */ S(Hl, {
|
|
8153
8219
|
isHeader: !0,
|
|
@@ -8158,7 +8224,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8158
8224
|
onChange: a.toggleHeaderCheck
|
|
8159
8225
|
}
|
|
8160
8226
|
}) : s ? /* @__PURE__ */ S("td", {}) : null,
|
|
8161
|
-
n && /* @__PURE__ */ S("th", { className:
|
|
8227
|
+
n && /* @__PURE__ */ S("th", { className: Tp.dragCell }),
|
|
8162
8228
|
i.cells.map((n, r) => {
|
|
8163
8229
|
let i = t ? t[r] : void 0, a = e ? e[r] : void 0;
|
|
8164
8230
|
return /* @__PURE__ */ S(Hl, {
|
|
@@ -8178,22 +8244,22 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8178
8244
|
})
|
|
8179
8245
|
] }, c)) })
|
|
8180
8246
|
});
|
|
8181
|
-
},
|
|
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 }) => {
|
|
8182
8248
|
let { columnAlignment: m, columnWidths: h, fixedWidth: g, headers: _, rows: v = [] } = d, y = ll(v, _ == null ? [] : _);
|
|
8183
|
-
return /* @__PURE__ */ S(
|
|
8249
|
+
return /* @__PURE__ */ S(Np, {
|
|
8184
8250
|
rowCheckboxes: u,
|
|
8185
8251
|
rows: v,
|
|
8186
8252
|
children: /* @__PURE__ */ C("div", {
|
|
8187
|
-
className:
|
|
8253
|
+
className: Tp.treeTable,
|
|
8188
8254
|
"data-testid": f,
|
|
8189
8255
|
style: { width: g },
|
|
8190
|
-
children: [!!_ && /* @__PURE__ */ S(
|
|
8256
|
+
children: [!!_ && /* @__PURE__ */ S(Fp, {
|
|
8191
8257
|
columnAlignment: m,
|
|
8192
8258
|
columnWidths: h,
|
|
8193
8259
|
draggable: r,
|
|
8194
8260
|
hasRowActions: y,
|
|
8195
8261
|
headers: _
|
|
8196
|
-
}), /* @__PURE__ */ S(
|
|
8262
|
+
}), /* @__PURE__ */ S(wp, {
|
|
8197
8263
|
allowParentReassignment: e,
|
|
8198
8264
|
autoOpenActiveItems: t,
|
|
8199
8265
|
canDrop: n,
|
|
@@ -8209,7 +8275,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8209
8275
|
onItemToggle: s,
|
|
8210
8276
|
onListReorder: c,
|
|
8211
8277
|
placeholderIndent: "var(--size)",
|
|
8212
|
-
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, {
|
|
8213
8279
|
node: e,
|
|
8214
8280
|
columnAlignment: m,
|
|
8215
8281
|
columnWidths: h,
|
|
@@ -8227,10 +8293,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8227
8293
|
})]
|
|
8228
8294
|
})
|
|
8229
8295
|
});
|
|
8230
|
-
},
|
|
8296
|
+
}, Lp = Object.freeze({
|
|
8231
8297
|
Translations: "translations",
|
|
8232
8298
|
LanguageKey: "languageKey"
|
|
8233
|
-
}),
|
|
8299
|
+
}), Rp = {
|
|
8234
8300
|
unified: "Unified",
|
|
8235
8301
|
split: "Split",
|
|
8236
8302
|
changesTooLarge: "Changes are too large to be shown",
|
|
@@ -8253,39 +8319,39 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8253
8319
|
showAll: "Show all",
|
|
8254
8320
|
unknown: "Unknown",
|
|
8255
8321
|
unexpectedError: "Unexpected error"
|
|
8256
|
-
},
|
|
8322
|
+
}, zp = (e) => Object.keys(Rp).reduce((t, n) => ({
|
|
8257
8323
|
...t,
|
|
8258
|
-
[n]: (e == null ? void 0 : e[n]) || (
|
|
8259
|
-
}), {}),
|
|
8260
|
-
[
|
|
8261
|
-
[
|
|
8262
|
-
},
|
|
8263
|
-
|
|
8264
|
-
},
|
|
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 }) => {
|
|
8265
8331
|
var a;
|
|
8266
|
-
let { unitTemplate: o = null } = (a =
|
|
8267
|
-
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, {
|
|
8268
8334
|
preferredUnits: e,
|
|
8269
8335
|
storageUnits: t
|
|
8270
8336
|
};
|
|
8271
8337
|
}, {
|
|
8272
8338
|
preferredUnits: {},
|
|
8273
8339
|
storageUnits: {}
|
|
8274
|
-
}),
|
|
8340
|
+
}), Wp = ({ value: e, unitKey: t, selectedUnits: n, storageUnits: r }) => {
|
|
8275
8341
|
let i = n[t], a = r[t];
|
|
8276
8342
|
if (!(a && i !== a) || e === null || e === "") return e;
|
|
8277
|
-
let { value: o = e } =
|
|
8343
|
+
let { value: o = e } = Hf({
|
|
8278
8344
|
value: fr(e),
|
|
8279
8345
|
unitkey: t,
|
|
8280
8346
|
toUnit: i,
|
|
8281
8347
|
fromUnit: a
|
|
8282
8348
|
});
|
|
8283
8349
|
return o;
|
|
8284
|
-
},
|
|
8350
|
+
}, Gp = ({ row: e, selectedUnits: t, storageUnits: n, convertBackToStorageUnit: r, enableCosmeticRounding: i, enableDisplayRounding: a }) => ({
|
|
8285
8351
|
...e,
|
|
8286
8352
|
cells: e.cells.map((e) => {
|
|
8287
8353
|
if ("autoUnit" in e && e.autoUnit && (typeof e.value == "string" || typeof e.value == "number")) {
|
|
8288
|
-
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({
|
|
8289
8355
|
value: s,
|
|
8290
8356
|
unitKey: o,
|
|
8291
8357
|
selectedUnits: t,
|
|
@@ -8299,7 +8365,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8299
8365
|
roundDisplayValue: l,
|
|
8300
8366
|
selectOnFocus: !0,
|
|
8301
8367
|
onChange: (t) => {
|
|
8302
|
-
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({
|
|
8303
8369
|
value: String(i),
|
|
8304
8370
|
unitkey: o,
|
|
8305
8371
|
toUnit: a,
|
|
@@ -8318,8 +8384,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8318
8384
|
}
|
|
8319
8385
|
return e;
|
|
8320
8386
|
})
|
|
8321
|
-
}),
|
|
8322
|
-
let { translations: i } =
|
|
8387
|
+
}), Kp = ({ headers: e, selectedUnits: t, storageUnits: n, onChangeUnit: r }) => {
|
|
8388
|
+
let { translations: i } = Vp();
|
|
8323
8389
|
return e ? e.map((e) => ({
|
|
8324
8390
|
...e,
|
|
8325
8391
|
cells: e.cells.map((e) => {
|
|
@@ -8348,8 +8414,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8348
8414
|
return e;
|
|
8349
8415
|
})
|
|
8350
8416
|
})) : [];
|
|
8351
|
-
},
|
|
8352
|
-
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 }) => {
|
|
8353
8419
|
g((t) => ({
|
|
8354
8420
|
...t,
|
|
8355
8421
|
[e]: n
|
|
@@ -8360,13 +8426,13 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8360
8426
|
newUnit: n,
|
|
8361
8427
|
unitKey: e
|
|
8362
8428
|
});
|
|
8363
|
-
}, y = l(({ row: e, rowIndex: t }) =>
|
|
8429
|
+
}, y = l(({ row: e, rowIndex: t }) => Gp({
|
|
8364
8430
|
row: s ? s({
|
|
8365
8431
|
row: e,
|
|
8366
8432
|
rowIndex: t,
|
|
8367
8433
|
selectedUnits: h,
|
|
8368
8434
|
storageUnits: f,
|
|
8369
|
-
convertValue: (e, t) =>
|
|
8435
|
+
convertValue: (e, t) => Wp({
|
|
8370
8436
|
value: e,
|
|
8371
8437
|
unitKey: t,
|
|
8372
8438
|
selectedUnits: h,
|
|
@@ -8397,7 +8463,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8397
8463
|
}, [t]), /* @__PURE__ */ S($l, {
|
|
8398
8464
|
table: {
|
|
8399
8465
|
...u,
|
|
8400
|
-
headers:
|
|
8466
|
+
headers: Kp({
|
|
8401
8467
|
headers: e.headers,
|
|
8402
8468
|
selectedUnits: h,
|
|
8403
8469
|
storageUnits: f,
|
|
@@ -8408,8 +8474,8 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8408
8474
|
canListReorder: o,
|
|
8409
8475
|
beforeRenderRow: y
|
|
8410
8476
|
});
|
|
8411
|
-
},
|
|
8412
|
-
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 = [
|
|
8413
8479
|
...r ? [] : [{
|
|
8414
8480
|
label: d == null ? void 0 : d.allUsers,
|
|
8415
8481
|
value: !1
|
|
@@ -8424,7 +8490,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8424
8490
|
}] : []
|
|
8425
8491
|
], m = a !== void 0 && o !== void 0 && !dn(a, o);
|
|
8426
8492
|
return /* @__PURE__ */ C("div", {
|
|
8427
|
-
className:
|
|
8493
|
+
className: Jp.settingField,
|
|
8428
8494
|
"data-testid": u,
|
|
8429
8495
|
children: [/* @__PURE__ */ C(yd, {
|
|
8430
8496
|
justifyContent: "space-between",
|
|
@@ -8456,7 +8522,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8456
8522
|
children: f(t)
|
|
8457
8523
|
})]
|
|
8458
8524
|
});
|
|
8459
|
-
},
|
|
8525
|
+
}, Xp = { backgroundColor: "var(--color-background-error-muted)" }, Zp = { backgroundColor: "var(--color-background-success-muted)" }, Qp = { backgroundColor: "var(--color-background-warning-muted)" }, $p = {
|
|
8460
8526
|
addedBackground: "var(--color-diff-added-background)",
|
|
8461
8527
|
addedGutterBackground: "var(--color-diff-added-gutter-background)",
|
|
8462
8528
|
codeFoldBackground: "var(--color-diff-code-fold-background)",
|
|
@@ -8475,10 +8541,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8475
8541
|
removedGutterBackground: "var(--color-diff-removed-gutter-background)",
|
|
8476
8542
|
wordAddedBackground: "var(--color-diff-word-added-background)",
|
|
8477
8543
|
wordRemovedBackground: "var(--color-diff-word-removed-background)"
|
|
8478
|
-
},
|
|
8544
|
+
}, em = {
|
|
8479
8545
|
variables: {
|
|
8480
|
-
light:
|
|
8481
|
-
dark:
|
|
8546
|
+
light: $p,
|
|
8547
|
+
dark: $p
|
|
8482
8548
|
},
|
|
8483
8549
|
diffContainer: { minWidth: "unset" },
|
|
8484
8550
|
codeFoldGutter: {
|
|
@@ -8493,10 +8559,10 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8493
8559
|
pre: { opacity: .5 }
|
|
8494
8560
|
} },
|
|
8495
8561
|
marker: { pre: { opacity: .4 } }
|
|
8496
|
-
},
|
|
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 }) => {
|
|
8497
8563
|
let c = t !== void 0, l = c ? t : e, u = i !== Di.WORDS;
|
|
8498
8564
|
return /* @__PURE__ */ S("div", {
|
|
8499
|
-
className: b(s, { [
|
|
8565
|
+
className: b(s, { [tm.codeOnly]: !c && !n }),
|
|
8500
8566
|
children: /* @__PURE__ */ S(Ei, {
|
|
8501
8567
|
oldValue: l,
|
|
8502
8568
|
newValue: e,
|
|
@@ -8508,22 +8574,22 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8508
8574
|
hideLineNumbers: !1,
|
|
8509
8575
|
hideSummary: o,
|
|
8510
8576
|
disableWorker: !0,
|
|
8511
|
-
styles:
|
|
8577
|
+
styles: em
|
|
8512
8578
|
})
|
|
8513
8579
|
});
|
|
8514
|
-
},
|
|
8580
|
+
}, rm = (e, t) => {
|
|
8515
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;
|
|
8516
8582
|
return {
|
|
8517
8583
|
added: Math.max(0, i),
|
|
8518
8584
|
removed: Math.max(0, a)
|
|
8519
8585
|
};
|
|
8520
|
-
},
|
|
8586
|
+
}, im = "split", am = "unified", om = ({ oldJson: e, newJson: t, viewType: n = im }) => {
|
|
8521
8587
|
var r, i;
|
|
8522
|
-
let { translations: a } =
|
|
8523
|
-
value:
|
|
8588
|
+
let { translations: a } = Vp(), [o, s] = v(n), c = [{
|
|
8589
|
+
value: im,
|
|
8524
8590
|
label: (r = a == null ? void 0 : a.split) == null ? "Split" : r
|
|
8525
8591
|
}, {
|
|
8526
|
-
value:
|
|
8592
|
+
value: am,
|
|
8527
8593
|
label: (i = a == null ? void 0 : a.unified) == null ? "Unified" : i
|
|
8528
8594
|
}];
|
|
8529
8595
|
d(() => {
|
|
@@ -8531,7 +8597,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8531
8597
|
}, [n]);
|
|
8532
8598
|
let l = ({ target: { value: e } }) => {
|
|
8533
8599
|
s(e);
|
|
8534
|
-
}, { added: u, removed: f } =
|
|
8600
|
+
}, { added: u, removed: f } = rm(e, t), p = u + f > 3500;
|
|
8535
8601
|
return /* @__PURE__ */ S(x, { children: /* @__PURE__ */ S(go, {
|
|
8536
8602
|
bordered: !0,
|
|
8537
8603
|
heading: /* @__PURE__ */ C(yd, {
|
|
@@ -8561,21 +8627,21 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8561
8627
|
muted: !0,
|
|
8562
8628
|
children: a == null ? void 0 : a.changesTooLarge
|
|
8563
8629
|
})
|
|
8564
|
-
}) : /* @__PURE__ */ S(
|
|
8630
|
+
}) : /* @__PURE__ */ S(nm, {
|
|
8565
8631
|
value: t,
|
|
8566
8632
|
compareValue: e,
|
|
8567
|
-
splitView: o ===
|
|
8633
|
+
splitView: o === im,
|
|
8568
8634
|
compareMethod: Di.WORDS,
|
|
8569
8635
|
showDiffOnly: !0,
|
|
8570
8636
|
hideSummary: !1
|
|
8571
8637
|
})
|
|
8572
8638
|
}) });
|
|
8573
|
-
},
|
|
8639
|
+
}, sm = (e) => typeof e == "object" && e && "value" in e ? e.value : e, cm = (e) => {
|
|
8574
8640
|
var t;
|
|
8575
8641
|
if (e.id != null) return String(e.id);
|
|
8576
|
-
let n =
|
|
8642
|
+
let n = sm((t = e.cells) == null || (t = t[0]) == null ? void 0 : t.value);
|
|
8577
8643
|
return n == null ? "" : String(n);
|
|
8578
|
-
},
|
|
8644
|
+
}, lm = (e, t) => ({
|
|
8579
8645
|
...e,
|
|
8580
8646
|
cells: e.cells.map((e) => ({
|
|
8581
8647
|
...e,
|
|
@@ -8584,7 +8650,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8584
8650
|
...t
|
|
8585
8651
|
}
|
|
8586
8652
|
}))
|
|
8587
|
-
}),
|
|
8653
|
+
}), um = (e, t) => ({
|
|
8588
8654
|
...e,
|
|
8589
8655
|
cells: e.cells.map((e, n) => {
|
|
8590
8656
|
var r;
|
|
@@ -8593,17 +8659,17 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8593
8659
|
...e,
|
|
8594
8660
|
style: {
|
|
8595
8661
|
...e.style,
|
|
8596
|
-
...
|
|
8662
|
+
...Qp
|
|
8597
8663
|
},
|
|
8598
8664
|
tooltip: typeof a == "number" ? String(a) : a
|
|
8599
8665
|
};
|
|
8600
8666
|
})
|
|
8601
|
-
}),
|
|
8667
|
+
}), dm = (e = [], t = []) => {
|
|
8602
8668
|
let n = /* @__PURE__ */ new Map();
|
|
8603
|
-
for (let e of t) n.set(
|
|
8604
|
-
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;
|
|
8605
8671
|
for (let e = t.length - 1; e >= 0; e--) {
|
|
8606
|
-
let n = t[e], c =
|
|
8672
|
+
let n = t[e], c = cm(n);
|
|
8607
8673
|
if (r.has(c)) {
|
|
8608
8674
|
o = c;
|
|
8609
8675
|
continue;
|
|
@@ -8618,7 +8684,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8618
8684
|
a.reverse();
|
|
8619
8685
|
let c = [];
|
|
8620
8686
|
for (let t of e) {
|
|
8621
|
-
let e =
|
|
8687
|
+
let e = cm(t), r = i.get(e);
|
|
8622
8688
|
if (r) for (let e of r) c.push({
|
|
8623
8689
|
status: "deleted",
|
|
8624
8690
|
row: e
|
|
@@ -8638,11 +8704,11 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8638
8704
|
row: e
|
|
8639
8705
|
});
|
|
8640
8706
|
return c;
|
|
8641
|
-
},
|
|
8642
|
-
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(() => {
|
|
8643
8709
|
if (!a) return i.map((e) => e.row);
|
|
8644
8710
|
}, [a, i]), s = l(({ row: e, rowIndex: t }) => {
|
|
8645
|
-
let r = i[t], a = r ?
|
|
8711
|
+
let r = i[t], a = r ? fm(r) : e;
|
|
8646
8712
|
return n ? n({
|
|
8647
8713
|
row: a,
|
|
8648
8714
|
rowIndex: t
|
|
@@ -8661,7 +8727,7 @@ var To = (e) => e.replace(/^lch\(\s*(\d+(?:\.\d+)?)(?!%)\s+/, "lch($1% "), Eo =
|
|
|
8661
8727
|
};
|
|
8662
8728
|
//#endregion
|
|
8663
8729
|
//#region src/helpers/date.ts
|
|
8664
|
-
function
|
|
8730
|
+
function mm({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i, locale: a }) {
|
|
8665
8731
|
return e ? new Date(e).toLocaleString(a, {
|
|
8666
8732
|
year: "numeric",
|
|
8667
8733
|
month: "short",
|
|
@@ -8675,28 +8741,28 @@ function lm({ date: e, showTime: t, showSeconds: n, timeZone: r, showTimeZone: i
|
|
|
8675
8741
|
}
|
|
8676
8742
|
//#endregion
|
|
8677
8743
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/clone.js
|
|
8678
|
-
function
|
|
8744
|
+
function hm(e) {
|
|
8679
8745
|
var t;
|
|
8680
8746
|
let n = /^\/(.*)\/([gimyu]*)$/.exec(e.toString());
|
|
8681
8747
|
if (!n) throw Error("Invalid RegExp");
|
|
8682
8748
|
return new RegExp((t = n[1]) == null ? "" : t, n[2]);
|
|
8683
8749
|
}
|
|
8684
|
-
function
|
|
8750
|
+
function gm(e) {
|
|
8685
8751
|
if (typeof e != "object") return e;
|
|
8686
8752
|
if (e === null) return null;
|
|
8687
|
-
if (Array.isArray(e)) return e.map(
|
|
8753
|
+
if (Array.isArray(e)) return e.map(gm);
|
|
8688
8754
|
if (e instanceof Date) return new Date(e.getTime());
|
|
8689
|
-
if (e instanceof RegExp) return
|
|
8755
|
+
if (e instanceof RegExp) return hm(e);
|
|
8690
8756
|
let t = {};
|
|
8691
|
-
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]));
|
|
8692
8758
|
return t;
|
|
8693
8759
|
}
|
|
8694
8760
|
//#endregion
|
|
8695
8761
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/assertions/arrays.js
|
|
8696
|
-
function
|
|
8762
|
+
function _m(e, t) {
|
|
8697
8763
|
if (e.length === 0) throw Error(t || "Expected a non-empty array");
|
|
8698
8764
|
}
|
|
8699
|
-
var
|
|
8765
|
+
var vm = (e) => e[e.length - 1], ym = class {
|
|
8700
8766
|
setResult(e) {
|
|
8701
8767
|
return this.result = e, this.hasResult = !0, this;
|
|
8702
8768
|
}
|
|
@@ -8704,16 +8770,16 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8704
8770
|
return this.exiting = !0, this;
|
|
8705
8771
|
}
|
|
8706
8772
|
push(e, t) {
|
|
8707
|
-
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;
|
|
8708
8774
|
}
|
|
8709
|
-
},
|
|
8775
|
+
}, bm = class extends ym {
|
|
8710
8776
|
constructor(e, t) {
|
|
8711
8777
|
super(), this.left = e, this.right = t, this.pipe = "diff";
|
|
8712
8778
|
}
|
|
8713
8779
|
prepareDeltaResult(e) {
|
|
8714
8780
|
var t, n, r, i;
|
|
8715
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)) {
|
|
8716
|
-
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;
|
|
8717
8783
|
typeof e[0] == "object" && (e[0] = t(e[0])), typeof e[1] == "object" && (e[1] = t(e[1]));
|
|
8718
8784
|
}
|
|
8719
8785
|
return e;
|
|
@@ -8721,15 +8787,15 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8721
8787
|
setResult(e) {
|
|
8722
8788
|
return this.prepareDeltaResult(e), super.setResult(e);
|
|
8723
8789
|
}
|
|
8724
|
-
},
|
|
8790
|
+
}, xm = class extends ym {
|
|
8725
8791
|
constructor(e, t) {
|
|
8726
8792
|
super(), this.left = e, this.delta = t, this.pipe = "patch";
|
|
8727
8793
|
}
|
|
8728
|
-
},
|
|
8794
|
+
}, Sm = class extends ym {
|
|
8729
8795
|
constructor(e) {
|
|
8730
8796
|
super(), this.delta = e, this.pipe = "reverse";
|
|
8731
8797
|
}
|
|
8732
|
-
},
|
|
8798
|
+
}, Cm = class {
|
|
8733
8799
|
constructor(e) {
|
|
8734
8800
|
this.name = e, this.filters = [];
|
|
8735
8801
|
}
|
|
@@ -8793,7 +8859,7 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8793
8859
|
}
|
|
8794
8860
|
}), this);
|
|
8795
8861
|
}
|
|
8796
|
-
},
|
|
8862
|
+
}, wm = class {
|
|
8797
8863
|
constructor(e) {
|
|
8798
8864
|
this.selfOptions = e || {}, this.pipes = {};
|
|
8799
8865
|
}
|
|
@@ -8820,7 +8886,7 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8820
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);
|
|
8821
8887
|
return n.hasResult ? n.result : void 0;
|
|
8822
8888
|
}
|
|
8823
|
-
},
|
|
8889
|
+
}, Tm = (e, t, n, r) => e[n] === t[r], Em = (e, t, n, r) => {
|
|
8824
8890
|
var i, a, o;
|
|
8825
8891
|
let s = e.length, c = t.length, l, u, d = Array(s + 1);
|
|
8826
8892
|
for (l = 0; l < s + 1; l++) {
|
|
@@ -8836,7 +8902,7 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8836
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);
|
|
8837
8903
|
}
|
|
8838
8904
|
return d;
|
|
8839
|
-
},
|
|
8905
|
+
}, Dm = (e, t, n, r) => {
|
|
8840
8906
|
let i = t.length, a = n.length, o = {
|
|
8841
8907
|
sequence: [],
|
|
8842
8908
|
indices1: [],
|
|
@@ -8858,11 +8924,11 @@ var pm = (e) => e[e.length - 1], mm = class {
|
|
|
8858
8924
|
}
|
|
8859
8925
|
}
|
|
8860
8926
|
return o;
|
|
8861
|
-
},
|
|
8927
|
+
}, Om = { get: (e, t, n, r) => {
|
|
8862
8928
|
let i = r || {};
|
|
8863
|
-
return
|
|
8864
|
-
} },
|
|
8865
|
-
function
|
|
8929
|
+
return Dm(Em(e, t, n || Tm, i), e, t, i);
|
|
8930
|
+
} }, km = 3;
|
|
8931
|
+
function Am(e, t, n, r) {
|
|
8866
8932
|
for (let i = 0; i < n; i++) {
|
|
8867
8933
|
let n = e[i];
|
|
8868
8934
|
for (let e = 0; e < r; e++) {
|
|
@@ -8872,7 +8938,7 @@ function Tm(e, t, n, r) {
|
|
|
8872
8938
|
}
|
|
8873
8939
|
return !1;
|
|
8874
8940
|
}
|
|
8875
|
-
function
|
|
8941
|
+
function jm(e, t, n, r, i) {
|
|
8876
8942
|
let a = e[n], o = t[r];
|
|
8877
8943
|
if (a === o) return !0;
|
|
8878
8944
|
if (typeof a != "object" || typeof o != "object") return !1;
|
|
@@ -8885,15 +8951,15 @@ function Em(e, t, n, r, i) {
|
|
|
8885
8951
|
let l = i.hashCache2[r];
|
|
8886
8952
|
return l === void 0 && (i.hashCache2[r] = l = s(o, r)), l !== void 0 && c === l;
|
|
8887
8953
|
}
|
|
8888
|
-
var
|
|
8954
|
+
var Mm = function(e) {
|
|
8889
8955
|
var t, n, r, i, a;
|
|
8890
8956
|
if (!e.leftIsArray) return;
|
|
8891
8957
|
let o = {
|
|
8892
8958
|
objectHash: (t = e.options) == null ? void 0 : t.objectHash,
|
|
8893
8959
|
matchByPosition: (n = e.options) == null ? void 0 : n.matchByPosition
|
|
8894
8960
|
}, s = 0, c = 0, l, u, d, f = e.left, p = e.right, m = f.length, h = p.length, g;
|
|
8895
|
-
for (m > 0 && h > 0 && !o.objectHash && typeof o.matchByPosition != "boolean" && (o.matchByPosition = !
|
|
8896
|
-
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++;
|
|
8897
8963
|
let _;
|
|
8898
8964
|
if (s + c === m) {
|
|
8899
8965
|
if (m === h) {
|
|
@@ -8917,7 +8983,7 @@ var Dm = function(e) {
|
|
|
8917
8983
|
return;
|
|
8918
8984
|
}
|
|
8919
8985
|
o.hashCache1 = void 0, o.hashCache2 = void 0;
|
|
8920
|
-
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 = [];
|
|
8921
8987
|
for (_ = _ || { _t: "a" }, l = s; l < m - c; l++) if (b.indices1.indexOf(l - s) < 0) {
|
|
8922
8988
|
let t = `_${l}`;
|
|
8923
8989
|
_[t] = [
|
|
@@ -8938,8 +9004,8 @@ var Dm = function(e) {
|
|
|
8938
9004
|
if (S && w > 0) for (let n = 0; n < w; n++) {
|
|
8939
9005
|
u = x[n];
|
|
8940
9006
|
let r = u === void 0 ? void 0 : _[`_${u}`];
|
|
8941
|
-
if (u !== void 0 && r &&
|
|
8942
|
-
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;
|
|
8943
9009
|
break;
|
|
8944
9010
|
}
|
|
8945
9011
|
}
|
|
@@ -8947,20 +9013,20 @@ var Dm = function(e) {
|
|
|
8947
9013
|
} else {
|
|
8948
9014
|
if (b.indices1[t] === void 0) throw Error(`Invalid indexOnArray2: ${t}, seq.indices1: ${b.indices1}`);
|
|
8949
9015
|
if (u = b.indices1[t] + s, b.indices2[t] === void 0) throw Error(`Invalid indexOnArray2: ${t}, seq.indices2: ${b.indices2}`);
|
|
8950
|
-
d = b.indices2[t] + s, g = new
|
|
9016
|
+
d = b.indices2[t] + s, g = new bm(f[u], p[d]), e.push(g, d);
|
|
8951
9017
|
}
|
|
8952
9018
|
}
|
|
8953
9019
|
e.setResult(_).exit();
|
|
8954
9020
|
};
|
|
8955
|
-
|
|
8956
|
-
var
|
|
9021
|
+
Mm.filterName = "arrays";
|
|
9022
|
+
var Nm = {
|
|
8957
9023
|
numerically(e, t) {
|
|
8958
9024
|
return e - t;
|
|
8959
9025
|
},
|
|
8960
9026
|
numericallyBy(e) {
|
|
8961
9027
|
return (t, n) => t[e] - n[e];
|
|
8962
9028
|
}
|
|
8963
|
-
},
|
|
9029
|
+
}, Pm = function(e) {
|
|
8964
9030
|
var t;
|
|
8965
9031
|
if (!e.nested) return;
|
|
8966
9032
|
let n = e.delta;
|
|
@@ -8969,7 +9035,7 @@ var Om = {
|
|
|
8969
9035
|
for (r in a) if (r !== "_t") {
|
|
8970
9036
|
if (r[0] === "_") {
|
|
8971
9037
|
let e = r;
|
|
8972
|
-
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));
|
|
8973
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]}`);
|
|
8974
9040
|
} else {
|
|
8975
9041
|
let e = r;
|
|
@@ -8982,15 +9048,15 @@ var Om = {
|
|
|
8982
9048
|
});
|
|
8983
9049
|
}
|
|
8984
9050
|
}
|
|
8985
|
-
for (s = s.sort(
|
|
9051
|
+
for (s = s.sort(Nm.numerically), r = s.length - 1; r >= 0; r--) {
|
|
8986
9052
|
if (i = s[r], i === void 0) continue;
|
|
8987
9053
|
let e = a[`_${i}`], t = o.splice(i, 1)[0];
|
|
8988
|
-
(e == null ? void 0 : e[2]) ===
|
|
9054
|
+
(e == null ? void 0 : e[2]) === km && c.push({
|
|
8989
9055
|
index: e[1],
|
|
8990
9056
|
value: t
|
|
8991
9057
|
});
|
|
8992
9058
|
}
|
|
8993
|
-
c = c.sort(
|
|
9059
|
+
c = c.sort(Nm.numericallyBy("index"));
|
|
8994
9060
|
let u = c.length;
|
|
8995
9061
|
for (r = 0; r < u; r++) {
|
|
8996
9062
|
let e = c[r];
|
|
@@ -9000,7 +9066,7 @@ var Om = {
|
|
|
9000
9066
|
if (d > 0) for (r = 0; r < d; r++) {
|
|
9001
9067
|
let t = l[r];
|
|
9002
9068
|
if (t === void 0) continue;
|
|
9003
|
-
let n = new
|
|
9069
|
+
let n = new xm(o[t.index], t.delta);
|
|
9004
9070
|
e.push(n, t.index);
|
|
9005
9071
|
}
|
|
9006
9072
|
if (!e.children) {
|
|
@@ -9009,8 +9075,8 @@ var Om = {
|
|
|
9009
9075
|
}
|
|
9010
9076
|
e.exit();
|
|
9011
9077
|
};
|
|
9012
|
-
|
|
9013
|
-
var
|
|
9078
|
+
Pm.filterName = "arrays";
|
|
9079
|
+
var Fm = function(e) {
|
|
9014
9080
|
if (!e || !e.children || e.delta._t !== "a") return;
|
|
9015
9081
|
let t = e.left, n = e.children.length;
|
|
9016
9082
|
for (let r = 0; r < n; r++) {
|
|
@@ -9021,16 +9087,16 @@ var Am = function(e) {
|
|
|
9021
9087
|
}
|
|
9022
9088
|
e.setResult(t).exit();
|
|
9023
9089
|
};
|
|
9024
|
-
|
|
9025
|
-
var
|
|
9090
|
+
Fm.filterName = "arraysCollectChildren";
|
|
9091
|
+
var Im = function(e) {
|
|
9026
9092
|
if (!e.nested) {
|
|
9027
9093
|
let t = e.delta;
|
|
9028
|
-
if (t[2] ===
|
|
9094
|
+
if (t[2] === km) {
|
|
9029
9095
|
let n = t;
|
|
9030
9096
|
e.newName = `_${n[1]}`, e.setResult([
|
|
9031
9097
|
n[0],
|
|
9032
9098
|
Number.parseInt(e.childName.substring(1), 10),
|
|
9033
|
-
|
|
9099
|
+
km
|
|
9034
9100
|
]).exit();
|
|
9035
9101
|
}
|
|
9036
9102
|
return;
|
|
@@ -9040,20 +9106,20 @@ var jm = function(e) {
|
|
|
9040
9106
|
let n = t;
|
|
9041
9107
|
for (let t in n) {
|
|
9042
9108
|
if (t === "_t") continue;
|
|
9043
|
-
let r = new
|
|
9109
|
+
let r = new Sm(n[t]);
|
|
9044
9110
|
e.push(r, t);
|
|
9045
9111
|
}
|
|
9046
9112
|
e.exit();
|
|
9047
9113
|
};
|
|
9048
|
-
|
|
9049
|
-
var
|
|
9114
|
+
Im.filterName = "arrays";
|
|
9115
|
+
var Lm = (e, t, n) => {
|
|
9050
9116
|
if (typeof t == "string" && t[0] === "_") return Number.parseInt(t.substring(1), 10);
|
|
9051
9117
|
if (Array.isArray(n) && n[2] === 0) return `_${t}`;
|
|
9052
9118
|
let r = +t;
|
|
9053
9119
|
for (let n in e) {
|
|
9054
9120
|
let i = e[n];
|
|
9055
9121
|
if (Array.isArray(i)) {
|
|
9056
|
-
if (i[2] ===
|
|
9122
|
+
if (i[2] === km) {
|
|
9057
9123
|
let e = Number.parseInt(n.substring(1), 10), a = i[1];
|
|
9058
9124
|
if (a === +t) return e;
|
|
9059
9125
|
e <= r && a > r ? r++ : e >= r && a < r && r--;
|
|
@@ -9061,7 +9127,7 @@ var Mm = (e, t, n) => {
|
|
|
9061
9127
|
}
|
|
9062
9128
|
}
|
|
9063
9129
|
return r;
|
|
9064
|
-
},
|
|
9130
|
+
}, Rm = (e) => {
|
|
9065
9131
|
if (!e || !e.children) return;
|
|
9066
9132
|
let t = e.delta;
|
|
9067
9133
|
if (t._t !== "a") return;
|
|
@@ -9072,22 +9138,22 @@ var Mm = (e, t, n) => {
|
|
|
9072
9138
|
let a = r.newName;
|
|
9073
9139
|
if (a === void 0) {
|
|
9074
9140
|
if (r.childName === void 0) throw Error("child.childName is undefined");
|
|
9075
|
-
a =
|
|
9141
|
+
a = Lm(n, r.childName, r.result);
|
|
9076
9142
|
}
|
|
9077
9143
|
i[a] !== r.result && (i[a] = r.result);
|
|
9078
9144
|
}
|
|
9079
9145
|
e.setResult(i).exit();
|
|
9080
9146
|
};
|
|
9081
|
-
|
|
9147
|
+
Rm.filterName = "arraysCollectChildren";
|
|
9082
9148
|
//#endregion
|
|
9083
9149
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/dates.js
|
|
9084
|
-
var
|
|
9150
|
+
var zm = function(e) {
|
|
9085
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();
|
|
9086
9152
|
};
|
|
9087
|
-
|
|
9153
|
+
zm.filterName = "dates";
|
|
9088
9154
|
//#endregion
|
|
9089
9155
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/nested.js
|
|
9090
|
-
var
|
|
9156
|
+
var Bm = /* @__PURE__ */ new Set(["__proto__"]), Vm = (e) => {
|
|
9091
9157
|
if (!e || !e.children) return;
|
|
9092
9158
|
let t = e.children.length, n = e.result;
|
|
9093
9159
|
for (let r = 0; r < t; r++) {
|
|
@@ -9099,18 +9165,18 @@ var Fm = /* @__PURE__ */ new Set(["__proto__"]), Im = (e) => {
|
|
|
9099
9165
|
}
|
|
9100
9166
|
n && e.leftIsArray && (n._t = "a"), e.setResult(n).exit();
|
|
9101
9167
|
};
|
|
9102
|
-
|
|
9103
|
-
var
|
|
9168
|
+
Vm.filterName = "collectChildren";
|
|
9169
|
+
var Hm = (e) => {
|
|
9104
9170
|
var t;
|
|
9105
9171
|
if (e.leftIsArray || e.leftType !== "object") return;
|
|
9106
9172
|
let n = e.left, r = e.right, i = (t = e.options) == null ? void 0 : t.propertyFilter;
|
|
9107
9173
|
for (let t in n) {
|
|
9108
9174
|
if (!Object.prototype.hasOwnProperty.call(n, t) || i && !i(t, e)) continue;
|
|
9109
|
-
let a = new
|
|
9175
|
+
let a = new bm(n[t], r[t]);
|
|
9110
9176
|
e.push(a, t);
|
|
9111
9177
|
}
|
|
9112
9178
|
for (let t in r) if (Object.prototype.hasOwnProperty.call(r, t) && !(i && !i(t, e)) && n[t] === void 0) {
|
|
9113
|
-
let n = new
|
|
9179
|
+
let n = new bm(void 0, r[t]);
|
|
9114
9180
|
e.push(n, t);
|
|
9115
9181
|
}
|
|
9116
9182
|
if (!e.children || e.children.length === 0) {
|
|
@@ -9119,15 +9185,15 @@ var Lm = (e) => {
|
|
|
9119
9185
|
}
|
|
9120
9186
|
e.exit();
|
|
9121
9187
|
};
|
|
9122
|
-
|
|
9123
|
-
var
|
|
9188
|
+
Hm.filterName = "objects";
|
|
9189
|
+
var Um = function(e) {
|
|
9124
9190
|
if (!e.nested) return;
|
|
9125
9191
|
let t = e.delta;
|
|
9126
9192
|
if (t._t) return;
|
|
9127
9193
|
let n = t, r = !1;
|
|
9128
9194
|
for (let t in n) {
|
|
9129
|
-
if (
|
|
9130
|
-
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]);
|
|
9131
9197
|
e.push(a, t), r = !0;
|
|
9132
9198
|
}
|
|
9133
9199
|
if (!r) {
|
|
@@ -9136,8 +9202,8 @@ var Rm = function(e) {
|
|
|
9136
9202
|
}
|
|
9137
9203
|
e.exit();
|
|
9138
9204
|
};
|
|
9139
|
-
|
|
9140
|
-
var
|
|
9205
|
+
Um.filterName = "objects";
|
|
9206
|
+
var Wm = function(e) {
|
|
9141
9207
|
if (!e || !e.children || e.delta._t) return;
|
|
9142
9208
|
if (e.left === null || typeof e.left != "object") {
|
|
9143
9209
|
e.setResult(e.left).exit();
|
|
@@ -9148,17 +9214,17 @@ var zm = function(e) {
|
|
|
9148
9214
|
let n = e.children[r];
|
|
9149
9215
|
if (n === void 0) continue;
|
|
9150
9216
|
let i = n.childName;
|
|
9151
|
-
|
|
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));
|
|
9152
9218
|
}
|
|
9153
9219
|
e.setResult(t).exit();
|
|
9154
9220
|
};
|
|
9155
|
-
|
|
9156
|
-
var
|
|
9221
|
+
Wm.filterName = "collectChildren";
|
|
9222
|
+
var Gm = function(e) {
|
|
9157
9223
|
if (!e.nested || e.delta._t) return;
|
|
9158
9224
|
let t = e.delta, n = !1;
|
|
9159
9225
|
for (let r in t) {
|
|
9160
|
-
if (
|
|
9161
|
-
let i = new
|
|
9226
|
+
if (Bm.has(r) || !Object.prototype.hasOwnProperty.call(t, r)) continue;
|
|
9227
|
+
let i = new Sm(t[r]);
|
|
9162
9228
|
e.push(i, r), n = !0;
|
|
9163
9229
|
}
|
|
9164
9230
|
if (!n) {
|
|
@@ -9167,25 +9233,25 @@ var Bm = function(e) {
|
|
|
9167
9233
|
}
|
|
9168
9234
|
e.exit();
|
|
9169
9235
|
};
|
|
9170
|
-
|
|
9171
|
-
var
|
|
9236
|
+
Gm.filterName = "objects";
|
|
9237
|
+
var Km = (e) => {
|
|
9172
9238
|
if (!e || !e.children || e.delta._t) return;
|
|
9173
9239
|
let t = e.children.length, n = {};
|
|
9174
9240
|
for (let r = 0; r < t; r++) {
|
|
9175
9241
|
let t = e.children[r];
|
|
9176
9242
|
if (t === void 0) continue;
|
|
9177
9243
|
let i = t.childName;
|
|
9178
|
-
|
|
9244
|
+
Bm.has(i) || n[i] !== t.result && (n[i] = t.result);
|
|
9179
9245
|
}
|
|
9180
9246
|
e.setResult(n).exit();
|
|
9181
9247
|
};
|
|
9182
|
-
|
|
9248
|
+
Km.filterName = "collectChildren";
|
|
9183
9249
|
//#endregion
|
|
9184
9250
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/texts.js
|
|
9185
|
-
var
|
|
9186
|
-
function
|
|
9251
|
+
var qm = 2, Jm = 60, Ym = null;
|
|
9252
|
+
function Xm(e, t) {
|
|
9187
9253
|
var n;
|
|
9188
|
-
if (!
|
|
9254
|
+
if (!Ym) {
|
|
9189
9255
|
let r;
|
|
9190
9256
|
if ((n = e == null ? void 0 : e.textDiff) != null && n.diffMatchPatch) r = new e.textDiff.diffMatchPatch();
|
|
9191
9257
|
else {
|
|
@@ -9193,7 +9259,7 @@ function Gm(e, t) {
|
|
|
9193
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.");
|
|
9194
9260
|
throw e.diff_match_patch_not_found = !0, e;
|
|
9195
9261
|
}
|
|
9196
|
-
|
|
9262
|
+
Ym = {
|
|
9197
9263
|
diff: (e, t) => r.patch_toText(r.patch_make(e, t)),
|
|
9198
9264
|
patch: (e, t) => {
|
|
9199
9265
|
let n = r.patch_apply(r.patch_fromText(t), e);
|
|
@@ -9205,17 +9271,17 @@ function Gm(e, t) {
|
|
|
9205
9271
|
}
|
|
9206
9272
|
};
|
|
9207
9273
|
}
|
|
9208
|
-
return
|
|
9274
|
+
return Ym;
|
|
9209
9275
|
}
|
|
9210
|
-
var
|
|
9276
|
+
var Zm = function(e) {
|
|
9211
9277
|
var t, n;
|
|
9212
9278
|
if (e.leftType !== "string") return;
|
|
9213
|
-
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;
|
|
9214
9280
|
if (r.length < a || i.length < a) {
|
|
9215
9281
|
e.setResult([r, i]).exit();
|
|
9216
9282
|
return;
|
|
9217
9283
|
}
|
|
9218
|
-
let o =
|
|
9284
|
+
let o = Xm(e.options);
|
|
9219
9285
|
if (!o) {
|
|
9220
9286
|
e.setResult([r, i]).exit();
|
|
9221
9287
|
return;
|
|
@@ -9224,19 +9290,19 @@ var Km = function(e) {
|
|
|
9224
9290
|
e.setResult([
|
|
9225
9291
|
s(r, i),
|
|
9226
9292
|
0,
|
|
9227
|
-
|
|
9293
|
+
qm
|
|
9228
9294
|
]).exit();
|
|
9229
9295
|
};
|
|
9230
|
-
|
|
9231
|
-
var
|
|
9296
|
+
Zm.filterName = "texts";
|
|
9297
|
+
var Qm = function(e) {
|
|
9232
9298
|
if (e.nested) return;
|
|
9233
9299
|
let t = e.delta;
|
|
9234
|
-
if (t[2] !==
|
|
9235
|
-
let n = t, r =
|
|
9300
|
+
if (t[2] !== qm) return;
|
|
9301
|
+
let n = t, r = Xm(e.options, !0).patch;
|
|
9236
9302
|
e.setResult(r(e.left, n[0])).exit();
|
|
9237
9303
|
};
|
|
9238
|
-
|
|
9239
|
-
var
|
|
9304
|
+
Qm.filterName = "texts";
|
|
9305
|
+
var $m = (e) => {
|
|
9240
9306
|
var t, n, r;
|
|
9241
9307
|
let i = /^@@ +-(\d+),(\d+) +\+(\d+),(\d+) +@@$/, a = e.split("\n");
|
|
9242
9308
|
for (let e = 0; e < a.length; e++) {
|
|
@@ -9257,21 +9323,21 @@ var Jm = (e) => {
|
|
|
9257
9323
|
} else s === "-" && (a[e] = `+${(r = a[e]) == null ? void 0 : r.slice(1)}`);
|
|
9258
9324
|
}
|
|
9259
9325
|
return a.join("\n");
|
|
9260
|
-
},
|
|
9326
|
+
}, eh = function(e) {
|
|
9261
9327
|
if (e.nested) return;
|
|
9262
9328
|
let t = e.delta;
|
|
9263
|
-
if (t[2] !==
|
|
9329
|
+
if (t[2] !== qm) return;
|
|
9264
9330
|
let n = t;
|
|
9265
9331
|
e.setResult([
|
|
9266
|
-
|
|
9332
|
+
$m(n[0]),
|
|
9267
9333
|
0,
|
|
9268
|
-
|
|
9334
|
+
qm
|
|
9269
9335
|
]).exit();
|
|
9270
9336
|
};
|
|
9271
|
-
|
|
9337
|
+
eh.filterName = "texts";
|
|
9272
9338
|
//#endregion
|
|
9273
9339
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/filters/trivial.js
|
|
9274
|
-
var
|
|
9340
|
+
var th = function(e) {
|
|
9275
9341
|
if (e.left === e.right) {
|
|
9276
9342
|
e.setResult(void 0).exit();
|
|
9277
9343
|
return;
|
|
@@ -9304,8 +9370,8 @@ var Xm = function(e) {
|
|
|
9304
9370
|
}
|
|
9305
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());
|
|
9306
9372
|
};
|
|
9307
|
-
|
|
9308
|
-
var
|
|
9373
|
+
th.filterName = "trivial";
|
|
9374
|
+
var nh = function(e) {
|
|
9309
9375
|
if (e.delta === void 0) {
|
|
9310
9376
|
e.setResult(e.left).exit();
|
|
9311
9377
|
return;
|
|
@@ -9329,8 +9395,8 @@ var Zm = function(e) {
|
|
|
9329
9395
|
}
|
|
9330
9396
|
t.length === 3 && t[2] === 0 && e.setResult(void 0).exit();
|
|
9331
9397
|
};
|
|
9332
|
-
|
|
9333
|
-
var
|
|
9398
|
+
nh.filterName = "trivial";
|
|
9399
|
+
var rh = function(e) {
|
|
9334
9400
|
if (e.delta === void 0) {
|
|
9335
9401
|
e.setResult(e.delta).exit();
|
|
9336
9402
|
return;
|
|
@@ -9351,36 +9417,36 @@ var Qm = function(e) {
|
|
|
9351
9417
|
}
|
|
9352
9418
|
t.length === 3 && t[2] === 0 && e.setResult([t[0]]).exit();
|
|
9353
9419
|
};
|
|
9354
|
-
|
|
9420
|
+
rh.filterName = "trivial";
|
|
9355
9421
|
//#endregion
|
|
9356
9422
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/diffpatcher.js
|
|
9357
|
-
var
|
|
9423
|
+
var ih = class {
|
|
9358
9424
|
constructor(e) {
|
|
9359
|
-
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());
|
|
9360
9426
|
}
|
|
9361
9427
|
options(e) {
|
|
9362
9428
|
return this.processor.options(e);
|
|
9363
9429
|
}
|
|
9364
9430
|
diff(e, t) {
|
|
9365
|
-
return this.processor.process(new
|
|
9431
|
+
return this.processor.process(new bm(e, t));
|
|
9366
9432
|
}
|
|
9367
9433
|
patch(e, t) {
|
|
9368
|
-
return this.processor.process(new
|
|
9434
|
+
return this.processor.process(new xm(e, t));
|
|
9369
9435
|
}
|
|
9370
9436
|
reverse(e) {
|
|
9371
|
-
return this.processor.process(new
|
|
9437
|
+
return this.processor.process(new Sm(e));
|
|
9372
9438
|
}
|
|
9373
9439
|
unpatch(e, t) {
|
|
9374
9440
|
return this.patch(e, this.reverse(t));
|
|
9375
9441
|
}
|
|
9376
9442
|
clone(e) {
|
|
9377
|
-
return
|
|
9443
|
+
return gm(e);
|
|
9378
9444
|
}
|
|
9379
9445
|
};
|
|
9380
9446
|
//#endregion
|
|
9381
9447
|
//#region node_modules/.pnpm/jsondiffpatch@0.7.6/node_modules/jsondiffpatch/lib/index.js
|
|
9382
|
-
function
|
|
9383
|
-
return new
|
|
9448
|
+
function ah(e) {
|
|
9449
|
+
return new ih(e);
|
|
9384
9450
|
}
|
|
9385
9451
|
//#endregion
|
|
9386
9452
|
//#region node_modules/.pnpm/@dmsnell+diff-match-patch@1.1.0/node_modules/@dmsnell/diff-match-patch/index.js
|
|
@@ -9942,46 +10008,46 @@ $.Diff = function(e, t) {
|
|
|
9942
10008
|
};
|
|
9943
10009
|
//#endregion
|
|
9944
10010
|
//#region src/components/audit-log/create-diff-patcher.tsx
|
|
9945
|
-
var
|
|
10011
|
+
var oh = (e = {}) => ah({
|
|
9946
10012
|
...e,
|
|
9947
10013
|
textDiff: {
|
|
9948
10014
|
diffMatchPatch: $,
|
|
9949
10015
|
minLength: 120
|
|
9950
10016
|
},
|
|
9951
10017
|
cloneDiffValues: !0
|
|
9952
|
-
}),
|
|
10018
|
+
}), sh = ["user", "unittemplate"], ch = oh(), lh = (e, t, n) => {
|
|
9953
10019
|
let r = Object.fromEntries(e.map((e) => [e.sectionKey, e.sectionLabel]));
|
|
9954
10020
|
for (let e = t.length - 1; e >= 0; e--) {
|
|
9955
10021
|
let n = r[t[e]];
|
|
9956
10022
|
if (n) return n;
|
|
9957
10023
|
}
|
|
9958
10024
|
return n || "";
|
|
9959
|
-
},
|
|
10025
|
+
}, uh = (e) => {
|
|
9960
10026
|
let t = (e) => rr(e) ? hr(e) : String(e);
|
|
9961
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);
|
|
9962
|
-
},
|
|
10028
|
+
}, dh = (e) => {
|
|
9963
10029
|
switch (e.length) {
|
|
9964
10030
|
case 1: {
|
|
9965
10031
|
let [t] = e;
|
|
9966
10032
|
return {
|
|
9967
10033
|
type: "created",
|
|
9968
10034
|
before: "",
|
|
9969
|
-
after:
|
|
10035
|
+
after: uh(t)
|
|
9970
10036
|
};
|
|
9971
10037
|
}
|
|
9972
10038
|
case 2: {
|
|
9973
10039
|
let [t, n] = e;
|
|
9974
10040
|
return {
|
|
9975
10041
|
type: "modified",
|
|
9976
|
-
before:
|
|
9977
|
-
after:
|
|
10042
|
+
before: uh(t),
|
|
10043
|
+
after: uh(n)
|
|
9978
10044
|
};
|
|
9979
10045
|
}
|
|
9980
10046
|
case 3: {
|
|
9981
10047
|
let [t] = e;
|
|
9982
10048
|
return {
|
|
9983
10049
|
type: "deleted",
|
|
9984
|
-
before:
|
|
10050
|
+
before: uh(t),
|
|
9985
10051
|
after: ""
|
|
9986
10052
|
};
|
|
9987
10053
|
}
|
|
@@ -9991,15 +10057,15 @@ var th = (e = {}) => eh({
|
|
|
9991
10057
|
after: ""
|
|
9992
10058
|
};
|
|
9993
10059
|
}
|
|
9994
|
-
},
|
|
9995
|
-
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);
|
|
9996
10062
|
if (!r) return {
|
|
9997
10063
|
oldJson: "",
|
|
9998
10064
|
newJson: "",
|
|
9999
10065
|
error: `Cannot create comparison view: missing date for audit log ${e.id}`
|
|
10000
10066
|
};
|
|
10001
10067
|
let i = t.filter((e) => {
|
|
10002
|
-
let t =
|
|
10068
|
+
let t = mh(e);
|
|
10003
10069
|
return !!(e.diffs && t && t >= r);
|
|
10004
10070
|
}), a = Array.from({ length: i.length + 1 });
|
|
10005
10071
|
a[0] = nn(n);
|
|
@@ -10012,7 +10078,7 @@ var th = (e = {}) => eh({
|
|
|
10012
10078
|
a[e + 1] = a[e];
|
|
10013
10079
|
continue;
|
|
10014
10080
|
}
|
|
10015
|
-
a[e + 1] =
|
|
10081
|
+
a[e + 1] = ph(a[e], t);
|
|
10016
10082
|
}
|
|
10017
10083
|
let e = i.length > 0 ? a[i.length - 1] : n, t = i.length > 0 ? a[i.length] : n;
|
|
10018
10084
|
o = JSON.stringify(t == null ? "" : t, null, 2), s = JSON.stringify(e == null ? "" : e, null, 2);
|
|
@@ -10027,10 +10093,10 @@ var th = (e = {}) => eh({
|
|
|
10027
10093
|
oldJson: o,
|
|
10028
10094
|
newJson: s
|
|
10029
10095
|
};
|
|
10030
|
-
},
|
|
10096
|
+
}, gh = (e, t, n = {}, r = []) => {
|
|
10031
10097
|
var i;
|
|
10032
10098
|
if (!e) return;
|
|
10033
|
-
let a = [...
|
|
10099
|
+
let a = [...sh, ...(i = n.hiddenKeys) == null ? [] : i];
|
|
10034
10100
|
Object.keys(e).forEach((i) => {
|
|
10035
10101
|
var o;
|
|
10036
10102
|
let s = e[i];
|
|
@@ -10043,12 +10109,12 @@ var th = (e = {}) => eh({
|
|
|
10043
10109
|
cn(s) ? t.push({
|
|
10044
10110
|
deltaFormat: [...s],
|
|
10045
10111
|
path: c
|
|
10046
|
-
}) : gn(s) &&
|
|
10112
|
+
}) : gn(s) && gh(s, t, n, c);
|
|
10047
10113
|
});
|
|
10048
|
-
},
|
|
10114
|
+
}, _h = (e, t = {}) => {
|
|
10049
10115
|
let n = [];
|
|
10050
|
-
return e ? (
|
|
10051
|
-
},
|
|
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) => {
|
|
10052
10118
|
if (e == null || e === "") return "empty";
|
|
10053
10119
|
if (typeof e == "boolean") return e ? "true" : "false";
|
|
10054
10120
|
if (typeof e == "string") return e;
|
|
@@ -10059,27 +10125,27 @@ var th = (e = {}) => eh({
|
|
|
10059
10125
|
} catch {
|
|
10060
10126
|
return String(e);
|
|
10061
10127
|
}
|
|
10062
|
-
},
|
|
10128
|
+
}, bh = (e, t = e.length - 1) => {
|
|
10063
10129
|
if (t >= e.length) return "Value";
|
|
10064
10130
|
let n = e[t];
|
|
10065
|
-
return !n || er(n) ?
|
|
10066
|
-
},
|
|
10067
|
-
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}` : "";
|
|
10068
10134
|
switch (t) {
|
|
10069
10135
|
case "modified": return `${e} updated ${n} from ${o} to ${s}${c}.`;
|
|
10070
10136
|
case "created": return `${e} created ${s}${c}.`;
|
|
10071
10137
|
case "deleted": return `${e} deleted ${o}${c}.`;
|
|
10072
10138
|
default: return `${e} changed ${n}${c}.`;
|
|
10073
10139
|
}
|
|
10074
|
-
},
|
|
10140
|
+
}, Sh = ({ sectionNames: e, userName: t, diffs: n, defaultSectionName: r }) => {
|
|
10075
10141
|
let i = {
|
|
10076
10142
|
headers: [{ cells: [{ value: "Changes" }] }],
|
|
10077
10143
|
rows: n.map((n) => {
|
|
10078
|
-
let { deltaFormat: i, path: a } = n, o =
|
|
10079
|
-
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({
|
|
10080
10146
|
userName: t,
|
|
10081
10147
|
type: s,
|
|
10082
|
-
property:
|
|
10148
|
+
property: bh(a),
|
|
10083
10149
|
before: c,
|
|
10084
10150
|
after: l,
|
|
10085
10151
|
sectionName: o
|
|
@@ -10087,7 +10153,7 @@ var th = (e = {}) => eh({
|
|
|
10087
10153
|
})
|
|
10088
10154
|
};
|
|
10089
10155
|
return /* @__PURE__ */ S($l, { table: i });
|
|
10090
|
-
},
|
|
10156
|
+
}, Ch = Object.freeze({
|
|
10091
10157
|
summary: {
|
|
10092
10158
|
label: "Summary",
|
|
10093
10159
|
value: "summary"
|
|
@@ -10096,13 +10162,13 @@ var th = (e = {}) => eh({
|
|
|
10096
10162
|
label: "Compare",
|
|
10097
10163
|
value: "compare"
|
|
10098
10164
|
}
|
|
10099
|
-
}),
|
|
10100
|
-
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 }) => ({
|
|
10101
10167
|
label: e,
|
|
10102
10168
|
value: t
|
|
10103
10169
|
})), [l, u] = v(c[0]), { diffs: d = void 0 } = e || {};
|
|
10104
10170
|
if (!d) return null;
|
|
10105
|
-
let { oldJson: f, newJson: p, error: m } =
|
|
10171
|
+
let { oldJson: f, newJson: p, error: m } = hh(e, t, n);
|
|
10106
10172
|
return /* @__PURE__ */ S(xs, {
|
|
10107
10173
|
visible: r,
|
|
10108
10174
|
centered: !0,
|
|
@@ -10110,20 +10176,20 @@ var th = (e = {}) => eh({
|
|
|
10110
10176
|
children: /* @__PURE__ */ S($o, { dialog: {
|
|
10111
10177
|
scroll: !0,
|
|
10112
10178
|
heading: "Comparison view",
|
|
10113
|
-
content: /* @__PURE__ */ C(x, { children: [/* @__PURE__ */ S(
|
|
10179
|
+
content: /* @__PURE__ */ C(x, { children: [/* @__PURE__ */ S(op, {
|
|
10114
10180
|
name: "ViewTab",
|
|
10115
10181
|
onChange: (e) => u(c.find((t) => t.value === e.target.value)),
|
|
10116
10182
|
options: c,
|
|
10117
10183
|
value: l
|
|
10118
|
-
}), l.value === "summary" ? /* @__PURE__ */ S(
|
|
10184
|
+
}), l.value === "summary" ? /* @__PURE__ */ S(Sh, {
|
|
10119
10185
|
userName: e.userName,
|
|
10120
10186
|
sectionNames: a,
|
|
10121
|
-
diffs:
|
|
10187
|
+
diffs: _h(d, i),
|
|
10122
10188
|
defaultSectionName: o
|
|
10123
10189
|
}) : m ? /* @__PURE__ */ S("div", {
|
|
10124
10190
|
style: { padding: 16 },
|
|
10125
10191
|
children: m
|
|
10126
|
-
}) : /* @__PURE__ */ S(
|
|
10192
|
+
}) : /* @__PURE__ */ S(om, {
|
|
10127
10193
|
oldJson: f,
|
|
10128
10194
|
newJson: p
|
|
10129
10195
|
})] }),
|
|
@@ -10136,7 +10202,7 @@ var th = (e = {}) => eh({
|
|
|
10136
10202
|
height: "90vh"
|
|
10137
10203
|
} })
|
|
10138
10204
|
});
|
|
10139
|
-
},
|
|
10205
|
+
}, Th = [
|
|
10140
10206
|
{
|
|
10141
10207
|
label: "10 / page",
|
|
10142
10208
|
value: 10
|
|
@@ -10149,15 +10215,15 @@ var th = (e = {}) => eh({
|
|
|
10149
10215
|
label: "50 / page",
|
|
10150
10216
|
value: 50
|
|
10151
10217
|
}
|
|
10152
|
-
],
|
|
10153
|
-
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";
|
|
10154
10220
|
if (a === "API" && !i) return o === "Created" ? "Created through API" : "Changed through API";
|
|
10155
10221
|
switch (o) {
|
|
10156
10222
|
case "Created": return "Created";
|
|
10157
10223
|
case "Cloned": return `Cloned (from design ID ${s})`;
|
|
10158
10224
|
case "Reverted": {
|
|
10159
|
-
let e = t.find((e) => e.id === s), n = e ?
|
|
10160
|
-
date:
|
|
10225
|
+
let e = t.find((e) => e.id === s), n = e ? mm({
|
|
10226
|
+
date: mh(e),
|
|
10161
10227
|
showTime: !0
|
|
10162
10228
|
}) : null;
|
|
10163
10229
|
return `Reverted${n ? ` (to ${n})` : ""}`;
|
|
@@ -10167,7 +10233,7 @@ var th = (e = {}) => eh({
|
|
|
10167
10233
|
case "Updated": return `Updated (${l})`;
|
|
10168
10234
|
default: return "Updated";
|
|
10169
10235
|
}
|
|
10170
|
-
},
|
|
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 }) => {
|
|
10171
10237
|
let [_, y] = v(!1), [b, w] = v(null), T = (e) => {
|
|
10172
10238
|
if (e.snapshot) {
|
|
10173
10239
|
f == null || f(e.snapshot, e);
|
|
@@ -10186,7 +10252,7 @@ var th = (e = {}) => eh({
|
|
|
10186
10252
|
return {
|
|
10187
10253
|
cells: [
|
|
10188
10254
|
{
|
|
10189
|
-
value: t.snapshot ? `Snapshot: ${t.snapshot}` :
|
|
10255
|
+
value: t.snapshot ? `Snapshot: ${t.snapshot}` : Eh(t, e, l),
|
|
10190
10256
|
type: "Link",
|
|
10191
10257
|
disabled: a,
|
|
10192
10258
|
onClick: a ? void 0 : r && g ? () => g(t.operationMetaData) : () => T(t),
|
|
@@ -10205,8 +10271,8 @@ var th = (e = {}) => eh({
|
|
|
10205
10271
|
type: "Static"
|
|
10206
10272
|
},
|
|
10207
10273
|
{
|
|
10208
|
-
value:
|
|
10209
|
-
date:
|
|
10274
|
+
value: mm({
|
|
10275
|
+
date: mh(t),
|
|
10210
10276
|
showTime: !0
|
|
10211
10277
|
}),
|
|
10212
10278
|
type: "Static"
|
|
@@ -10249,14 +10315,14 @@ var th = (e = {}) => eh({
|
|
|
10249
10315
|
onChange: (e) => {
|
|
10250
10316
|
u(Number(e.target.value));
|
|
10251
10317
|
},
|
|
10252
|
-
options:
|
|
10318
|
+
options: Th,
|
|
10253
10319
|
value: a
|
|
10254
10320
|
},
|
|
10255
10321
|
onSelectPage: (e) => d(e),
|
|
10256
10322
|
small: !0
|
|
10257
10323
|
} }
|
|
10258
10324
|
} })
|
|
10259
|
-
}), _ && b && b.diffs && /* @__PURE__ */ S(
|
|
10325
|
+
}), _ && b && b.diffs && /* @__PURE__ */ S(wh, {
|
|
10260
10326
|
sectionNames: o,
|
|
10261
10327
|
isOpen: _,
|
|
10262
10328
|
onClose: () => y(!1),
|
|
@@ -10266,7 +10332,7 @@ var th = (e = {}) => eh({
|
|
|
10266
10332
|
data: t,
|
|
10267
10333
|
transformDiffsConfig: l
|
|
10268
10334
|
})] });
|
|
10269
|
-
},
|
|
10335
|
+
}, Oh = ({ pathName: e, moduleName: t, onNavigate: n, onStartTimingEvent: r }) => {
|
|
10270
10336
|
let i = window.location.href, a = _(i);
|
|
10271
10337
|
return d(() => {
|
|
10272
10338
|
a.current = i;
|
|
@@ -10289,20 +10355,20 @@ var th = (e = {}) => eh({
|
|
|
10289
10355
|
});
|
|
10290
10356
|
};
|
|
10291
10357
|
}, [e, t]), null;
|
|
10292
|
-
},
|
|
10358
|
+
}, kh = {
|
|
10293
10359
|
errorBoundary: "_errorBoundary_hmco0_1",
|
|
10294
10360
|
sidebarErrorBoundary: "_sidebarErrorBoundary_hmco0_5",
|
|
10295
10361
|
rightSidebarErrorBoundary: "_rightSidebarErrorBoundary_hmco0_6"
|
|
10296
|
-
},
|
|
10297
|
-
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();
|
|
10298
10364
|
if (t) return /* @__PURE__ */ S(t, {});
|
|
10299
10365
|
if (n || r) return /* @__PURE__ */ S("div", {
|
|
10300
|
-
className: b(n ?
|
|
10366
|
+
className: b(n ? kh.sidebarErrorBoundary : "", r ? kh.rightSidebarErrorBoundary : ""),
|
|
10301
10367
|
style: a,
|
|
10302
10368
|
children: o == null ? void 0 : o.unexpectedError
|
|
10303
10369
|
});
|
|
10304
10370
|
let s = /* @__PURE__ */ S("div", {
|
|
10305
|
-
className:
|
|
10371
|
+
className: kh.errorBoundary,
|
|
10306
10372
|
style: a,
|
|
10307
10373
|
children: /* @__PURE__ */ S(Vs, { message: {
|
|
10308
10374
|
icon: !0,
|
|
@@ -10317,19 +10383,19 @@ var th = (e = {}) => eh({
|
|
|
10317
10383
|
padding: 0,
|
|
10318
10384
|
children: s
|
|
10319
10385
|
}) : s;
|
|
10320
|
-
},
|
|
10321
|
-
fallback: /* @__PURE__ */ S(
|
|
10386
|
+
}, jh = ({ children: e, options: t }) => /* @__PURE__ */ S(Oi.ErrorBoundary, {
|
|
10387
|
+
fallback: /* @__PURE__ */ S(Ah, { options: t }),
|
|
10322
10388
|
onError: (e, t) => {
|
|
10323
10389
|
console.error("Error caught by boundary:", e, t);
|
|
10324
10390
|
},
|
|
10325
10391
|
children: e
|
|
10326
|
-
}),
|
|
10392
|
+
}), Mh = (e, t = {}) => (n) => /* @__PURE__ */ S(jh, {
|
|
10327
10393
|
options: t,
|
|
10328
10394
|
children: /* @__PURE__ */ S(e, { ...n })
|
|
10329
|
-
}),
|
|
10330
|
-
Lp
|
|
10331
|
-
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 });
|
|
10332
10398
|
});
|
|
10333
10399
|
};
|
|
10334
10400
|
//#endregion
|
|
10335
|
-
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 };
|