@michelangelo-ai/core 0.7.0 → 0.8.0-rc.2
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/components/form/fields/string/components/editable-string-tag.d.ts.map +1 -1
- package/dist/components/form/fields/string/components/multi-string-field.d.ts.map +1 -1
- package/dist/components/form/layout/array-form-group/array-form-group.d.ts.map +1 -1
- package/dist/components/links-box/__tests__/links-box.test.d.ts +2 -0
- package/dist/components/links-box/__tests__/links-box.test.d.ts.map +1 -0
- package/dist/components/links-box/links-box.d.ts +7 -0
- package/dist/components/links-box/links-box.d.ts.map +1 -0
- package/dist/components/links-box/map-link-config-to-column-config.d.ts +4 -0
- package/dist/components/links-box/map-link-config-to-column-config.d.ts.map +1 -0
- package/dist/components/links-box/types.d.ts +11 -0
- package/dist/components/links-box/types.d.ts.map +1 -0
- package/dist/components/message-container/__tests__/message-container.test.d.ts +2 -0
- package/dist/components/message-container/__tests__/message-container.test.d.ts.map +1 -0
- package/dist/components/message-container/message-container.d.ts +7 -0
- package/dist/components/message-container/message-container.d.ts.map +1 -0
- package/dist/components/message-container/styled-components.d.ts +6 -0
- package/dist/components/message-container/styled-components.d.ts.map +1 -0
- package/dist/components/message-container/types.d.ts +17 -0
- package/dist/components/message-container/types.d.ts.map +1 -0
- package/dist/components/row/types.d.ts +0 -2
- package/dist/components/row/types.d.ts.map +1 -1
- package/dist/michelangelo-core.cjs +8 -8
- package/dist/michelangelo-core.js +290 -305
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -469,15 +469,15 @@ function Pr(i, e, t, n) {
|
|
|
469
469
|
headers: []
|
|
470
470
|
}, m = [];
|
|
471
471
|
f.forEach((y) => {
|
|
472
|
-
const b = [...m].reverse()[0],
|
|
473
|
-
let
|
|
474
|
-
if (
|
|
472
|
+
const b = [...m].reverse()[0], v = y.column.depth === p.depth;
|
|
473
|
+
let x, C = !1;
|
|
474
|
+
if (v && y.column.parent ? x = y.column.parent : (x = y.column, C = !0), b && (b == null ? void 0 : b.column) === x)
|
|
475
475
|
b.subHeaders.push(y);
|
|
476
476
|
else {
|
|
477
|
-
const S = Ac(t,
|
|
478
|
-
id: [n, d,
|
|
477
|
+
const S = Ac(t, x, {
|
|
478
|
+
id: [n, d, x.id, y == null ? void 0 : y.id].filter(Boolean).join("_"),
|
|
479
479
|
isPlaceholder: C,
|
|
480
|
-
placeholderId: C ? `${m.filter((k) => k.column ===
|
|
480
|
+
placeholderId: C ? `${m.filter((k) => k.column === x).length}` : void 0,
|
|
481
481
|
depth: d,
|
|
482
482
|
index: m.length
|
|
483
483
|
});
|
|
@@ -492,15 +492,15 @@ function Pr(i, e, t, n) {
|
|
|
492
492
|
c(u, o - 1), a.reverse();
|
|
493
493
|
const h = (f) => f.filter((p) => p.column.getIsVisible()).map((p) => {
|
|
494
494
|
let m = 0, y = 0, b = [0];
|
|
495
|
-
p.subHeaders && p.subHeaders.length ? (b = [], h(p.subHeaders).forEach((
|
|
495
|
+
p.subHeaders && p.subHeaders.length ? (b = [], h(p.subHeaders).forEach((x) => {
|
|
496
496
|
let {
|
|
497
497
|
colSpan: C,
|
|
498
498
|
rowSpan: S
|
|
499
|
-
} =
|
|
499
|
+
} = x;
|
|
500
500
|
m += C, b.push(S);
|
|
501
501
|
})) : m = 1;
|
|
502
|
-
const
|
|
503
|
-
return y = y +
|
|
502
|
+
const v = Math.min(...b);
|
|
503
|
+
return y = y + v, p.colSpan = m, p.rowSpan = y, {
|
|
504
504
|
colSpan: m,
|
|
505
505
|
rowSpan: y
|
|
506
506
|
};
|
|
@@ -1007,25 +1007,25 @@ const Dr = {
|
|
|
1007
1007
|
return (s) => {
|
|
1008
1008
|
if (!n || !r || (s.persist == null || s.persist(), wo(s) && s.touches && s.touches.length > 1))
|
|
1009
1009
|
return;
|
|
1010
|
-
const o = i.getSize(), l = i ? i.getLeafHeaders().map((b) => [b.column.id, b.column.getSize()]) : [[n.id, n.getSize()]], a = wo(s) ? Math.round(s.touches[0].clientX) : s.clientX, c = {}, u = (b,
|
|
1011
|
-
typeof
|
|
1010
|
+
const o = i.getSize(), l = i ? i.getLeafHeaders().map((b) => [b.column.id, b.column.getSize()]) : [[n.id, n.getSize()]], a = wo(s) ? Math.round(s.touches[0].clientX) : s.clientX, c = {}, u = (b, v) => {
|
|
1011
|
+
typeof v == "number" && (e.setColumnSizingInfo((x) => {
|
|
1012
1012
|
var C, S;
|
|
1013
|
-
const k = e.options.columnResizeDirection === "rtl" ? -1 : 1, E = (
|
|
1014
|
-
return
|
|
1013
|
+
const k = e.options.columnResizeDirection === "rtl" ? -1 : 1, E = (v - ((C = x == null ? void 0 : x.startOffset) != null ? C : 0)) * k, O = Math.max(E / ((S = x == null ? void 0 : x.startSize) != null ? S : 0), -0.999999);
|
|
1014
|
+
return x.columnSizingStart.forEach((R) => {
|
|
1015
1015
|
let [z, F] = R;
|
|
1016
1016
|
c[z] = Math.round(Math.max(F + F * O, 0) * 100) / 100;
|
|
1017
1017
|
}), {
|
|
1018
|
-
...
|
|
1018
|
+
...x,
|
|
1019
1019
|
deltaOffset: E,
|
|
1020
1020
|
deltaPercentage: O
|
|
1021
1021
|
};
|
|
1022
|
-
}), (e.options.columnResizeMode === "onChange" || b === "end") && e.setColumnSizing((
|
|
1023
|
-
...
|
|
1022
|
+
}), (e.options.columnResizeMode === "onChange" || b === "end") && e.setColumnSizing((x) => ({
|
|
1023
|
+
...x,
|
|
1024
1024
|
...c
|
|
1025
1025
|
})));
|
|
1026
1026
|
}, h = (b) => u("move", b), f = (b) => {
|
|
1027
|
-
u("end", b), e.setColumnSizingInfo((
|
|
1028
|
-
...
|
|
1027
|
+
u("end", b), e.setColumnSizingInfo((v) => ({
|
|
1028
|
+
...v,
|
|
1029
1029
|
isResizingColumn: !1,
|
|
1030
1030
|
startOffset: null,
|
|
1031
1031
|
startSize: null,
|
|
@@ -1041,8 +1041,8 @@ const Dr = {
|
|
|
1041
1041
|
}, m = {
|
|
1042
1042
|
moveHandler: (b) => (b.cancelable && (b.preventDefault(), b.stopPropagation()), h(b.touches[0].clientX), !1),
|
|
1043
1043
|
upHandler: (b) => {
|
|
1044
|
-
var
|
|
1045
|
-
d == null || d.removeEventListener("touchmove", m.moveHandler), d == null || d.removeEventListener("touchend", m.upHandler), b.cancelable && (b.preventDefault(), b.stopPropagation()), f((
|
|
1044
|
+
var v;
|
|
1045
|
+
d == null || d.removeEventListener("touchmove", m.moveHandler), d == null || d.removeEventListener("touchend", m.upHandler), b.cancelable && (b.preventDefault(), b.stopPropagation()), f((v = b.touches[0]) == null ? void 0 : v.clientX);
|
|
1046
1046
|
}
|
|
1047
1047
|
}, y = Py() ? {
|
|
1048
1048
|
passive: !1
|
|
@@ -1848,8 +1848,8 @@ function qy(i) {
|
|
|
1848
1848
|
getAllColumns: q(() => [r._getColumnDefs()], (f) => {
|
|
1849
1849
|
const d = function(p, m, y) {
|
|
1850
1850
|
return y === void 0 && (y = 0), p.map((b) => {
|
|
1851
|
-
const
|
|
1852
|
-
return
|
|
1851
|
+
const v = fy(r, b, y, m), x = b;
|
|
1852
|
+
return v.columns = x.columns ? d(x.columns, v, y + 1) : [], v;
|
|
1853
1853
|
});
|
|
1854
1854
|
};
|
|
1855
1855
|
return d(f);
|
|
@@ -2041,17 +2041,17 @@ function Zy() {
|
|
|
2041
2041
|
return a.map((p) => (p.depth = c, r.push(p), s[p.id] = p, p.subRows && (p.subRows = o(p.subRows, c + 1, p.id)), p));
|
|
2042
2042
|
const h = n[c], f = eb(a, h);
|
|
2043
2043
|
return Array.from(f.entries()).map((p, m) => {
|
|
2044
|
-
let [y, b] = p,
|
|
2045
|
-
|
|
2046
|
-
const
|
|
2047
|
-
|
|
2048
|
-
k.parentId =
|
|
2044
|
+
let [y, b] = p, v = `${h}:${y}`;
|
|
2045
|
+
v = u ? `${u}>${v}` : v;
|
|
2046
|
+
const x = o(b, c + 1, v);
|
|
2047
|
+
x.forEach((k) => {
|
|
2048
|
+
k.parentId = v;
|
|
2049
2049
|
});
|
|
2050
|
-
const C = c ? pf(b, (k) => k.subRows) : b, S = to(i,
|
|
2050
|
+
const C = c ? pf(b, (k) => k.subRows) : b, S = to(i, v, C[0].original, m, c, void 0, u);
|
|
2051
2051
|
return Object.assign(S, {
|
|
2052
2052
|
groupingColumnId: h,
|
|
2053
2053
|
groupingValue: y,
|
|
2054
|
-
subRows:
|
|
2054
|
+
subRows: x,
|
|
2055
2055
|
leafRows: C,
|
|
2056
2056
|
getValue: (k) => {
|
|
2057
2057
|
if (n.includes(k)) {
|
|
@@ -2069,7 +2069,7 @@ function Zy() {
|
|
|
2069
2069
|
if (R)
|
|
2070
2070
|
return S._groupingValuesCache[k] = R(k, C, b), S._groupingValuesCache[k];
|
|
2071
2071
|
}
|
|
2072
|
-
}),
|
|
2072
|
+
}), x.forEach((k) => {
|
|
2073
2073
|
r.push(k), s[k.id] = k;
|
|
2074
2074
|
}), S;
|
|
2075
2075
|
});
|
|
@@ -2149,17 +2149,17 @@ function ib() {
|
|
|
2149
2149
|
for (let d = 0; d < s.length; d += 1) {
|
|
2150
2150
|
var f;
|
|
2151
2151
|
const p = s[d], m = o[p.id], y = m.sortUndefined, b = (f = p == null ? void 0 : p.desc) != null ? f : !1;
|
|
2152
|
-
let
|
|
2152
|
+
let v = 0;
|
|
2153
2153
|
if (y) {
|
|
2154
|
-
const
|
|
2154
|
+
const x = u.getValue(p.id), C = h.getValue(p.id), S = x === void 0, k = C === void 0;
|
|
2155
2155
|
if (S || k) {
|
|
2156
2156
|
if (y === "first") return S ? -1 : 1;
|
|
2157
2157
|
if (y === "last") return S ? 1 : -1;
|
|
2158
|
-
|
|
2158
|
+
v = S && k ? 0 : S ? y : -y;
|
|
2159
2159
|
}
|
|
2160
2160
|
}
|
|
2161
|
-
if (
|
|
2162
|
-
return b && (
|
|
2161
|
+
if (v === 0 && (v = m.sortingFn(u, h, p.id)), v !== 0)
|
|
2162
|
+
return b && (v *= -1), m.invertSorting && (v *= -1), v;
|
|
2163
2163
|
}
|
|
2164
2164
|
return u.index - h.index;
|
|
2165
2165
|
}), c.forEach((u) => {
|
|
@@ -3250,16 +3250,16 @@ function Lf(i) {
|
|
|
3250
3250
|
return (
|
|
3251
3251
|
// cast: TypeScript cannot simplify Omit<P & WithStickySidesProps, keyof WithStickySidesProps>
|
|
3252
3252
|
// back to P after rest destructuring
|
|
3253
|
-
/* @__PURE__ */ g.jsx(i, { ...c, ref: f, children: ue.Children.map(a, (b,
|
|
3254
|
-
const
|
|
3255
|
-
if (!
|
|
3253
|
+
/* @__PURE__ */ g.jsx(i, { ...c, ref: f, children: ue.Children.map(a, (b, v) => {
|
|
3254
|
+
const x = y[v];
|
|
3255
|
+
if (!x || !ue.isValidElement(b)) return b;
|
|
3256
3256
|
const C = {
|
|
3257
3257
|
...m,
|
|
3258
|
-
[
|
|
3258
|
+
[x.stickySide]: `${x.position}px !important`
|
|
3259
3259
|
};
|
|
3260
3260
|
return ue.cloneElement(b, {
|
|
3261
|
-
className: `${u(C)} ${u(Jb(
|
|
3262
|
-
"data-testid": `sticky-cell-${
|
|
3261
|
+
className: `${u(C)} ${u(Jb(x.shadowSide, o))}`,
|
|
3262
|
+
"data-testid": `sticky-cell-${x.stickySide}-sticky`
|
|
3263
3263
|
});
|
|
3264
3264
|
}) })
|
|
3265
3265
|
);
|
|
@@ -3689,7 +3689,7 @@ function vv(i) {
|
|
|
3689
3689
|
});
|
|
3690
3690
|
}
|
|
3691
3691
|
function Ia(i) {
|
|
3692
|
-
var b,
|
|
3692
|
+
var b, v, x, C;
|
|
3693
3693
|
const e = pv(i), t = Ub(e.columns), [n, r] = G(), { state: s, initialState: o } = yv(e.state ?? {}), { enableRowSelection: l, setRowSelectionEnabled: a } = Yb({
|
|
3694
3694
|
state: s,
|
|
3695
3695
|
initialState: o
|
|
@@ -3709,7 +3709,7 @@ function Ia(i) {
|
|
|
3709
3709
|
getFilteredRowModel: Jy(),
|
|
3710
3710
|
...e.disableSorting ? { enableSorting: !1 } : { getSortedRowModel: ib() },
|
|
3711
3711
|
...e.disablePagination ? {} : { getPaginationRowModel: tb() },
|
|
3712
|
-
...(b = o.grouping) != null && b.length || (
|
|
3712
|
+
...(b = o.grouping) != null && b.length || (v = s.grouping) != null && v.length ? {
|
|
3713
3713
|
getGroupedRowModel: Zy(),
|
|
3714
3714
|
getExpandedRowModel: Tc()
|
|
3715
3715
|
} : {},
|
|
@@ -3735,7 +3735,7 @@ function Ia(i) {
|
|
|
3735
3735
|
hasFiltersApplied: (
|
|
3736
3736
|
// cast: TanStack types globalFilter as any; always string, the value passed to
|
|
3737
3737
|
// setGlobalFilter
|
|
3738
|
-
((
|
|
3738
|
+
((x = f.getState().globalFilter) == null ? void 0 : x.length) > 0 || (((C = f.getState().columnFilters) == null ? void 0 : C.length) ?? 0) > 0
|
|
3739
3739
|
),
|
|
3740
3740
|
filteredLength: f.getRowModel().rows.length,
|
|
3741
3741
|
columnsLength: t.length
|
|
@@ -4023,13 +4023,13 @@ var Ov = function i(e, t, n, r, s) {
|
|
|
4023
4023
|
}
|
|
4024
4024
|
if (!Array.isArray(e))
|
|
4025
4025
|
throw new Error("Cannot set a numeric property on an object");
|
|
4026
|
-
var y = e[d], b = i(y, t + 1, n, r, s),
|
|
4026
|
+
var y = e[d], b = i(y, t + 1, n, r, s), v = [].concat(e);
|
|
4027
4027
|
if (s && b === void 0) {
|
|
4028
|
-
if (
|
|
4028
|
+
if (v.splice(d, 1), v.length === 0)
|
|
4029
4029
|
return;
|
|
4030
4030
|
} else
|
|
4031
|
-
|
|
4032
|
-
return
|
|
4031
|
+
v[d] = b;
|
|
4032
|
+
return v;
|
|
4033
4033
|
}, gt = function(e, t, n, r) {
|
|
4034
4034
|
if (r === void 0 && (r = !1), e == null)
|
|
4035
4035
|
throw new Error("Cannot call setIn() with " + String(e) + " state");
|
|
@@ -4038,7 +4038,7 @@ var Ov = function i(e, t, n, r, s) {
|
|
|
4038
4038
|
return Ov(e, 0, Nf(t), n, r);
|
|
4039
4039
|
}, Jn = "FINAL_FORM/form-error", ln = "FINAL_FORM/array-error";
|
|
4040
4040
|
function Pc(i, e) {
|
|
4041
|
-
var t = i.errors, n = i.initialValues, r = i.lastSubmittedValues, s = i.submitErrors, o = i.submitFailed, l = i.submitSucceeded, a = i.submitting, c = i.values, u = e.active, h = e.blur, f = e.change, d = e.data, p = e.focus, m = e.modified, y = e.modifiedSinceLastSubmit, b = e.name,
|
|
4041
|
+
var t = i.errors, n = i.initialValues, r = i.lastSubmittedValues, s = i.submitErrors, o = i.submitFailed, l = i.submitSucceeded, a = i.submitting, c = i.values, u = e.active, h = e.blur, f = e.change, d = e.data, p = e.focus, m = e.modified, y = e.modifiedSinceLastSubmit, b = e.name, v = e.touched, x = e.validating, C = e.visited, S = ye(c, b), k = ye(t, b);
|
|
4042
4042
|
k && k[ln] && (k = k[ln]);
|
|
4043
4043
|
var E = s && ye(s, b), O = n && ye(n, b), R = e.isEqual(O, S), z = !!(r && !e.isEqual(ye(r, b), S)), F = !k && !E;
|
|
4044
4044
|
return {
|
|
@@ -4061,11 +4061,11 @@ function Pc(i, e) {
|
|
|
4061
4061
|
submitFailed: o,
|
|
4062
4062
|
submitSucceeded: l,
|
|
4063
4063
|
submitting: a,
|
|
4064
|
-
touched:
|
|
4064
|
+
touched: v,
|
|
4065
4065
|
valid: F,
|
|
4066
4066
|
value: S,
|
|
4067
4067
|
visited: C,
|
|
4068
|
-
validating:
|
|
4068
|
+
validating: x
|
|
4069
4069
|
};
|
|
4070
4070
|
}
|
|
4071
4071
|
var La = ["active", "data", "dirty", "dirtySinceLastSubmit", "error", "initial", "invalid", "length", "modified", "modifiedSinceLastSubmit", "pristine", "submitError", "submitFailed", "submitSucceeded", "submitting", "touched", "valid", "value", "visited", "validating"], jt = function(e, t) {
|
|
@@ -4196,7 +4196,7 @@ function Bv(i) {
|
|
|
4196
4196
|
}, b = function(w, M, I) {
|
|
4197
4197
|
var L = ye(w.formState.values, M), Y = I(L);
|
|
4198
4198
|
w.formState.values = gt(w.formState.values, M, Y) || {};
|
|
4199
|
-
},
|
|
4199
|
+
}, v = function(w, M, I) {
|
|
4200
4200
|
if (w.fields[M]) {
|
|
4201
4201
|
var L, Y;
|
|
4202
4202
|
w.fields = Se({}, w.fields, (L = {}, L[I] = Se({}, w.fields[M], {
|
|
@@ -4216,7 +4216,7 @@ function Bv(i) {
|
|
|
4216
4216
|
var J = ye(w.formState.values, M);
|
|
4217
4217
|
w.formState.values = gt(w.formState.values, M, void 0) || {}, w.formState.values = gt(w.formState.values, I, J), delete w.lastFormState;
|
|
4218
4218
|
}
|
|
4219
|
-
},
|
|
4219
|
+
}, x = function(w) {
|
|
4220
4220
|
return function() {
|
|
4221
4221
|
if (s) {
|
|
4222
4222
|
for (var M = {
|
|
@@ -4229,7 +4229,7 @@ function Bv(i) {
|
|
|
4229
4229
|
var J = s[w](L, M, {
|
|
4230
4230
|
changeValue: b,
|
|
4231
4231
|
getIn: ye,
|
|
4232
|
-
renameField:
|
|
4232
|
+
renameField: v,
|
|
4233
4233
|
resetFieldState: Z.resetFieldState,
|
|
4234
4234
|
setIn: gt,
|
|
4235
4235
|
shallowEqual: jt
|
|
@@ -4240,7 +4240,7 @@ function Bv(i) {
|
|
|
4240
4240
|
}
|
|
4241
4241
|
};
|
|
4242
4242
|
}, C = s ? Object.keys(s).reduce(function($, w) {
|
|
4243
|
-
return $[w] =
|
|
4243
|
+
return $[w] = x(w), $;
|
|
4244
4244
|
}, {}) : {}, S = function(w) {
|
|
4245
4245
|
var M = [];
|
|
4246
4246
|
if (l) {
|
|
@@ -4578,7 +4578,7 @@ function Bv(i) {
|
|
|
4578
4578
|
s = M, M ? (Object.keys(C).forEach(function(I) {
|
|
4579
4579
|
I in M || delete C[I];
|
|
4580
4580
|
}), Object.keys(M).forEach(function(I) {
|
|
4581
|
-
C[I] =
|
|
4581
|
+
C[I] = x(I);
|
|
4582
4582
|
})) : Object.keys(C).forEach(function(I) {
|
|
4583
4583
|
delete C[I];
|
|
4584
4584
|
});
|
|
@@ -4741,12 +4741,12 @@ function Uv(i) {
|
|
|
4741
4741
|
}, b = zv(function() {
|
|
4742
4742
|
var O = s || Bv(y);
|
|
4743
4743
|
return O.pauseValidation(), O;
|
|
4744
|
-
}),
|
|
4744
|
+
}), v = ke.useState(function() {
|
|
4745
4745
|
var O = {};
|
|
4746
4746
|
return b.subscribe(function(R) {
|
|
4747
4747
|
O = R;
|
|
4748
4748
|
}, f)(), O;
|
|
4749
|
-
}),
|
|
4749
|
+
}), x = v[0], C = v[1], S = $f(x);
|
|
4750
4750
|
ke.useEffect(function() {
|
|
4751
4751
|
b.isValidationPaused() && b.resumeValidation();
|
|
4752
4752
|
var O = [b.subscribe(function(R) {
|
|
@@ -4792,7 +4792,7 @@ function Uv(i) {
|
|
|
4792
4792
|
}),
|
|
4793
4793
|
handleSubmit: k
|
|
4794
4794
|
};
|
|
4795
|
-
return Hf(E,
|
|
4795
|
+
return Hf(E, x), /* @__PURE__ */ ke.createElement(zf.Provider, {
|
|
4796
4796
|
value: b
|
|
4797
4797
|
}, Vv(Se({}, m, {
|
|
4798
4798
|
__versions: Wv
|
|
@@ -4875,7 +4875,7 @@ var Qv = La.reduce(function(i, e) {
|
|
|
4875
4875
|
};
|
|
4876
4876
|
function Wf(i, e) {
|
|
4877
4877
|
e === void 0 && (e = {});
|
|
4878
|
-
var t = e, n = t.afterSubmit, r = t.allowNull, s = t.component, o = t.data, l = t.defaultValue, a = t.format, c = a === void 0 ? Oo : a, u = t.formatOnBlur, h = t.initialValue, f = t.multiple, d = t.parse, p = d === void 0 ? Jv : d, m = t.subscription, y = m === void 0 ? Qv : m, b = t.type,
|
|
4878
|
+
var t = e, n = t.afterSubmit, r = t.allowNull, s = t.component, o = t.data, l = t.defaultValue, a = t.format, c = a === void 0 ? Oo : a, u = t.formatOnBlur, h = t.initialValue, f = t.multiple, d = t.parse, p = d === void 0 ? Jv : d, m = t.subscription, y = m === void 0 ? Qv : m, b = t.type, v = t.validateFields, x = t.value, C = no("useField"), S = $f(e), k = function(H, X) {
|
|
4879
4879
|
return (
|
|
4880
4880
|
// avoid using `state` const in any closures created inside `register`
|
|
4881
4881
|
// because they would refer `state` from current execution context
|
|
@@ -4902,7 +4902,7 @@ function Wf(i, e) {
|
|
|
4902
4902
|
return (S.current.isEqual || Zv)(me, te);
|
|
4903
4903
|
},
|
|
4904
4904
|
silent: X,
|
|
4905
|
-
validateFields:
|
|
4905
|
+
validateFields: v
|
|
4906
4906
|
})
|
|
4907
4907
|
);
|
|
4908
4908
|
}, E = ke.useRef(!0), O = ke.useState(function() {
|
|
@@ -4938,14 +4938,14 @@ function Wf(i, e) {
|
|
|
4938
4938
|
name: i,
|
|
4939
4939
|
get value() {
|
|
4940
4940
|
var D = R.value;
|
|
4941
|
-
return u ? s === "input" && (D = Oo(D)) : D = c(D, i), D === null && !r && (D = ""), b === "checkbox" || b === "radio" ?
|
|
4941
|
+
return u ? s === "input" && (D = Oo(D)) : D = c(D, i), D === null && !r && (D = ""), b === "checkbox" || b === "radio" ? x : s === "select" && f ? D || [] : D;
|
|
4942
4942
|
},
|
|
4943
4943
|
get checked() {
|
|
4944
4944
|
var D = R.value;
|
|
4945
4945
|
if (b === "checkbox")
|
|
4946
|
-
return D = c(D, i),
|
|
4946
|
+
return D = c(D, i), x === void 0 ? !!D : !!(Array.isArray(D) && ~D.indexOf(x));
|
|
4947
4947
|
if (b === "radio")
|
|
4948
|
-
return c(D, i) ===
|
|
4948
|
+
return c(D, i) === x;
|
|
4949
4949
|
},
|
|
4950
4950
|
onBlur: Mo(function(D) {
|
|
4951
4951
|
if (R.blur(), u) {
|
|
@@ -4955,11 +4955,11 @@ function Wf(i, e) {
|
|
|
4955
4955
|
}),
|
|
4956
4956
|
onChange: Mo(function(D) {
|
|
4957
4957
|
if (process.env.NODE_ENV !== "production" && D && D.target) {
|
|
4958
|
-
var H = D.target.type, X = ~["checkbox", "radio", "select-multiple"].indexOf(H) && !b && s !== "select", fe = H === "select-multiple" ? R.value :
|
|
4958
|
+
var H = D.target.type, X = ~["checkbox", "radio", "select-multiple"].indexOf(H) && !b && s !== "select", fe = H === "select-multiple" ? R.value : x;
|
|
4959
4959
|
X && console.error('You must pass `type="' + (H === "select-multiple" ? "select" : H) + '"` prop to your Field(' + i + `) component.
|
|
4960
4960
|
` + ("Without it we don't know how to unpack your `value` prop - " + (Array.isArray(fe) ? "[" + fe + "]" : '"' + fe + '"') + "."));
|
|
4961
4961
|
}
|
|
4962
|
-
var me = D && D.target ? Xv(D, R.value,
|
|
4962
|
+
var me = D && D.target ? Xv(D, R.value, x, Kv) : D;
|
|
4963
4963
|
R.change(p(me, i));
|
|
4964
4964
|
}),
|
|
4965
4965
|
onFocus: Mo(function(D) {
|
|
@@ -5015,12 +5015,17 @@ function wt(i, e) {
|
|
|
5015
5015
|
return { input: s, meta: o };
|
|
5016
5016
|
}
|
|
5017
5017
|
function rx(i) {
|
|
5018
|
-
const { closeable: e, index: t, onRemove: n, readOnly: r, updateValue: s, value: o } = i, [, l] = G(), [a, c] = se(!1), [u, h] = se(o), f =
|
|
5019
|
-
|
|
5018
|
+
const { closeable: e, index: t, onRemove: n, readOnly: r, updateValue: s, value: o } = i, [, l] = G(), [a, c] = se(!1), [u, h] = se(o), f = {
|
|
5019
|
+
paddingTop: l.sizing.scale100,
|
|
5020
|
+
paddingRight: l.sizing.scale100,
|
|
5021
|
+
paddingBottom: l.sizing.scale100,
|
|
5022
|
+
paddingLeft: l.sizing.scale100
|
|
5020
5023
|
}, d = () => {
|
|
5024
|
+
h(o), c(!1);
|
|
5025
|
+
}, p = () => {
|
|
5021
5026
|
s(u, t), c(!1);
|
|
5022
|
-
},
|
|
5023
|
-
|
|
5027
|
+
}, m = (y) => {
|
|
5028
|
+
y.key === "Enter" && p();
|
|
5024
5029
|
};
|
|
5025
5030
|
return a && !r ? /* @__PURE__ */ g.jsx(
|
|
5026
5031
|
ul,
|
|
@@ -5031,19 +5036,9 @@ function rx(i) {
|
|
|
5031
5036
|
component: pe,
|
|
5032
5037
|
// Matches the size baseui's own small Tag action icon (e.g. the remove icon)
|
|
5033
5038
|
// renders at, so the confirm icon doesn't look oversized next to it.
|
|
5034
|
-
props: { name: "check", onMouseDown:
|
|
5039
|
+
props: { name: "check", onMouseDown: p, size: l.sizing.scale500 }
|
|
5035
5040
|
},
|
|
5036
|
-
|
|
5037
|
-
// Spacing between tags is handled by the container's `gap` (see StringTagInput) rather
|
|
5038
|
-
// than margin here, since Tag's own overrides always win margin conflicts when merged.
|
|
5039
|
-
Root: {
|
|
5040
|
-
style: {
|
|
5041
|
-
paddingTop: l.sizing.scale100,
|
|
5042
|
-
paddingRight: l.sizing.scale200,
|
|
5043
|
-
paddingBottom: l.sizing.scale100,
|
|
5044
|
-
paddingLeft: l.sizing.scale200
|
|
5045
|
-
}
|
|
5046
|
-
}
|
|
5041
|
+
Root: { style: f }
|
|
5047
5042
|
},
|
|
5048
5043
|
behavior: Vm.selection,
|
|
5049
5044
|
hierarchy: wc.secondary,
|
|
@@ -5052,9 +5047,9 @@ function rx(i) {
|
|
|
5052
5047
|
{
|
|
5053
5048
|
$adjoined: rf.none,
|
|
5054
5049
|
autoFocus: !0,
|
|
5055
|
-
onBlur:
|
|
5056
|
-
onChange: (
|
|
5057
|
-
onKeyDown:
|
|
5050
|
+
onBlur: d,
|
|
5051
|
+
onChange: (y) => h(y.target.value),
|
|
5052
|
+
onKeyDown: m,
|
|
5058
5053
|
size: u.length + 1,
|
|
5059
5054
|
$size: Ca.compact,
|
|
5060
5055
|
style: { padding: 0 },
|
|
@@ -5069,17 +5064,7 @@ function rx(i) {
|
|
|
5069
5064
|
onActionClick: n,
|
|
5070
5065
|
onClick: () => c(!0),
|
|
5071
5066
|
overrides: {
|
|
5072
|
-
|
|
5073
|
-
// Spacing between tags is handled by the container's `gap` (see StringTagInput) rather
|
|
5074
|
-
// than margin here, since Tag's own overrides always win margin conflicts when merged.
|
|
5075
|
-
Root: {
|
|
5076
|
-
style: {
|
|
5077
|
-
paddingTop: l.sizing.scale100,
|
|
5078
|
-
paddingRight: l.sizing.scale200,
|
|
5079
|
-
paddingBottom: l.sizing.scale100,
|
|
5080
|
-
paddingLeft: l.sizing.scale200
|
|
5081
|
-
}
|
|
5082
|
-
}
|
|
5067
|
+
Root: { style: f }
|
|
5083
5068
|
},
|
|
5084
5069
|
hierarchy: wc.primary,
|
|
5085
5070
|
children: o
|
|
@@ -5158,19 +5143,19 @@ function ox({
|
|
|
5158
5143
|
label: e,
|
|
5159
5144
|
format: f,
|
|
5160
5145
|
parse: d
|
|
5161
|
-
}), [y, b] = se(""),
|
|
5162
|
-
p.onChange([...
|
|
5163
|
-
}, C = (R) => p.onChange(
|
|
5164
|
-
const F = [...
|
|
5146
|
+
}), [y, b] = se(""), v = Array.isArray(p.value) ? p.value : [], x = (R) => {
|
|
5147
|
+
p.onChange([...v, R]), b("");
|
|
5148
|
+
}, C = (R) => p.onChange(v.filter((z, F) => F !== R)), S = (R, z) => {
|
|
5149
|
+
const F = [...v];
|
|
5165
5150
|
F[z] = R, p.onChange(F);
|
|
5166
5151
|
}, k = () => {
|
|
5167
5152
|
p.onChange([]), b("");
|
|
5168
5153
|
}, E = (R) => {
|
|
5169
5154
|
if (o) return;
|
|
5170
|
-
const z = R.key === "Enter" && y, F = R.key === "Backspace" &&
|
|
5171
|
-
z ? (R.preventDefault(),
|
|
5155
|
+
const z = R.key === "Enter" && y, F = R.key === "Backspace" && v.length > 0 && !y;
|
|
5156
|
+
z ? (R.preventDefault(), x(y)) : F && C(v.length - 1);
|
|
5172
5157
|
}, O = () => {
|
|
5173
|
-
p.onBlur(), y &&
|
|
5158
|
+
p.onBlur(), y && x(y);
|
|
5174
5159
|
};
|
|
5175
5160
|
return /* @__PURE__ */ g.jsx(
|
|
5176
5161
|
ht,
|
|
@@ -5188,7 +5173,8 @@ function ox({
|
|
|
5188
5173
|
id: i,
|
|
5189
5174
|
value: y,
|
|
5190
5175
|
onChange: (R) => b(R.currentTarget.value),
|
|
5191
|
-
|
|
5176
|
+
onBlur: O,
|
|
5177
|
+
placeholder: !l && !o && v.length === 0 ? a : "",
|
|
5192
5178
|
readOnly: o,
|
|
5193
5179
|
disabled: l,
|
|
5194
5180
|
overrides: {
|
|
@@ -5199,12 +5185,11 @@ function ox({
|
|
|
5199
5185
|
component: sx,
|
|
5200
5186
|
props: {
|
|
5201
5187
|
clear: k,
|
|
5202
|
-
onBlur: O,
|
|
5203
5188
|
onKeyDown: E,
|
|
5204
5189
|
readOnly: o,
|
|
5205
5190
|
removeValue: C,
|
|
5206
5191
|
updateValue: S,
|
|
5207
|
-
valueList:
|
|
5192
|
+
valueList: v
|
|
5208
5193
|
},
|
|
5209
5194
|
style: { width: "auto", flexGrow: 1, padding: 0 }
|
|
5210
5195
|
}
|
|
@@ -5329,9 +5314,9 @@ var Kf = function(e, t, n) {
|
|
|
5329
5314
|
source: t.fields[r + "[" + (y - 1) + "]" + h]
|
|
5330
5315
|
});
|
|
5331
5316
|
}
|
|
5332
|
-
var
|
|
5317
|
+
var v = r + "[" + o + "]" + h;
|
|
5333
5318
|
c({
|
|
5334
|
-
destKey:
|
|
5319
|
+
destKey: v,
|
|
5335
5320
|
source: d
|
|
5336
5321
|
});
|
|
5337
5322
|
}
|
|
@@ -5789,7 +5774,7 @@ const Dx = ({
|
|
|
5789
5774
|
rows: p,
|
|
5790
5775
|
maxLength: m
|
|
5791
5776
|
}) => {
|
|
5792
|
-
var
|
|
5777
|
+
var x;
|
|
5793
5778
|
const { input: y, meta: b } = wt(i, {
|
|
5794
5779
|
required: r,
|
|
5795
5780
|
validate: s,
|
|
@@ -5798,7 +5783,7 @@ const Dx = ({
|
|
|
5798
5783
|
label: e,
|
|
5799
5784
|
format: f,
|
|
5800
5785
|
parse: d
|
|
5801
|
-
}),
|
|
5786
|
+
}), v = ((x = y.value) == null ? void 0 : x.length) ?? 0;
|
|
5802
5787
|
return /* @__PURE__ */ g.jsx(
|
|
5803
5788
|
ht,
|
|
5804
5789
|
{
|
|
@@ -5808,7 +5793,7 @@ const Dx = ({
|
|
|
5808
5793
|
labelEndEnhancer: h,
|
|
5809
5794
|
caption: u,
|
|
5810
5795
|
error: b.touched && b.error ? b.error : void 0,
|
|
5811
|
-
counter: m ? { length:
|
|
5796
|
+
counter: m ? { length: v, maxLength: m } : void 0,
|
|
5812
5797
|
children: /* @__PURE__ */ g.jsx(
|
|
5813
5798
|
uf,
|
|
5814
5799
|
{
|
|
@@ -8268,11 +8253,11 @@ function bS(i) {
|
|
|
8268
8253
|
} else F == -3 ? c = O : F == -4 && (u = O);
|
|
8269
8254
|
return E;
|
|
8270
8255
|
}
|
|
8271
|
-
let
|
|
8256
|
+
let v = [], x = [];
|
|
8272
8257
|
for (; l.pos > 0; )
|
|
8273
|
-
h(i.start || 0, i.bufferStart || 0,
|
|
8274
|
-
let C = (e = i.length) !== null && e !== void 0 ? e :
|
|
8275
|
-
return new Oe(a[i.topID],
|
|
8258
|
+
h(i.start || 0, i.bufferStart || 0, v, x, -1, 0);
|
|
8259
|
+
let C = (e = i.length) !== null && e !== void 0 ? e : v.length ? x[0] + v[0].length : 0;
|
|
8260
|
+
return new Oe(a[i.topID], v.reverse(), x.reverse(), C);
|
|
8276
8261
|
}
|
|
8277
8262
|
const $c = /* @__PURE__ */ new WeakMap();
|
|
8278
8263
|
function os(i, e) {
|
|
@@ -8300,27 +8285,27 @@ function Ha(i, e, t, n, r, s, o, l, a) {
|
|
|
8300
8285
|
c * 1.5 / 8
|
|
8301
8286
|
/* Balance.BranchFactor */
|
|
8302
8287
|
), h = [], f = [];
|
|
8303
|
-
function d(p, m, y, b,
|
|
8304
|
-
for (let
|
|
8305
|
-
let C =
|
|
8306
|
-
for (
|
|
8307
|
-
let E = os(i, p[
|
|
8288
|
+
function d(p, m, y, b, v) {
|
|
8289
|
+
for (let x = y; x < b; ) {
|
|
8290
|
+
let C = x, S = m[x], k = os(i, p[x]);
|
|
8291
|
+
for (x++; x < b; x++) {
|
|
8292
|
+
let E = os(i, p[x]);
|
|
8308
8293
|
if (k + E >= u)
|
|
8309
8294
|
break;
|
|
8310
8295
|
k += E;
|
|
8311
8296
|
}
|
|
8312
|
-
if (
|
|
8297
|
+
if (x == C + 1) {
|
|
8313
8298
|
if (k > u) {
|
|
8314
8299
|
let E = p[C];
|
|
8315
|
-
d(E.children, E.positions, 0, E.children.length, m[C] +
|
|
8300
|
+
d(E.children, E.positions, 0, E.children.length, m[C] + v);
|
|
8316
8301
|
continue;
|
|
8317
8302
|
}
|
|
8318
8303
|
h.push(p[C]);
|
|
8319
8304
|
} else {
|
|
8320
|
-
let E = m[
|
|
8321
|
-
h.push(Ha(i, p, m, C,
|
|
8305
|
+
let E = m[x - 1] + p[x - 1].length - S;
|
|
8306
|
+
h.push(Ha(i, p, m, C, x, S, E, null, a));
|
|
8322
8307
|
}
|
|
8323
|
-
f.push(S +
|
|
8308
|
+
f.push(S + v - s);
|
|
8324
8309
|
}
|
|
8325
8310
|
}
|
|
8326
8311
|
return d(e, t, n, r, 0), (l || a)(h, f, o);
|
|
@@ -9896,13 +9881,13 @@ class FS {
|
|
|
9896
9881
|
if (f && f.overlay) {
|
|
9897
9882
|
let d = e.node.enter(f.overlay[0].from + l, 1), p = this.highlighters.filter((y) => !y.scope || y.scope(f.tree.type)), m = e.firstChild();
|
|
9898
9883
|
for (let y = 0, b = l; ; y++) {
|
|
9899
|
-
let
|
|
9884
|
+
let v = y < f.overlay.length ? f.overlay[y] : null, x = v ? v.from + l : a, C = Math.max(t, b), S = Math.min(n, x);
|
|
9900
9885
|
if (C < S && m)
|
|
9901
|
-
for (; e.from < S && (this.highlightRange(e, C, S, r, s), this.startSpan(Math.min(S, e.to), c), !(e.to >=
|
|
9886
|
+
for (; e.from < S && (this.highlightRange(e, C, S, r, s), this.startSpan(Math.min(S, e.to), c), !(e.to >= x || !e.nextSibling())); )
|
|
9902
9887
|
;
|
|
9903
|
-
if (!
|
|
9888
|
+
if (!v || x > n)
|
|
9904
9889
|
break;
|
|
9905
|
-
b =
|
|
9890
|
+
b = v.to + l, b > t && (this.highlightRange(d.cursor(), Math.max(t, v.from + l), Math.min(n, b), "", p), this.startSpan(Math.min(n, b), c));
|
|
9906
9891
|
}
|
|
9907
9892
|
m && e.parent();
|
|
9908
9893
|
} else if (e.firstChild()) {
|
|
@@ -13350,40 +13335,40 @@ function u1(i, e, t, n, r, s, o, l) {
|
|
|
13350
13335
|
u = u.assignedSlot || u.parentNode;
|
|
13351
13336
|
continue;
|
|
13352
13337
|
}
|
|
13353
|
-
let
|
|
13354
|
-
({ scaleX: p, scaleY: m } = Ud(u,
|
|
13355
|
-
left:
|
|
13356
|
-
right:
|
|
13357
|
-
top:
|
|
13358
|
-
bottom:
|
|
13338
|
+
let v = u.getBoundingClientRect();
|
|
13339
|
+
({ scaleX: p, scaleY: m } = Ud(u, v)), f = {
|
|
13340
|
+
left: v.left,
|
|
13341
|
+
right: v.left + u.clientWidth * p,
|
|
13342
|
+
top: v.top,
|
|
13343
|
+
bottom: v.top + u.clientHeight * m
|
|
13359
13344
|
};
|
|
13360
13345
|
}
|
|
13361
13346
|
let y = 0, b = 0;
|
|
13362
13347
|
if (r == "nearest")
|
|
13363
13348
|
e.top < f.top ? (b = e.top - (f.top + o), t > 0 && e.bottom > f.bottom + b && (b = e.bottom - f.bottom + o)) : e.bottom > f.bottom && (b = e.bottom - f.bottom + o, t < 0 && e.top - b < f.top && (b = e.top - (f.top + o)));
|
|
13364
13349
|
else {
|
|
13365
|
-
let
|
|
13366
|
-
b = (r == "center" &&
|
|
13350
|
+
let v = e.bottom - e.top, x = f.bottom - f.top;
|
|
13351
|
+
b = (r == "center" && v <= x ? e.top + v / 2 - x / 2 : r == "start" || r == "center" && t < 0 ? e.top - o : e.bottom - x + o) - f.top;
|
|
13367
13352
|
}
|
|
13368
13353
|
if (n == "nearest" ? e.left < f.left ? (y = e.left - (f.left + s), t > 0 && e.right > f.right + y && (y = e.right - f.right + s)) : e.right > f.right && (y = e.right - f.right + s, t < 0 && e.left < f.left + y && (y = e.left - (f.left + s))) : y = (n == "center" ? e.left + (e.right - e.left) / 2 - (f.right - f.left) / 2 : n == "start" == l ? e.left - s : e.right - (f.right - f.left) + s) - f.left, y || b)
|
|
13369
13354
|
if (d)
|
|
13370
13355
|
c.scrollBy(y, b);
|
|
13371
13356
|
else {
|
|
13372
|
-
let
|
|
13357
|
+
let v = 0, x = 0;
|
|
13373
13358
|
if (b) {
|
|
13374
13359
|
let C = u.scrollTop;
|
|
13375
|
-
u.scrollTop += b / m,
|
|
13360
|
+
u.scrollTop += b / m, x = (u.scrollTop - C) * m;
|
|
13376
13361
|
}
|
|
13377
13362
|
if (y) {
|
|
13378
13363
|
let C = u.scrollLeft;
|
|
13379
|
-
u.scrollLeft += y / p,
|
|
13364
|
+
u.scrollLeft += y / p, v = (u.scrollLeft - C) * p;
|
|
13380
13365
|
}
|
|
13381
13366
|
e = {
|
|
13382
|
-
left: e.left -
|
|
13383
|
-
top: e.top -
|
|
13384
|
-
right: e.right -
|
|
13385
|
-
bottom: e.bottom -
|
|
13386
|
-
},
|
|
13367
|
+
left: e.left - v,
|
|
13368
|
+
top: e.top - x,
|
|
13369
|
+
right: e.right - v,
|
|
13370
|
+
bottom: e.bottom - x
|
|
13371
|
+
}, v && Math.abs(v - y) < 1 && (n = "nearest"), x && Math.abs(x - b) < 1 && (r = "nearest");
|
|
13387
13372
|
}
|
|
13388
13373
|
if (d)
|
|
13389
13374
|
break;
|
|
@@ -15125,8 +15110,8 @@ class gu extends he {
|
|
|
15125
15110
|
S.breakAtStart ? k.breakAfter = 1 : S.content.length && k.merge(k.length, k.length, S.content[0], !1, S.openStart, 0) && (k.breakAfter = S.content[0].breakAfter, S.content.shift()), C.content.length && k.merge(0, 0, C.content[C.content.length - 1], !0, 0, C.openEnd) && C.content.pop(), f = C.content.concat(k).concat(S.content);
|
|
15126
15111
|
} else
|
|
15127
15112
|
({ content: f, breakAtStart: d, openStart: p, openEnd: m } = qn.build(this.view.state.doc, u, h, this.decorations, this.dynamicDecorationMap));
|
|
15128
|
-
let { i: y, off: b } = s.findPos(c, 1), { i:
|
|
15129
|
-
Zd(this,
|
|
15113
|
+
let { i: y, off: b } = s.findPos(c, 1), { i: v, off: x } = s.findPos(a, -1);
|
|
15114
|
+
Zd(this, v, x, y, b, f, d, p, m);
|
|
15130
15115
|
}
|
|
15131
15116
|
n && this.fixCompositionDOM(n);
|
|
15132
15117
|
}
|
|
@@ -15545,10 +15530,10 @@ function Xl(i, e, t) {
|
|
|
15545
15530
|
for (let y = 0; y < m.length; y++) {
|
|
15546
15531
|
let b = m[y];
|
|
15547
15532
|
r && _o(r, b) && (b = pu(mu(b, r.bottom), r.top));
|
|
15548
|
-
let
|
|
15549
|
-
if (
|
|
15533
|
+
let v = V1(e, b), x = z1(t, b);
|
|
15534
|
+
if (v == 0 && x == 0)
|
|
15550
15535
|
return p.nodeType == 3 ? yu(p, e, t) : Xl(p, e, t);
|
|
15551
|
-
(!n || o >
|
|
15536
|
+
(!n || o > x || o == x && s > v) && (n = p, r = b, s = v, o = x, l = v ? e < b.left ? y > 0 : y < m.length - 1 : !0), v == 0 ? t > b.bottom && (!u || u.bottom < b.bottom) ? (a = p, u = b) : t < b.top && (!h || h.top > b.top) && (c = p, h = b) : u && _o(u, b) ? u = mu(u, b.bottom) : h && _o(h, b) && (h = pu(h, b.top));
|
|
15552
15537
|
}
|
|
15553
15538
|
}
|
|
15554
15539
|
if (u && u.bottom >= t ? (n = a, r = u) : h && h.top <= t && (n = c, r = h), !n)
|
|
@@ -15602,31 +15587,31 @@ function Rg(i, e, t, n = -1) {
|
|
|
15602
15587
|
return i.viewport.to == i.state.doc.length ? i.state.doc.length : t ? null : bu(i, o, a, u, h);
|
|
15603
15588
|
let p = i.dom.ownerDocument, m = i.root.elementFromPoint ? i.root : p, y = m.elementFromPoint(u, h);
|
|
15604
15589
|
y && !i.contentDOM.contains(y) && (y = null), y || (u = Math.max(o.left + 1, Math.min(o.right - 1, u)), y = m.elementFromPoint(u, h), y && !i.contentDOM.contains(y) && (y = null));
|
|
15605
|
-
let b,
|
|
15590
|
+
let b, v = -1;
|
|
15606
15591
|
if (y && ((r = i.docView.nearest(y)) === null || r === void 0 ? void 0 : r.isEditable) != !1) {
|
|
15607
15592
|
if (p.caretPositionFromPoint) {
|
|
15608
15593
|
let C = p.caretPositionFromPoint(u, h);
|
|
15609
|
-
C && ({ offsetNode: b, offset:
|
|
15594
|
+
C && ({ offsetNode: b, offset: v } = C);
|
|
15610
15595
|
} else if (p.caretRangeFromPoint) {
|
|
15611
15596
|
let C = p.caretRangeFromPoint(u, h);
|
|
15612
|
-
C && ({ startContainer: b, startOffset:
|
|
15597
|
+
C && ({ startContainer: b, startOffset: v } = C);
|
|
15613
15598
|
}
|
|
15614
|
-
b && (!i.contentDOM.contains(b) || j.safari && $1(b,
|
|
15599
|
+
b && (!i.contentDOM.contains(b) || j.safari && $1(b, v, u) || j.chrome && _1(b, v, u)) && (b = void 0), b && (v = Math.min(Ut(b), v));
|
|
15615
15600
|
}
|
|
15616
15601
|
if (!b || !i.docView.dom.contains(b)) {
|
|
15617
15602
|
let C = Me.find(i.docView, d);
|
|
15618
15603
|
if (!C)
|
|
15619
15604
|
return f > a.top + a.height / 2 ? a.to : a.from;
|
|
15620
|
-
({ node: b, offset:
|
|
15605
|
+
({ node: b, offset: v } = Xl(C.dom, u, h));
|
|
15621
15606
|
}
|
|
15622
|
-
let
|
|
15623
|
-
if (!
|
|
15607
|
+
let x = i.docView.nearest(b);
|
|
15608
|
+
if (!x)
|
|
15624
15609
|
return null;
|
|
15625
|
-
if (
|
|
15626
|
-
let C =
|
|
15627
|
-
return e.y < C.top || e.y <= C.bottom && e.x <= (C.left + C.right) / 2 ?
|
|
15610
|
+
if (x.isWidget && ((s = x.dom) === null || s === void 0 ? void 0 : s.nodeType) == 1) {
|
|
15611
|
+
let C = x.dom.getBoundingClientRect();
|
|
15612
|
+
return e.y < C.top || e.y <= C.bottom && e.x <= (C.left + C.right) / 2 ? x.posAtStart : x.posAtEnd;
|
|
15628
15613
|
} else
|
|
15629
|
-
return
|
|
15614
|
+
return x.localPosFromDOM(b, v) + x.posAtStart;
|
|
15630
15615
|
}
|
|
15631
15616
|
function bu(i, e, t, n, r) {
|
|
15632
15617
|
let s = Math.round((n - e.left) * i.defaultCharacterWidth);
|
|
@@ -15970,10 +15955,10 @@ function X1(i, e, t) {
|
|
|
15970
15955
|
// ignored.
|
|
15971
15956
|
m.to >= h.from && m.from <= h.to)
|
|
15972
15957
|
return { range: m };
|
|
15973
|
-
let
|
|
15958
|
+
let v = r.changes({ from: b, to: y, insert: e.insert }), x = m.to - s.to;
|
|
15974
15959
|
return {
|
|
15975
|
-
changes:
|
|
15976
|
-
range: c ? T.range(Math.max(0, c.anchor +
|
|
15960
|
+
changes: v,
|
|
15961
|
+
range: c ? T.range(Math.max(0, c.anchor + x), Math.max(0, c.head + x)) : m.map(v)
|
|
15977
15962
|
};
|
|
15978
15963
|
});
|
|
15979
15964
|
} else
|
|
@@ -17073,12 +17058,12 @@ class Iu {
|
|
|
17073
17058
|
let b = this.pixelViewport.bottom > this.pixelViewport.top && this.pixelViewport.right > this.pixelViewport.left;
|
|
17074
17059
|
if (b != this.inView && (this.inView = b, b && (a = !0)), !this.inView && !this.scrollTarget && !Cw(e.dom))
|
|
17075
17060
|
return 0;
|
|
17076
|
-
let
|
|
17077
|
-
if ((this.contentDOMWidth !=
|
|
17061
|
+
let v = l.width;
|
|
17062
|
+
if ((this.contentDOMWidth != v || this.editorHeight != e.scrollDOM.clientHeight) && (this.contentDOMWidth = l.width, this.editorHeight = e.scrollDOM.clientHeight, c |= 16), a) {
|
|
17078
17063
|
let C = e.docView.measureVisibleLineHeights(this.viewport);
|
|
17079
|
-
if (r.mustRefreshForHeights(C) && (o = !0), o || r.lineWrapping && Math.abs(
|
|
17064
|
+
if (r.mustRefreshForHeights(C) && (o = !0), o || r.lineWrapping && Math.abs(v - this.contentDOMWidth) > r.charWidth) {
|
|
17080
17065
|
let { lineHeight: S, charWidth: k, textHeight: E } = e.docView.measureTextSize();
|
|
17081
|
-
o = S > 0 && r.refresh(s, S, k, E, Math.max(5,
|
|
17066
|
+
o = S > 0 && r.refresh(s, S, k, E, Math.max(5, v / k), C), o && (e.docView.minWidth = 0, c |= 16);
|
|
17082
17067
|
}
|
|
17083
17068
|
m > 0 && y > 0 ? u = Math.max(m, y) : m < 0 && y < 0 && (u = Math.min(m, y)), Pu();
|
|
17084
17069
|
for (let S of this.viewports) {
|
|
@@ -17087,8 +17072,8 @@ class Iu {
|
|
|
17087
17072
|
}
|
|
17088
17073
|
wn && (c |= 2);
|
|
17089
17074
|
}
|
|
17090
|
-
let
|
|
17091
|
-
return
|
|
17075
|
+
let x = !this.viewportIsAppropriate(this.viewport, u) || this.scrollTarget && (this.scrollTarget.range.head < this.viewport.from || this.scrollTarget.range.head > this.viewport.to);
|
|
17076
|
+
return x && (c & 2 && (c |= this.updateScaler()), this.viewport = this.getViewport(u, this.scrollTarget), c |= this.updateForViewport()), (c & 2 || x) && this.updateViewportLines(), (this.lineGaps.length || this.viewport.to - this.viewport.from > 4e3) && this.updateLineGaps(this.ensureLineGaps(o ? [] : this.lineGaps, e)), c |= this.computeVisibleRanges(), this.mustEnforceCursorAssoc && (this.mustEnforceCursorAssoc = !1, e.docView.enforceCursorAssoc()), c;
|
|
17092
17077
|
}
|
|
17093
17078
|
get visibleTop() {
|
|
17094
17079
|
return this.scaler.fromDOM(this.pixelViewport.top);
|
|
@@ -17156,14 +17141,14 @@ class Iu {
|
|
|
17156
17141
|
a(u, b - 10, f, d), a(b + 10, h, f, d);
|
|
17157
17142
|
return;
|
|
17158
17143
|
}
|
|
17159
|
-
let y = Ew(e, (b) => b.from >= f.from && b.to <= f.to && Math.abs(b.from - u) < s && Math.abs(b.to - h) < s && !m.some((
|
|
17144
|
+
let y = Ew(e, (b) => b.from >= f.from && b.to <= f.to && Math.abs(b.from - u) < s && Math.abs(b.to - h) < s && !m.some((v) => b.from < v && b.to > v));
|
|
17160
17145
|
if (!y) {
|
|
17161
|
-
if (h < f.to && t && n && t.visibleRanges.some((
|
|
17162
|
-
let
|
|
17163
|
-
|
|
17146
|
+
if (h < f.to && t && n && t.visibleRanges.some((x) => x.from <= h && x.to >= h)) {
|
|
17147
|
+
let x = t.moveToLineBoundary(T.cursor(h), !1, !0).head;
|
|
17148
|
+
x > u && (h = x);
|
|
17164
17149
|
}
|
|
17165
|
-
let b = this.gapSize(f, u, h, d),
|
|
17166
|
-
y = new Go(u, h, b,
|
|
17150
|
+
let b = this.gapSize(f, u, h, d), v = n || b < 2e6 ? b : 2e6;
|
|
17151
|
+
y = new Go(u, h, b, v);
|
|
17167
17152
|
}
|
|
17168
17153
|
l.push(y);
|
|
17169
17154
|
}, c = (u) => {
|
|
@@ -17176,8 +17161,8 @@ class Iu {
|
|
|
17176
17161
|
if (n) {
|
|
17177
17162
|
let m = r / this.heightOracle.lineLength * this.heightOracle.lineHeight, y, b;
|
|
17178
17163
|
if (f != null) {
|
|
17179
|
-
let
|
|
17180
|
-
y =
|
|
17164
|
+
let v = Yr(h, f), x = ((this.visibleBottom - this.visibleTop) / 2 + m) / u.height;
|
|
17165
|
+
y = v - x, b = v + x;
|
|
17181
17166
|
} else
|
|
17182
17167
|
y = (this.visibleTop - u.top - m) / u.height, b = (this.visibleBottom - u.top + m) / u.height;
|
|
17183
17168
|
d = Kr(h, y), p = Kr(h, b);
|
|
@@ -17186,12 +17171,12 @@ class Iu {
|
|
|
17186
17171
|
if (m > 2e6)
|
|
17187
17172
|
for (let k of e)
|
|
17188
17173
|
k.from >= u.from && k.from < u.to && k.size != k.displaySize && k.from * this.heightOracle.charWidth + b < this.pixelViewport.left && (b = k.size - k.displaySize);
|
|
17189
|
-
let
|
|
17174
|
+
let v = this.pixelViewport.left + b, x = this.pixelViewport.right + b, C, S;
|
|
17190
17175
|
if (f != null) {
|
|
17191
|
-
let k = Yr(h, f), E = ((
|
|
17176
|
+
let k = Yr(h, f), E = ((x - v) / 2 + y) / m;
|
|
17192
17177
|
C = k - E, S = k + E;
|
|
17193
17178
|
} else
|
|
17194
|
-
C = (
|
|
17179
|
+
C = (v - y) / m, S = (x + y) / m;
|
|
17195
17180
|
d = Kr(h, C), p = Kr(h, S);
|
|
17196
17181
|
}
|
|
17197
17182
|
d > u.from && a(u.from, d, u, h), p < u.to && a(p, u.to, u, h);
|
|
@@ -18843,12 +18828,12 @@ function Vw(i, e = Lw) {
|
|
|
18843
18828
|
var h, f;
|
|
18844
18829
|
let d = t[o] || (t[o] = /* @__PURE__ */ Object.create(null)), p = l.split(/ (?!$)/).map((b) => Fw(b, e));
|
|
18845
18830
|
for (let b = 1; b < p.length; b++) {
|
|
18846
|
-
let
|
|
18847
|
-
r(
|
|
18831
|
+
let v = p.slice(0, b).join(" ");
|
|
18832
|
+
r(v, !0), d[v] || (d[v] = {
|
|
18848
18833
|
preventDefault: !0,
|
|
18849
18834
|
stopPropagation: !1,
|
|
18850
|
-
run: [(
|
|
18851
|
-
let C = gi = { view:
|
|
18835
|
+
run: [(x) => {
|
|
18836
|
+
let C = gi = { view: x, prefix: v, scope: o };
|
|
18852
18837
|
return setTimeout(() => {
|
|
18853
18838
|
gi == C && (gi = null);
|
|
18854
18839
|
}, jw), !0;
|
|
@@ -18954,21 +18939,21 @@ function zw(i, e, t) {
|
|
|
18954
18939
|
return [];
|
|
18955
18940
|
let n = Math.max(t.from, i.viewport.from), r = Math.min(t.to, i.viewport.to), s = i.textDirection == ve.LTR, o = i.contentDOM, l = o.getBoundingClientRect(), a = Gg(i), c = o.querySelector(".cm-line"), u = c && window.getComputedStyle(c), h = l.left + (u ? parseInt(u.paddingLeft) + Math.min(0, parseInt(u.textIndent)) : 0), f = l.right - (u ? parseInt(u.paddingRight) : 0), d = Ql(i, n, 1), p = Ql(i, r, -1), m = d.type == Qe.Text ? d : null, y = p.type == Qe.Text ? p : null;
|
|
18956
18941
|
if (m && (i.lineWrapping || d.widgetLineBreaks) && (m = zu(i, n, 1, m)), y && (i.lineWrapping || p.widgetLineBreaks) && (y = zu(i, r, -1, y)), m && y && m.from == y.from && m.to == y.to)
|
|
18957
|
-
return x(
|
|
18942
|
+
return v(x(t.from, t.to, m));
|
|
18958
18943
|
{
|
|
18959
|
-
let S = m ?
|
|
18960
|
-
return (m || d).to < (y || p).from - (m && y ? 1 : 0) || d.widgetLineBreaks > 1 && S.bottom + i.defaultLineHeight / 2 < k.top ? E.push(b(h, S.bottom, f, k.top)) : S.bottom < k.top && i.elementAtHeight((S.bottom + k.top) / 2).type == Qe.Text && (S.bottom = k.top = (S.bottom + k.top) / 2),
|
|
18944
|
+
let S = m ? x(t.from, null, m) : C(d, !1), k = y ? x(null, t.to, y) : C(p, !0), E = [];
|
|
18945
|
+
return (m || d).to < (y || p).from - (m && y ? 1 : 0) || d.widgetLineBreaks > 1 && S.bottom + i.defaultLineHeight / 2 < k.top ? E.push(b(h, S.bottom, f, k.top)) : S.bottom < k.top && i.elementAtHeight((S.bottom + k.top) / 2).type == Qe.Text && (S.bottom = k.top = (S.bottom + k.top) / 2), v(S).concat(E).concat(v(k));
|
|
18961
18946
|
}
|
|
18962
18947
|
function b(S, k, E, O) {
|
|
18963
18948
|
return new Rr(e, S - a.left, k - a.top, E - S, O - k);
|
|
18964
18949
|
}
|
|
18965
|
-
function
|
|
18950
|
+
function v({ top: S, bottom: k, horizontal: E }) {
|
|
18966
18951
|
let O = [];
|
|
18967
18952
|
for (let R = 0; R < E.length; R += 2)
|
|
18968
18953
|
O.push(b(E[R], S, E[R + 1], k));
|
|
18969
18954
|
return O;
|
|
18970
18955
|
}
|
|
18971
|
-
function
|
|
18956
|
+
function x(S, k, E) {
|
|
18972
18957
|
let O = 1e9, R = -1e9, z = [];
|
|
18973
18958
|
function F(D, H, X, fe, me) {
|
|
18974
18959
|
let te = i.coordsAtPos(D, D == E.to ? -2 : 2), Z = i.coordsAtPos(X, X == E.from ? 2 : -2);
|
|
@@ -19680,7 +19665,7 @@ const qo = /* @__PURE__ */ V.define({
|
|
|
19680
19665
|
u.style.top = Jr;
|
|
19681
19666
|
continue;
|
|
19682
19667
|
}
|
|
19683
|
-
let d = a.arrow ? c.dom.querySelector(".cm-tooltip-arrow") : null, p = d ? 7 : 0, m = f.right - f.left, y = (e = Wu.get(c)) !== null && e !== void 0 ? e : f.bottom - f.top, b = c.offset || xC,
|
|
19668
|
+
let d = a.arrow ? c.dom.querySelector(".cm-tooltip-arrow") : null, p = d ? 7 : 0, m = f.right - f.left, y = (e = Wu.get(c)) !== null && e !== void 0 ? e : f.bottom - f.top, b = c.offset || xC, v = this.view.textDirection == ve.LTR, x = f.width > n.right - n.left ? v ? n.left : n.right - f.width : v ? Math.max(n.left, Math.min(h.left - (d ? 14 : 0) + b.x, n.right - m)) : Math.min(Math.max(n.left, h.left - m + (d ? 14 : 0) - b.x), n.right - m), C = this.above[l];
|
|
19684
19669
|
!a.strictSide && (C ? h.top - y - p - b.y < n.top : h.bottom + y + p + b.y > n.bottom) && C == n.bottom - h.bottom > h.top - n.top && (C = this.above[l] = !C);
|
|
19685
19670
|
let S = (C ? h.top - n.top : n.bottom - h.bottom) - p;
|
|
19686
19671
|
if (S < y && c.resize !== !1) {
|
|
@@ -19690,15 +19675,15 @@ const qo = /* @__PURE__ */ V.define({
|
|
|
19690
19675
|
}
|
|
19691
19676
|
Wu.set(c, y), u.style.height = (y = S) / s + "px";
|
|
19692
19677
|
} else u.style.height && (u.style.height = "");
|
|
19693
|
-
let k = C ? h.top - y - p - b.y : h.bottom + p + b.y, E =
|
|
19678
|
+
let k = C ? h.top - y - p - b.y : h.bottom + p + b.y, E = x + m;
|
|
19694
19679
|
if (c.overlap !== !0)
|
|
19695
19680
|
for (let O of o)
|
|
19696
|
-
O.left < E && O.right >
|
|
19697
|
-
if (this.position == "absolute" ? (u.style.top = (k - i.parent.top) / s + "px", Uu(u, (
|
|
19698
|
-
let O = h.left + (
|
|
19681
|
+
O.left < E && O.right > x && O.top < k + y && O.bottom > k && (k = C ? O.top - y - 2 - p : O.bottom + p + 2);
|
|
19682
|
+
if (this.position == "absolute" ? (u.style.top = (k - i.parent.top) / s + "px", Uu(u, (x - i.parent.left) / r)) : (u.style.top = k / s + "px", Uu(u, x / r)), d) {
|
|
19683
|
+
let O = h.left + (v ? b.x : -b.x) - (x + 14 - 7);
|
|
19699
19684
|
d.style.left = O / r + "px";
|
|
19700
19685
|
}
|
|
19701
|
-
c.overlap !== !0 && o.push({ left:
|
|
19686
|
+
c.overlap !== !0 && o.push({ left: x, top: k, right: E, bottom: k + y }), u.classList.toggle("cm-tooltip-above", C), u.classList.toggle("cm-tooltip-below", !C), c.positioned && c.positioned(i.space);
|
|
19702
19687
|
}
|
|
19703
19688
|
}
|
|
19704
19689
|
maybeMeasure() {
|
|
@@ -23431,31 +23416,31 @@ class RA {
|
|
|
23431
23416
|
return null;
|
|
23432
23417
|
let { chars: t, folded: n, any: r, precise: s, byWord: o } = this;
|
|
23433
23418
|
if (t.length == 1) {
|
|
23434
|
-
let
|
|
23435
|
-
if (
|
|
23419
|
+
let v = Ze(e, 0), x = zt(v), C = x == e.length ? 0 : -100;
|
|
23420
|
+
if (v != t[0]) if (v == n[0])
|
|
23436
23421
|
C += -200;
|
|
23437
23422
|
else
|
|
23438
23423
|
return null;
|
|
23439
|
-
return this.ret(C, [0,
|
|
23424
|
+
return this.ret(C, [0, x]);
|
|
23440
23425
|
}
|
|
23441
23426
|
let l = e.indexOf(this.pattern);
|
|
23442
23427
|
if (l == 0)
|
|
23443
23428
|
return this.ret(e.length == this.pattern.length ? 0 : -100, [0, this.pattern.length]);
|
|
23444
23429
|
let a = t.length, c = 0;
|
|
23445
23430
|
if (l < 0) {
|
|
23446
|
-
for (let
|
|
23447
|
-
let C = Ze(e,
|
|
23448
|
-
(C == t[c] || C == n[c]) && (r[c++] =
|
|
23431
|
+
for (let v = 0, x = Math.min(e.length, 200); v < x && c < a; ) {
|
|
23432
|
+
let C = Ze(e, v);
|
|
23433
|
+
(C == t[c] || C == n[c]) && (r[c++] = v), v += zt(C);
|
|
23449
23434
|
}
|
|
23450
23435
|
if (c < a)
|
|
23451
23436
|
return null;
|
|
23452
23437
|
}
|
|
23453
23438
|
let u = 0, h = 0, f = !1, d = 0, p = -1, m = -1, y = /[a-z]/.test(e), b = !0;
|
|
23454
|
-
for (let
|
|
23455
|
-
let S = Ze(e,
|
|
23456
|
-
l < 0 && (u < a && S == t[u] && (s[u++] =
|
|
23439
|
+
for (let v = 0, x = Math.min(e.length, 200), C = 0; v < x && h < a; ) {
|
|
23440
|
+
let S = Ze(e, v);
|
|
23441
|
+
l < 0 && (u < a && S == t[u] && (s[u++] = v), d < a && (S == t[d] || S == n[d] ? (d == 0 && (p = v), m = v + 1, d++) : d = 0));
|
|
23457
23442
|
let k, E = S < 255 ? S >= 48 && S <= 57 || S >= 97 && S <= 122 ? 2 : S >= 65 && S <= 90 ? 1 : 0 : (k = Ga(S)) != k.toLowerCase() ? 1 : k != k.toUpperCase() ? 2 : 0;
|
|
23458
|
-
(!
|
|
23443
|
+
(!v || E == 1 && y || C == 0 && E != 0) && (t[h] == S || n[h] == S && (f = !0) ? o[h++] = v : o.length && (b = !1)), C = E, v += zt(S);
|
|
23459
23444
|
}
|
|
23460
23445
|
return h == a && o[0] == 0 && b ? this.result(-100 + (f ? -200 : 0), o, e) : d == a && p == 0 ? this.ret(-200 - e.length + (m == e.length ? 0 : -100), [0, m]) : l > -1 ? this.ret(-700 - e.length, [l, l + this.pattern.length]) : d == a ? this.ret(-900 - e.length, [p, m]) : h == a ? this.result(-100 + (f ? -200 : 0) + -700 + (b ? 0 : -1100), o, e) : t.length == 2 ? null : this.result((r[0] ? -700 : 0) + -200 + -1100, r, e);
|
|
23461
23446
|
}
|
|
@@ -23524,8 +23509,8 @@ function EA(i, e, t, n, r, s) {
|
|
|
23524
23509
|
(o ? e.right : r.right - e.left) - 30
|
|
23525
23510
|
/* Info.Margin */
|
|
23526
23511
|
);
|
|
23527
|
-
let
|
|
23528
|
-
|
|
23512
|
+
let v = r.bottom - e.bottom;
|
|
23513
|
+
v >= m || v > e.top ? u = t.bottom - e.top : (c = "bottom", u = e.bottom - t.top);
|
|
23529
23514
|
}
|
|
23530
23515
|
let y = (e.bottom - e.top) / s.offsetHeight, b = (e.right - e.left) / s.offsetWidth;
|
|
23531
23516
|
return {
|
|
@@ -23740,8 +23725,8 @@ function DA(i, e) {
|
|
|
23740
23725
|
if (d = p.match(m.label)) {
|
|
23741
23726
|
let y = m.displayLabel ? h ? h(m, d.matched) : [] : d.matched, b = d.score + (m.boost || 0);
|
|
23742
23727
|
if (s(new xh(m, u.source, y, b)), typeof m.section == "object" && m.section.rank === "dynamic") {
|
|
23743
|
-
let { name:
|
|
23744
|
-
r || (r = /* @__PURE__ */ Object.create(null)), r[
|
|
23728
|
+
let { name: v } = m.section;
|
|
23729
|
+
r || (r = /* @__PURE__ */ Object.create(null)), r[v] = Math.max(b, r[v] || -1e9);
|
|
23745
23730
|
}
|
|
23746
23731
|
}
|
|
23747
23732
|
}
|
|
@@ -24477,26 +24462,26 @@ class Li {
|
|
|
24477
24462
|
break;
|
|
24478
24463
|
let m, y;
|
|
24479
24464
|
if (l.length)
|
|
24480
|
-
m = a, y = l.reduce((
|
|
24465
|
+
m = a, y = l.reduce((x, C) => Math.min(x, C.to), p && p.from > m ? p.from : 1e8);
|
|
24481
24466
|
else {
|
|
24482
24467
|
if (m = p.from, m > h)
|
|
24483
24468
|
break;
|
|
24484
24469
|
y = p.to, l.push(p), d++;
|
|
24485
24470
|
}
|
|
24486
24471
|
for (; d < s.length; ) {
|
|
24487
|
-
let
|
|
24488
|
-
if (
|
|
24489
|
-
l.push(
|
|
24472
|
+
let x = s[d];
|
|
24473
|
+
if (x.from == m && (x.to > x.from || x.to == m))
|
|
24474
|
+
l.push(x), d++, y = Math.min(x.to, y);
|
|
24490
24475
|
else {
|
|
24491
|
-
y = Math.min(
|
|
24476
|
+
y = Math.min(x.from, y);
|
|
24492
24477
|
break;
|
|
24493
24478
|
}
|
|
24494
24479
|
}
|
|
24495
24480
|
y = Math.min(y, h);
|
|
24496
24481
|
let b = !1;
|
|
24497
|
-
if (l.some((
|
|
24498
|
-
let
|
|
24499
|
-
|
|
24482
|
+
if (l.some((x) => x.from == m && (x.to == y || y == h)) && (b = m == y, !b && y - m < 10)) {
|
|
24483
|
+
let x = m - (u + c.value.length);
|
|
24484
|
+
x > 0 && (c.next(x), u = m);
|
|
24500
24485
|
for (let C = m; ; ) {
|
|
24501
24486
|
if (C >= y) {
|
|
24502
24487
|
b = !0;
|
|
@@ -24507,24 +24492,24 @@ class Li {
|
|
|
24507
24492
|
C = u + c.value.length, u += c.value.length, c.next();
|
|
24508
24493
|
}
|
|
24509
24494
|
}
|
|
24510
|
-
let
|
|
24495
|
+
let v = vE(l);
|
|
24511
24496
|
if (b)
|
|
24512
24497
|
o.add(m, m, W.widget({
|
|
24513
|
-
widget: new pE(
|
|
24498
|
+
widget: new pE(v),
|
|
24514
24499
|
diagnostics: l.slice()
|
|
24515
24500
|
}));
|
|
24516
24501
|
else {
|
|
24517
|
-
let
|
|
24502
|
+
let x = l.reduce((C, S) => S.markClass ? C + " " + S.markClass : C, "");
|
|
24518
24503
|
o.add(m, y, W.mark({
|
|
24519
|
-
class: "cm-lintRange cm-lintRange-" +
|
|
24504
|
+
class: "cm-lintRange cm-lintRange-" + v + x,
|
|
24520
24505
|
diagnostics: l.slice(),
|
|
24521
24506
|
inclusiveEnd: l.some((C) => C.to > y)
|
|
24522
24507
|
}));
|
|
24523
24508
|
}
|
|
24524
24509
|
if (a = y, a == h)
|
|
24525
24510
|
break;
|
|
24526
|
-
for (let
|
|
24527
|
-
l[
|
|
24511
|
+
for (let x = 0; x < l.length; x++)
|
|
24512
|
+
l[x].to <= a && l.splice(x--, 1);
|
|
24528
24513
|
}
|
|
24529
24514
|
let f = o.finish();
|
|
24530
24515
|
return new Li(f, t, Rn(f));
|
|
@@ -25172,8 +25157,8 @@ function VE(i) {
|
|
|
25172
25157
|
maxWidth: m = null,
|
|
25173
25158
|
placeholder: y = "",
|
|
25174
25159
|
editable: b = !0,
|
|
25175
|
-
readOnly:
|
|
25176
|
-
indentWithTab:
|
|
25160
|
+
readOnly: v = !1,
|
|
25161
|
+
indentWithTab: x = !0,
|
|
25177
25162
|
basicSetup: C = !0,
|
|
25178
25163
|
root: S,
|
|
25179
25164
|
initialState: k
|
|
@@ -25211,9 +25196,9 @@ function VE(i) {
|
|
|
25211
25196
|
}), fe = IE({
|
|
25212
25197
|
theme: c,
|
|
25213
25198
|
editable: b,
|
|
25214
|
-
readOnly:
|
|
25199
|
+
readOnly: v,
|
|
25215
25200
|
placeholder: y,
|
|
25216
|
-
indentWithTab:
|
|
25201
|
+
indentWithTab: x,
|
|
25217
25202
|
basicSetup: C
|
|
25218
25203
|
}), me = [X, H, ...fe];
|
|
25219
25204
|
return o && typeof o == "function" && me.push(B.updateListener.of(o)), me = me.concat(l), s0(() => {
|
|
@@ -25245,7 +25230,7 @@ function VE(i) {
|
|
|
25245
25230
|
R && R.dispatch({
|
|
25246
25231
|
effects: Q.reconfigure.of(me)
|
|
25247
25232
|
});
|
|
25248
|
-
}, [c, l, u, h, f, d, p, m, y, b,
|
|
25233
|
+
}, [c, l, u, h, f, d, p, m, y, b, v, x, C, n, o]), Be(() => {
|
|
25249
25234
|
if (e !== void 0) {
|
|
25250
25235
|
var te = R ? R.state.doc.toString() : "";
|
|
25251
25236
|
if (R && e !== te) {
|
|
@@ -25289,8 +25274,8 @@ var zE = ["className", "value", "selection", "extensions", "onChange", "onStatis
|
|
|
25289
25274
|
width: m,
|
|
25290
25275
|
minWidth: y,
|
|
25291
25276
|
maxWidth: b,
|
|
25292
|
-
basicSetup:
|
|
25293
|
-
placeholder:
|
|
25277
|
+
basicSetup: v,
|
|
25278
|
+
placeholder: x,
|
|
25294
25279
|
indentWithTab: C,
|
|
25295
25280
|
editable: S,
|
|
25296
25281
|
readOnly: k,
|
|
@@ -25312,8 +25297,8 @@ var zE = ["className", "value", "selection", "extensions", "onChange", "onStatis
|
|
|
25312
25297
|
width: m,
|
|
25313
25298
|
minWidth: y,
|
|
25314
25299
|
maxWidth: b,
|
|
25315
|
-
basicSetup:
|
|
25316
|
-
placeholder:
|
|
25300
|
+
basicSetup: v,
|
|
25301
|
+
placeholder: x,
|
|
25317
25302
|
indentWithTab: C,
|
|
25318
25303
|
editable: S,
|
|
25319
25304
|
readOnly: k,
|
|
@@ -25727,7 +25712,7 @@ function Sm({
|
|
|
25727
25712
|
), [p, m] = Xi(
|
|
25728
25713
|
`${i}.columnVisibility`,
|
|
25729
25714
|
(t == null ? void 0 : t.columnVisibility) ?? hi.columnVisibility
|
|
25730
|
-
), [y, b] = se(0), [
|
|
25715
|
+
), [y, b] = se(0), [v, x] = se({}), [C, S] = se(
|
|
25731
25716
|
(t == null ? void 0 : t.rowSelectionEnabled) ?? hi.rowSelectionEnabled
|
|
25732
25717
|
), [k, E] = se(
|
|
25733
25718
|
(t == null ? void 0 : t.grouping) ?? hi.grouping
|
|
@@ -25751,8 +25736,8 @@ function Sm({
|
|
|
25751
25736
|
setColumnOrder: d,
|
|
25752
25737
|
columnVisibility: p,
|
|
25753
25738
|
setColumnVisibility: m,
|
|
25754
|
-
rowSelection:
|
|
25755
|
-
setRowSelection:
|
|
25739
|
+
rowSelection: v,
|
|
25740
|
+
setRowSelection: x,
|
|
25756
25741
|
rowSelectionEnabled: C,
|
|
25757
25742
|
setRowSelectionEnabled: S,
|
|
25758
25743
|
grouping: k,
|
|
@@ -26374,7 +26359,7 @@ function pT({
|
|
|
26374
26359
|
] });
|
|
26375
26360
|
}
|
|
26376
26361
|
function mT({ phases: i = Na }) {
|
|
26377
|
-
const [, e] = G(), { phase: t, entity: n, entityId: r, projectId: s, entityTab: o } = ft("detail"), l = Ei(), a = i[t].entities.find((
|
|
26362
|
+
const [, e] = G(), { phase: t, entity: n, entityId: r, projectId: s, entityTab: o } = ft("detail"), l = Ei(), a = i[t].entities.find((v) => v.id === n), c = br(), { data: u, isLoading: h, error: f } = yr({
|
|
26378
26363
|
queryName: `Get${gn((a == null ? void 0 : a.service) ?? "")}`,
|
|
26379
26364
|
serviceOptions: {
|
|
26380
26365
|
namespace: s,
|
|
@@ -26384,18 +26369,18 @@ function mT({ phases: i = Na }) {
|
|
|
26384
26369
|
enabled: !!(a != null && a.service) && !!r
|
|
26385
26370
|
}
|
|
26386
26371
|
}), d = ue.useCallback(
|
|
26387
|
-
(
|
|
26388
|
-
l(`/${s}/${t}/${n}/${r}/${
|
|
26372
|
+
(v, x) => {
|
|
26373
|
+
l(`/${s}/${t}/${n}/${r}/${v}`, x);
|
|
26389
26374
|
},
|
|
26390
26375
|
[l, s, t, n, r]
|
|
26391
26376
|
), p = () => {
|
|
26392
26377
|
l(`/${s}/${t}/${n}`);
|
|
26393
|
-
}, m = ((a == null ? void 0 : a.views) ?? []).find((
|
|
26378
|
+
}, m = ((a == null ? void 0 : a.views) ?? []).find((v) => v.type === "detail") ?? void 0;
|
|
26394
26379
|
if (ue.useEffect(() => {
|
|
26395
26380
|
var C;
|
|
26396
26381
|
if (f || h || !r || !((C = m == null ? void 0 : m.pages) != null && C.length)) return;
|
|
26397
|
-
const
|
|
26398
|
-
o ?
|
|
26382
|
+
const v = m.pages.map((S) => S.id), x = v[0];
|
|
26383
|
+
o ? v.includes(o) || d(x, { replace: !0 }) : d(x, { replace: !0 });
|
|
26399
26384
|
}, [o, m, h, f, d]), f)
|
|
26400
26385
|
return /* @__PURE__ */ g.jsx(
|
|
26401
26386
|
ii,
|
|
@@ -26430,10 +26415,10 @@ function mT({ phases: i = Na }) {
|
|
|
26430
26415
|
children: /* @__PURE__ */ g.jsx(
|
|
26431
26416
|
uT,
|
|
26432
26417
|
{
|
|
26433
|
-
tabs: b.pages.map((
|
|
26434
|
-
id:
|
|
26435
|
-
label:
|
|
26436
|
-
content: /* @__PURE__ */ g.jsx(lT, { page:
|
|
26418
|
+
tabs: b.pages.map((v) => ({
|
|
26419
|
+
id: v.id,
|
|
26420
|
+
label: v.label,
|
|
26421
|
+
content: /* @__PURE__ */ g.jsx(lT, { page: v, data: y, isLoading: h })
|
|
26437
26422
|
})),
|
|
26438
26423
|
activeTabId: o,
|
|
26439
26424
|
onTabSelect: d
|
|
@@ -27015,8 +27000,8 @@ function YM({
|
|
|
27015
27000
|
visibleOptionLimit: m,
|
|
27016
27001
|
isLoading: y = !1,
|
|
27017
27002
|
clearable: b = !0,
|
|
27018
|
-
searchable:
|
|
27019
|
-
multi:
|
|
27003
|
+
searchable: v = !0,
|
|
27004
|
+
multi: x = !1,
|
|
27020
27005
|
creatable: C = !1
|
|
27021
27006
|
}) {
|
|
27022
27007
|
const { input: S, meta: k } = wt(i, {
|
|
@@ -27042,7 +27027,7 @@ function YM({
|
|
|
27042
27027
|
if (y || C) return;
|
|
27043
27028
|
const P = S.value;
|
|
27044
27029
|
if (!(!P || Array.isArray(P) && P.length === 0))
|
|
27045
|
-
if (
|
|
27030
|
+
if (x) {
|
|
27046
27031
|
const _ = P, D = _.filter((H) => O(H));
|
|
27047
27032
|
D.length !== _.length && S.onChange(D);
|
|
27048
27033
|
} else O(P) || S.onChange("");
|
|
@@ -27050,7 +27035,7 @@ function YM({
|
|
|
27050
27035
|
const z = (P) => {
|
|
27051
27036
|
var D;
|
|
27052
27037
|
const _ = P.value;
|
|
27053
|
-
|
|
27038
|
+
x ? S.onChange(_.map((H) => {
|
|
27054
27039
|
var X;
|
|
27055
27040
|
return ((X = R(H.id)) == null ? void 0 : X.id) ?? H.id;
|
|
27056
27041
|
})) : _.length > 0 ? S.onChange(((D = R(_[0].id)) == null ? void 0 : D.id) ?? _[0].id) : S.onChange("");
|
|
@@ -27083,8 +27068,8 @@ function YM({
|
|
|
27083
27068
|
placeholder: !l && !o ? h : "",
|
|
27084
27069
|
disabled: l,
|
|
27085
27070
|
clearable: !l && !o && b,
|
|
27086
|
-
searchable:
|
|
27087
|
-
multi:
|
|
27071
|
+
searchable: v,
|
|
27072
|
+
multi: x,
|
|
27088
27073
|
overrides: VT(i, l, o),
|
|
27089
27074
|
creatable: C,
|
|
27090
27075
|
filterOptions: (P, _, D, H) => F0(P, _, D, H).slice(0, m),
|
|
@@ -27120,9 +27105,9 @@ const XM = ({
|
|
|
27120
27105
|
label: e,
|
|
27121
27106
|
format: h,
|
|
27122
27107
|
parse: f
|
|
27123
|
-
}), b = (
|
|
27124
|
-
m.onChange(
|
|
27125
|
-
},
|
|
27108
|
+
}), b = (x) => {
|
|
27109
|
+
m.onChange(x.currentTarget.checked);
|
|
27110
|
+
}, v = d ?? (m.value ? "Enabled" : "Disabled");
|
|
27126
27111
|
return /* @__PURE__ */ g.jsx(
|
|
27127
27112
|
ht,
|
|
27128
27113
|
{
|
|
@@ -27144,15 +27129,15 @@ const XM = ({
|
|
|
27144
27129
|
labelPlacement: R0.right,
|
|
27145
27130
|
overrides: {
|
|
27146
27131
|
Label: {
|
|
27147
|
-
style: ({ $theme:
|
|
27148
|
-
fontSize:
|
|
27132
|
+
style: ({ $theme: x }) => ({
|
|
27133
|
+
fontSize: x.sizing.scale550
|
|
27149
27134
|
})
|
|
27150
27135
|
},
|
|
27151
27136
|
Root: {
|
|
27152
27137
|
style: o ? { cursor: "default" } : {}
|
|
27153
27138
|
}
|
|
27154
27139
|
},
|
|
27155
|
-
children:
|
|
27140
|
+
children: v
|
|
27156
27141
|
}
|
|
27157
27142
|
)
|
|
27158
27143
|
}
|
|
@@ -27206,11 +27191,11 @@ const XM = ({
|
|
|
27206
27191
|
format: h,
|
|
27207
27192
|
parse: f
|
|
27208
27193
|
}), b = Wt(
|
|
27209
|
-
() => d.findIndex((
|
|
27194
|
+
() => d.findIndex((x) => x.value === m.value),
|
|
27210
27195
|
[d, m]
|
|
27211
|
-
),
|
|
27212
|
-
(
|
|
27213
|
-
|
|
27196
|
+
), v = An(
|
|
27197
|
+
(x, C) => {
|
|
27198
|
+
x.preventDefault(), x.stopPropagation(), m.onChange(d[C].value);
|
|
27214
27199
|
},
|
|
27215
27200
|
[m, d]
|
|
27216
27201
|
);
|
|
@@ -27227,21 +27212,21 @@ const XM = ({
|
|
|
27227
27212
|
X0,
|
|
27228
27213
|
{
|
|
27229
27214
|
kind: Q0.singleSelect,
|
|
27230
|
-
onClick:
|
|
27215
|
+
onClick: v,
|
|
27231
27216
|
selected: b,
|
|
27232
27217
|
disabled: l || o,
|
|
27233
27218
|
overrides: $T,
|
|
27234
|
-
children: d.map((
|
|
27219
|
+
children: d.map((x) => /* @__PURE__ */ g.jsx(
|
|
27235
27220
|
J0,
|
|
27236
27221
|
{
|
|
27237
27222
|
tileKind: Z0.selection,
|
|
27238
|
-
leadingContent: () => /* @__PURE__ */ g.jsx(y0, { $style: { textAlign: "left" }, children:
|
|
27223
|
+
leadingContent: () => /* @__PURE__ */ g.jsx(y0, { $style: { textAlign: "left" }, children: x.label }),
|
|
27239
27224
|
headerAlignment: Rc.left,
|
|
27240
27225
|
bodyAlignment: Rc.left,
|
|
27241
27226
|
overrides: _T,
|
|
27242
|
-
children: /* @__PURE__ */ g.jsx(ey, { $style: { textAlign: "left", marginBottom: p.sizing.scale600 }, children:
|
|
27227
|
+
children: /* @__PURE__ */ g.jsx(ey, { $style: { textAlign: "left", marginBottom: p.sizing.scale600 }, children: x.description })
|
|
27243
27228
|
},
|
|
27244
|
-
String(
|
|
27229
|
+
String(x.value)
|
|
27245
27230
|
))
|
|
27246
27231
|
}
|
|
27247
27232
|
)
|
|
@@ -27264,7 +27249,7 @@ const XM = ({
|
|
|
27264
27249
|
options: d,
|
|
27265
27250
|
align: p = iy.horizontal
|
|
27266
27251
|
}) => {
|
|
27267
|
-
var
|
|
27252
|
+
var x;
|
|
27268
27253
|
const { input: m, meta: y } = wt(i, {
|
|
27269
27254
|
required: r,
|
|
27270
27255
|
validate: s,
|
|
@@ -27273,7 +27258,7 @@ const XM = ({
|
|
|
27273
27258
|
label: e,
|
|
27274
27259
|
format: h,
|
|
27275
27260
|
parse: f
|
|
27276
|
-
}), b = d.every(({ value: C }) => typeof C == "boolean"),
|
|
27261
|
+
}), b = d.every(({ value: C }) => typeof C == "boolean"), v = An(
|
|
27277
27262
|
(C) => {
|
|
27278
27263
|
const S = C.currentTarget.value;
|
|
27279
27264
|
m.onChange(b ? S === "true" : S);
|
|
@@ -27294,7 +27279,7 @@ const XM = ({
|
|
|
27294
27279
|
{
|
|
27295
27280
|
id: m.name,
|
|
27296
27281
|
readOnly: !0,
|
|
27297
|
-
value: ((
|
|
27282
|
+
value: ((x = d.find((C) => C.value === m.value)) == null ? void 0 : x.label) ?? "",
|
|
27298
27283
|
overrides: {
|
|
27299
27284
|
InputContainer: {
|
|
27300
27285
|
style: ({ $theme: C }) => ({
|
|
@@ -27321,7 +27306,7 @@ const XM = ({
|
|
|
27321
27306
|
value: typeof m.value == "boolean" ? String(m.value) : m.value,
|
|
27322
27307
|
align: p,
|
|
27323
27308
|
disabled: l,
|
|
27324
|
-
onChange:
|
|
27309
|
+
onChange: v,
|
|
27325
27310
|
onBlur: m.onBlur,
|
|
27326
27311
|
onFocus: m.onFocus,
|
|
27327
27312
|
overrides: {
|
|
@@ -27473,12 +27458,12 @@ const eO = ({
|
|
|
27473
27458
|
label: e,
|
|
27474
27459
|
format: u,
|
|
27475
27460
|
parse: h
|
|
27476
|
-
}), { value: b = [], onChange:
|
|
27461
|
+
}), { value: b = [], onChange: v } = m, x = An(
|
|
27477
27462
|
(S) => {
|
|
27478
27463
|
const k = b.includes(S) ? b.filter((E) => E !== S) : [...b, S];
|
|
27479
|
-
|
|
27464
|
+
v(k);
|
|
27480
27465
|
},
|
|
27481
|
-
[b,
|
|
27466
|
+
[b, v]
|
|
27482
27467
|
), C = f.some((S) => S.description);
|
|
27483
27468
|
return /* @__PURE__ */ g.jsx(
|
|
27484
27469
|
ht,
|
|
@@ -27502,7 +27487,7 @@ const eO = ({
|
|
|
27502
27487
|
Zs,
|
|
27503
27488
|
{
|
|
27504
27489
|
checked: b.includes(S.id),
|
|
27505
|
-
onChange: () =>
|
|
27490
|
+
onChange: () => x(S.id),
|
|
27506
27491
|
disabled: o,
|
|
27507
27492
|
overrides: {
|
|
27508
27493
|
Label: {
|
|
@@ -27582,8 +27567,8 @@ const tO = ({
|
|
|
27582
27567
|
{
|
|
27583
27568
|
id: y.name,
|
|
27584
27569
|
value: y.value,
|
|
27585
|
-
onChange: ({ date:
|
|
27586
|
-
at.isNil(
|
|
27570
|
+
onChange: ({ date: v }) => {
|
|
27571
|
+
at.isNil(v) && YT(y.value) || y.onChange(v);
|
|
27587
27572
|
},
|
|
27588
27573
|
placeholder: !a && !o ? l ?? "MM/dd/yyyy" : "",
|
|
27589
27574
|
formatString: "MM/dd/yyyy",
|
|
@@ -27601,8 +27586,8 @@ const tO = ({
|
|
|
27601
27586
|
},
|
|
27602
27587
|
overrides: {
|
|
27603
27588
|
InputContainer: {
|
|
27604
|
-
style: ({ $theme:
|
|
27605
|
-
backgroundColor:
|
|
27589
|
+
style: ({ $theme: v }) => ({
|
|
27590
|
+
backgroundColor: v.colors.backgroundPrimary
|
|
27606
27591
|
})
|
|
27607
27592
|
}
|
|
27608
27593
|
}
|
|
@@ -27644,7 +27629,7 @@ const iO = ({
|
|
|
27644
27629
|
label: e,
|
|
27645
27630
|
format: f,
|
|
27646
27631
|
parse: d
|
|
27647
|
-
}), [
|
|
27632
|
+
}), [v, x] = G(), C = ((S = y.value) == null ? void 0 : S.length) ?? 0;
|
|
27648
27633
|
return /* @__PURE__ */ g.jsx(
|
|
27649
27634
|
ht,
|
|
27650
27635
|
{
|
|
@@ -27658,16 +27643,16 @@ const iO = ({
|
|
|
27658
27643
|
children: o ? /* @__PURE__ */ g.jsx(
|
|
27659
27644
|
"div",
|
|
27660
27645
|
{
|
|
27661
|
-
className:
|
|
27662
|
-
...
|
|
27646
|
+
className: v({
|
|
27647
|
+
...x.typography.font300,
|
|
27663
27648
|
// To prevent the div from collapsing when the content is empty
|
|
27664
|
-
minHeight: String(
|
|
27665
|
-
border: `${
|
|
27666
|
-
borderRadius:
|
|
27667
|
-
paddingTop:
|
|
27668
|
-
paddingBottom:
|
|
27669
|
-
paddingLeft:
|
|
27670
|
-
paddingRight:
|
|
27649
|
+
minHeight: String(x.typography.font300.lineHeight),
|
|
27650
|
+
border: `${x.sizing.scale0} solid ${x.colors.borderOpaque}`,
|
|
27651
|
+
borderRadius: x.borders.radius300,
|
|
27652
|
+
paddingTop: x.sizing.scale400,
|
|
27653
|
+
paddingBottom: x.sizing.scale400,
|
|
27654
|
+
paddingLeft: x.sizing.scale550,
|
|
27655
|
+
paddingRight: x.sizing.scale550
|
|
27671
27656
|
}),
|
|
27672
27657
|
children: /* @__PURE__ */ g.jsx(oi, { children: y.value })
|
|
27673
27658
|
}
|
|
@@ -27894,11 +27879,11 @@ var eM = ["length"], tM = ["meta", "input"], iM = La.reduce(function(i, e) {
|
|
|
27894
27879
|
format: function(R) {
|
|
27895
27880
|
return R;
|
|
27896
27881
|
}
|
|
27897
|
-
}), b = y.meta,
|
|
27898
|
-
for (var z =
|
|
27882
|
+
}), b = y.meta, v = b.length, x = _h(b, eM), C = y.input, S = _h(y, tM), k = function(R) {
|
|
27883
|
+
for (var z = v || 0, F = 0; F < z; F++)
|
|
27899
27884
|
R(e + "[" + F + "]", F);
|
|
27900
27885
|
}, E = function(R) {
|
|
27901
|
-
for (var z =
|
|
27886
|
+
for (var z = v || 0, F = [], P = 0; P < z; P++)
|
|
27902
27887
|
F.push(R(e + "[" + P + "]", P));
|
|
27903
27888
|
return F;
|
|
27904
27889
|
};
|
|
@@ -27906,12 +27891,12 @@ var eM = ["length"], tM = ["meta", "input"], iM = La.reduce(function(i, e) {
|
|
|
27906
27891
|
fields: Ks({
|
|
27907
27892
|
name: e,
|
|
27908
27893
|
forEach: k,
|
|
27909
|
-
length:
|
|
27894
|
+
length: v || 0,
|
|
27910
27895
|
map: E
|
|
27911
27896
|
}, p, S, {
|
|
27912
27897
|
value: C.value
|
|
27913
27898
|
}),
|
|
27914
|
-
meta:
|
|
27899
|
+
meta: x
|
|
27915
27900
|
};
|
|
27916
27901
|
};
|
|
27917
27902
|
function Mm(i, { minItems: e = 0, readOnly: t = !1 } = {}) {
|
|
@@ -27994,12 +27979,12 @@ function lO({
|
|
|
27994
27979
|
const { entries: c, handleItemAdd: u, remove: h, isRemovable: f } = Mm(i, {
|
|
27995
27980
|
minItems: n,
|
|
27996
27981
|
readOnly: r
|
|
27997
|
-
}), d = t ?? (e ? `Add ${e.toLowerCase()}` : "Add more");
|
|
27998
|
-
return /* @__PURE__ */ g.jsxs(
|
|
27999
|
-
c.map(({ id:
|
|
27982
|
+
}), d = t ?? (e ? `Add ${e.toLowerCase()}` : "Add more"), [p, m] = G();
|
|
27983
|
+
return /* @__PURE__ */ g.jsxs("div", { className: p({ display: "flex", flexDirection: "column", gap: m.sizing.scale800 }), children: [
|
|
27984
|
+
c.map(({ id: y, indexedFieldPath: b }, v) => /* @__PURE__ */ g.jsx(Em, { index: v, rootFieldPath: i, children: /* @__PURE__ */ g.jsx(
|
|
28000
27985
|
XT,
|
|
28001
27986
|
{
|
|
28002
|
-
title: e ? `${e} ${
|
|
27987
|
+
title: e ? `${e} ${v + 1}` : void 0,
|
|
28003
27988
|
description: o,
|
|
28004
27989
|
tooltip: l,
|
|
28005
27990
|
collapsible: a,
|
|
@@ -28012,19 +27997,19 @@ function lO({
|
|
|
28012
27997
|
size: dt.compact,
|
|
28013
27998
|
startEnhancer: /* @__PURE__ */ g.jsx(pe, { name: "trashCan", kind: ys.PRIMARY }),
|
|
28014
27999
|
"aria-label": "Remove",
|
|
28015
|
-
onClick: () => h(
|
|
28000
|
+
onClick: () => h(v),
|
|
28016
28001
|
children: "Remove"
|
|
28017
28002
|
}
|
|
28018
28003
|
),
|
|
28019
28004
|
overrides: {
|
|
28020
|
-
//
|
|
28021
|
-
//
|
|
28022
|
-
//
|
|
28005
|
+
// ArrayFormGroup owns spacing between its own entries and the trailing AddButton via
|
|
28006
|
+
// the wrapping flex gap above, so each entry's own marginBottom would double up
|
|
28007
|
+
// (flex gap and margin are additive, not collapsing) and needs to be zeroed here.
|
|
28023
28008
|
BoxContainer: { style: { marginBottom: 0 } }
|
|
28024
28009
|
},
|
|
28025
|
-
children: s(
|
|
28010
|
+
children: s(b, v)
|
|
28026
28011
|
}
|
|
28027
|
-
) },
|
|
28012
|
+
) }, y)),
|
|
28028
28013
|
!r && /* @__PURE__ */ g.jsx(Tm, { label: d, shape: xt.pill, onClick: u })
|
|
28029
28014
|
] });
|
|
28030
28015
|
}
|