impact-nova 1.7.39 → 1.7.41
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/ui/ag-grid-react/cell-renderers/editors/date-cell-editor.js +58 -48
- package/dist/components/ui/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.d.ts +0 -2
- package/dist/components/ui/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.js +212 -218
- package/dist/components/ui/ag-grid-react/headers/advanced-filter/column-filter-section.d.ts +2 -2
- package/dist/components/ui/ag-grid-react/headers/advanced-filter/column-filter-section.js +97 -127
- package/dist/components/ui/ag-grid-react/headers/components/date-filter-picker.d.ts +39 -0
- package/dist/components/ui/ag-grid-react/headers/header-search-input.js +433 -299
- package/dist/components/ui/ag-grid-react/headers/utils/date-utils.d.ts +33 -1
- package/dist/components/ui/ag-grid-react/headers/utils/date-utils.js +60 -26
- package/dist/components/ui/ag-grid-react/headers/utils/filter-utils.d.ts +11 -10
- package/dist/components/ui/ag-grid-react/headers/utils/filter-utils.js +284 -260
- package/dist/components/ui/ag-grid-react/index.js +24 -25
- package/dist/components/ui/data-table/column-indicator.d.ts +17 -0
- package/dist/components/ui/data-table/column-indicator.js +30 -0
- package/dist/components/ui/data-table/data-table-column-list.js +210 -154
- package/dist/components/ui/data-table/data-table.js +60 -59
- package/dist/components/ui/data-table/index.d.ts +3 -0
- package/dist/components/ui/data-table/index.js +34 -28
- package/dist/components/ui/data-table/indicator-legend.d.ts +8 -0
- package/dist/components/ui/data-table/indicator-legend.js +20 -0
- package/dist/components/ui/data-table/pin-switch.d.ts +30 -0
- package/dist/components/ui/data-table/pin-switch.js +75 -0
- package/dist/components/ui/date-picker/date-picker.js +65 -63
- package/dist/components/ui/date-picker/date-range-picker.js +77 -75
- package/dist/components/ui/nested-list/components/NestedListContent.js +7 -7
- package/dist/components/ui/nested-list/components/SortableItem.d.ts +10 -0
- package/dist/components/ui/nested-list/components/SortableItem.js +91 -83
- package/dist/components/ui/nested-list/nested-list.js +184 -178
- package/dist/components/ui/types/ag-grid.types.d.ts +16 -2
- package/dist/components/ui/types/date-picker.types.d.ts +4 -0
- package/dist/components/ui/types/nested-list.types.d.ts +12 -0
- package/dist/i18n/defaultMessages.d.ts +10 -0
- package/dist/i18n/defaultMessages.js +16 -8
- package/dist/i18n/locales/de.js +8 -0
- package/dist/i18n/locales/es.js +8 -0
- package/dist/i18n/locales/hi.js +8 -0
- package/dist/i18n/locales/kn.js +8 -0
- package/dist/icons/assets/archive.svg.js +5 -0
- package/dist/icons/index.d.ts +1 -0
- package/dist/icons/index.js +280 -278
- package/dist/impact-nova.css +1 -1
- package/dist/index.js +180 -174
- package/package.json +1 -1
- package/tailwind.config.js +16 -0
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { jsx as L, jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { SortableItem as
|
|
1
|
+
import { jsx as L, jsxs as ce } from "react/jsx-runtime";
|
|
2
|
+
import q, { useMemo as T, useCallback as w } from "react";
|
|
3
|
+
import { SortableItem as qe } from "./components/SortableItem.js";
|
|
4
4
|
import { SelectionMode as U } from "../types/nested-list.types.js";
|
|
5
|
-
import { useNestedListDragDrop as
|
|
6
|
-
import { useNestedListSelectAll as
|
|
7
|
-
import { useNestedListState as
|
|
8
|
-
import { useNestedListHandlers as
|
|
9
|
-
import { NestedListHeader as
|
|
10
|
-
import { NestedListCategoryFilters as
|
|
11
|
-
import { NestedListContent as
|
|
12
|
-
import { NestedListApplyDiscardButtons as
|
|
13
|
-
import { cn as
|
|
14
|
-
import { useImpactNovaI18n as
|
|
15
|
-
const
|
|
5
|
+
import { useNestedListDragDrop as Ke } from "./hooks/useNestedListDragDrop.js";
|
|
6
|
+
import { useNestedListSelectAll as Qe } from "./hooks/useNestedListSelectAll.js";
|
|
7
|
+
import { useNestedListState as Xe } from "./hooks/useNestedListState.js";
|
|
8
|
+
import { useNestedListHandlers as Ye } from "./hooks/useNestedListHandlers.js";
|
|
9
|
+
import { NestedListHeader as Ze } from "./components/NestedListHeader.js";
|
|
10
|
+
import { NestedListCategoryFilters as $e } from "./components/NestedListCategoryFilters.js";
|
|
11
|
+
import { NestedListContent as Me } from "./components/NestedListContent.js";
|
|
12
|
+
import { NestedListApplyDiscardButtons as Ge } from "./components/NestedListApplyDiscardButtons.js";
|
|
13
|
+
import { cn as et } from "../../../lib/utils.js";
|
|
14
|
+
import { useImpactNovaI18n as tt } from "../../../i18n/ImpactNovaI18nContext.js";
|
|
15
|
+
const oe = (i, t) => {
|
|
16
16
|
if (!t || typeof t != "string") return i;
|
|
17
17
|
const c = t.toLowerCase(), o = [];
|
|
18
18
|
return i.forEach((r) => {
|
|
19
|
-
const l = r.label.toLowerCase().includes(c),
|
|
20
|
-
(l ||
|
|
19
|
+
const l = r.label.toLowerCase().includes(c), u = r.children ? oe(r.children, t) : void 0;
|
|
20
|
+
(l || u && u.length > 0) && o.push({
|
|
21
21
|
...r,
|
|
22
|
-
children:
|
|
22
|
+
children: u || r.children
|
|
23
23
|
});
|
|
24
24
|
}), o;
|
|
25
|
-
},
|
|
25
|
+
}, de = (i) => i.map((t) => {
|
|
26
26
|
if (t.children && t.children.length > 0) {
|
|
27
|
-
const c =
|
|
27
|
+
const c = de(t.children), o = c.every((r) => r.checked);
|
|
28
28
|
return {
|
|
29
29
|
...t,
|
|
30
30
|
checked: o,
|
|
@@ -32,200 +32,202 @@ const ce = (i, t) => {
|
|
|
32
32
|
};
|
|
33
33
|
}
|
|
34
34
|
return t;
|
|
35
|
-
}),
|
|
35
|
+
}), st = (i, t) => {
|
|
36
36
|
const c = /* @__PURE__ */ new Set(), o = (r) => {
|
|
37
37
|
r.forEach((l) => {
|
|
38
|
-
const
|
|
39
|
-
|
|
38
|
+
const u = t ? t(l) : l.category;
|
|
39
|
+
u && c.add(u), l.children && o(l.children);
|
|
40
40
|
});
|
|
41
41
|
};
|
|
42
42
|
return o(i), Array.from(c).sort();
|
|
43
|
-
},
|
|
43
|
+
}, ie = (i, t, c) => {
|
|
44
44
|
if (t.size === 0) return i;
|
|
45
45
|
const o = [];
|
|
46
46
|
return i.forEach((r) => {
|
|
47
|
-
const l = c ? c(r) : r.category,
|
|
48
|
-
(
|
|
47
|
+
const l = c ? c(r) : r.category, u = l && t.has(l), C = r.children ? ie(r.children, t, c) : void 0;
|
|
48
|
+
(u || C && C.length > 0) && o.push({
|
|
49
49
|
...r,
|
|
50
|
-
children:
|
|
50
|
+
children: C
|
|
51
51
|
});
|
|
52
52
|
}), o;
|
|
53
|
-
},
|
|
53
|
+
}, ae = (i, t, c, o = 0) => {
|
|
54
54
|
const r = [];
|
|
55
55
|
return i.forEach((l) => {
|
|
56
56
|
r.push({ item: l, level: o }), !t[l.id] && l.children && l.children.length > 0 && l.id !== c && r.push(
|
|
57
|
-
...
|
|
57
|
+
...ae(l.children, t, c, o + 1)
|
|
58
58
|
);
|
|
59
59
|
}), r;
|
|
60
|
-
},
|
|
60
|
+
}, St = ({
|
|
61
61
|
items: i,
|
|
62
62
|
onChange: t,
|
|
63
63
|
onSubmit: c,
|
|
64
64
|
onCancel: o,
|
|
65
65
|
onItemToggle: r,
|
|
66
66
|
onDragEnd: l,
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
67
|
+
renderLabelExtras: u,
|
|
68
|
+
renderActions: C,
|
|
69
|
+
enableSearch: he = !0,
|
|
70
|
+
enableDragDrop: _ = !0,
|
|
71
|
+
enableSelectAll: ue = !0,
|
|
70
72
|
enableGroupBy: k = !1,
|
|
71
73
|
getCategory: I,
|
|
72
|
-
searchPlaceholder:
|
|
73
|
-
className:
|
|
74
|
-
groupLabel:
|
|
74
|
+
searchPlaceholder: fe,
|
|
75
|
+
className: pe = "",
|
|
76
|
+
groupLabel: me,
|
|
75
77
|
enableApplyDiscard: p = !1,
|
|
76
|
-
enableCollapse:
|
|
77
|
-
enableGlobalCollapse:
|
|
78
|
-
submitButtonLabel:
|
|
79
|
-
cancelButtonLabel:
|
|
78
|
+
enableCollapse: K = !0,
|
|
79
|
+
enableGlobalCollapse: Ne = !0,
|
|
80
|
+
submitButtonLabel: Se,
|
|
81
|
+
cancelButtonLabel: Ce,
|
|
80
82
|
selectionMode: v = U.CASCADE_DOWN,
|
|
81
|
-
initialCollapsedItems:
|
|
82
|
-
onCollapseChange:
|
|
83
|
-
canDrag:
|
|
83
|
+
initialCollapsedItems: Ie,
|
|
84
|
+
onCollapseChange: Q,
|
|
85
|
+
canDrag: A
|
|
84
86
|
}) => {
|
|
85
|
-
const { t: P } =
|
|
87
|
+
const { t: P } = tt(), ve = fe ?? P("nestedList.searchPlaceholder"), ge = Se ?? P("nestedList.apply"), Le = Ce ?? P("nestedList.reset"), {
|
|
86
88
|
items: h,
|
|
87
89
|
setItems: g,
|
|
88
90
|
savedItems: b,
|
|
89
|
-
setSavedItems:
|
|
91
|
+
setSavedItems: X,
|
|
90
92
|
isUserChangeRef: x,
|
|
91
93
|
searchText: z,
|
|
92
|
-
setSearchText:
|
|
93
|
-
collapsedItems:
|
|
94
|
-
setCollapsedItems:
|
|
94
|
+
setSearchText: ke,
|
|
95
|
+
collapsedItems: m,
|
|
96
|
+
setCollapsedItems: Ee,
|
|
95
97
|
isListCollapsed: B,
|
|
96
|
-
setIsListCollapsed:
|
|
97
|
-
activeId:
|
|
98
|
-
setActiveId:
|
|
99
|
-
setOverId:
|
|
98
|
+
setIsListCollapsed: De,
|
|
99
|
+
activeId: N,
|
|
100
|
+
setActiveId: y,
|
|
101
|
+
setOverId: H,
|
|
100
102
|
selectedCategories: O,
|
|
101
|
-
setSelectedCategories:
|
|
102
|
-
itemsToBlink:
|
|
103
|
-
setItemsToBlink:
|
|
103
|
+
setSelectedCategories: Te,
|
|
104
|
+
itemsToBlink: Y,
|
|
105
|
+
setItemsToBlink: W,
|
|
104
106
|
// Normalized state helpers (for optimized operations)
|
|
105
|
-
isNormalized:
|
|
107
|
+
isNormalized: we,
|
|
106
108
|
normalizedState: Ae,
|
|
107
|
-
batchUpdateItems:
|
|
108
|
-
} =
|
|
109
|
+
batchUpdateItems: Pe
|
|
110
|
+
} = Xe({
|
|
109
111
|
initialItems: i,
|
|
110
112
|
enableApplyDiscard: p,
|
|
111
113
|
// Enable normalized state for large datasets (can be made configurable via props)
|
|
112
114
|
enableNormalizedState: i.length > 1e3,
|
|
113
|
-
initialCollapsedItems:
|
|
115
|
+
initialCollapsedItems: Ie
|
|
114
116
|
});
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
}, [
|
|
118
|
-
const [R,
|
|
119
|
-
sensors:
|
|
120
|
-
handleDragEnd:
|
|
121
|
-
isValidDrop:
|
|
122
|
-
} =
|
|
117
|
+
q.useEffect(() => {
|
|
118
|
+
Q?.(m);
|
|
119
|
+
}, [m, Q]);
|
|
120
|
+
const [R, Z] = q.useState(0), [V, be] = q.useState(0), {
|
|
121
|
+
sensors: xe,
|
|
122
|
+
handleDragEnd: ze,
|
|
123
|
+
isValidDrop: $
|
|
124
|
+
} = Ke({
|
|
123
125
|
items: h,
|
|
124
126
|
onDragEnd: l,
|
|
125
|
-
collapsedItems:
|
|
126
|
-
canDrag:
|
|
127
|
-
}),
|
|
128
|
-
() => k ?
|
|
127
|
+
collapsedItems: m,
|
|
128
|
+
canDrag: A
|
|
129
|
+
}), Be = T(
|
|
130
|
+
() => k ? st(h, I) : [],
|
|
129
131
|
[h, k, I]
|
|
130
|
-
),
|
|
132
|
+
), S = T(() => {
|
|
131
133
|
let e = h;
|
|
132
|
-
return k && O.size > 0 && (e =
|
|
133
|
-
}, [h, z, k, O, I]),
|
|
134
|
-
() =>
|
|
135
|
-
[
|
|
136
|
-
), { allChecked: E, someChecked:
|
|
134
|
+
return k && O.size > 0 && (e = ie(e, O, I)), z && (e = oe(e, z)), e;
|
|
135
|
+
}, [h, z, k, O, I]), Oe = T(
|
|
136
|
+
() => ae(S, m, N),
|
|
137
|
+
[S, m, N]
|
|
138
|
+
), { allChecked: E, someChecked: Re } = T(() => {
|
|
137
139
|
let e = !0, s = !1;
|
|
138
|
-
const n = (
|
|
139
|
-
for (const d of
|
|
140
|
+
const n = (f) => {
|
|
141
|
+
for (const d of f)
|
|
140
142
|
if (d.children && d.children.length > 0 ? n(d.children) : d.checked ? s = !0 : e = !1, s && !e) return;
|
|
141
143
|
};
|
|
142
|
-
return n(
|
|
143
|
-
}, [
|
|
144
|
+
return n(S), { allChecked: e && s, someChecked: s };
|
|
145
|
+
}, [S]), Ve = Re && !E, j = (e, s) => {
|
|
144
146
|
for (const n of e) {
|
|
145
147
|
if (n.id === s) return n;
|
|
146
148
|
if (n.children) {
|
|
147
|
-
const
|
|
148
|
-
if (
|
|
149
|
+
const f = j(n.children, s);
|
|
150
|
+
if (f) return f;
|
|
149
151
|
}
|
|
150
152
|
}
|
|
151
153
|
return null;
|
|
152
|
-
},
|
|
154
|
+
}, Ue = w(
|
|
153
155
|
(e, s) => {
|
|
154
156
|
if (v === U.INDEPENDENT)
|
|
155
157
|
return e;
|
|
156
158
|
const n = (d, a) => d.id === a ? !0 : d.children ? d.children.some(
|
|
157
159
|
(D) => n(D, a)
|
|
158
|
-
) : !1,
|
|
160
|
+
) : !1, f = (d) => d.map((a) => {
|
|
159
161
|
if (a.id === s)
|
|
160
162
|
return a;
|
|
161
163
|
if (a.children && n(a, s)) {
|
|
162
|
-
const D =
|
|
163
|
-
let
|
|
164
|
-
return v === U.CASCADE_UP_DOWN ?
|
|
164
|
+
const D = f(a.children);
|
|
165
|
+
let F;
|
|
166
|
+
return v === U.CASCADE_UP_DOWN ? F = D.some((J) => J.checked) : F = D.every((J) => J.checked), {
|
|
165
167
|
...a,
|
|
166
|
-
checked:
|
|
168
|
+
checked: F,
|
|
167
169
|
children: D
|
|
168
170
|
};
|
|
169
171
|
}
|
|
170
172
|
return a;
|
|
171
173
|
});
|
|
172
|
-
return
|
|
174
|
+
return f(e);
|
|
173
175
|
},
|
|
174
176
|
[v]
|
|
175
|
-
),
|
|
177
|
+
), M = (e) => {
|
|
176
178
|
const s = [];
|
|
177
179
|
return e.forEach((n) => {
|
|
178
|
-
n.children && n.children.length > 0 && (s.push(n.id), s.push(
|
|
180
|
+
n.children && n.children.length > 0 && (s.push(n.id), s.push(...M(n.children)));
|
|
179
181
|
}), s;
|
|
180
182
|
}, {
|
|
181
|
-
handleToggle:
|
|
182
|
-
handleToggleCollapse:
|
|
183
|
-
handleCollapseAll:
|
|
184
|
-
handleToggleCategory:
|
|
185
|
-
} =
|
|
183
|
+
handleToggle: G,
|
|
184
|
+
handleToggleCollapse: ee,
|
|
185
|
+
handleCollapseAll: _e,
|
|
186
|
+
handleToggleCategory: ye
|
|
187
|
+
} = Ye({
|
|
186
188
|
setItems: g,
|
|
187
|
-
findItemById:
|
|
188
|
-
updateParentsUpward:
|
|
189
|
+
findItemById: j,
|
|
190
|
+
updateParentsUpward: Ue,
|
|
189
191
|
onChange: (e) => {
|
|
190
|
-
|
|
192
|
+
Z((s) => s + 1), t(e);
|
|
191
193
|
},
|
|
192
194
|
onItemToggle: r,
|
|
193
195
|
getCategory: I,
|
|
194
|
-
setCollapsedItems:
|
|
195
|
-
setIsListCollapsed:
|
|
196
|
-
setSelectedCategories:
|
|
196
|
+
setCollapsedItems: Ee,
|
|
197
|
+
setIsListCollapsed: De,
|
|
198
|
+
setSelectedCategories: Te,
|
|
197
199
|
isUserChangeRef: x,
|
|
198
200
|
selectionMode: v,
|
|
199
201
|
// Pass normalized state helpers for optimized operations
|
|
200
|
-
isNormalized:
|
|
202
|
+
isNormalized: we,
|
|
201
203
|
normalizedState: Ae,
|
|
202
|
-
batchUpdateItems:
|
|
204
|
+
batchUpdateItems: Pe
|
|
203
205
|
}), {
|
|
204
|
-
collectVisibleItemIds:
|
|
205
|
-
findItemsNotSelected:
|
|
206
|
-
collectVisibleItemsForCallback:
|
|
207
|
-
updateVisibleItems:
|
|
208
|
-
} =
|
|
209
|
-
findItemById:
|
|
206
|
+
collectVisibleItemIds: te,
|
|
207
|
+
findItemsNotSelected: se,
|
|
208
|
+
collectVisibleItemsForCallback: re,
|
|
209
|
+
updateVisibleItems: ne
|
|
210
|
+
} = Qe({
|
|
211
|
+
findItemById: j,
|
|
210
212
|
getCategory: I
|
|
211
|
-
}),
|
|
213
|
+
}), He = w(() => {
|
|
212
214
|
x.current = !0, g((e) => {
|
|
213
|
-
const s =
|
|
214
|
-
|
|
215
|
+
const s = te(S), n = se(
|
|
216
|
+
S,
|
|
215
217
|
e,
|
|
216
218
|
s
|
|
217
219
|
);
|
|
218
220
|
if (n.size > 0) {
|
|
219
221
|
const a = new Set(n);
|
|
220
|
-
|
|
222
|
+
W(a), setTimeout(() => W(/* @__PURE__ */ new Set()), 600);
|
|
221
223
|
}
|
|
222
|
-
const
|
|
224
|
+
const f = ne(
|
|
223
225
|
e,
|
|
224
226
|
s,
|
|
225
227
|
!E
|
|
226
|
-
), d = v === U.INDEPENDENT ?
|
|
228
|
+
), d = v === U.INDEPENDENT ? f : de(f);
|
|
227
229
|
if (t(d), r) {
|
|
228
|
-
const a =
|
|
230
|
+
const a = re(
|
|
229
231
|
e,
|
|
230
232
|
s,
|
|
231
233
|
!E
|
|
@@ -238,128 +240,132 @@ const ce = (i, t) => {
|
|
|
238
240
|
E,
|
|
239
241
|
t,
|
|
240
242
|
r,
|
|
241
|
-
|
|
242
|
-
ee,
|
|
243
|
+
S,
|
|
243
244
|
te,
|
|
244
245
|
se,
|
|
245
246
|
re,
|
|
247
|
+
ne,
|
|
246
248
|
x,
|
|
247
249
|
g,
|
|
248
|
-
|
|
250
|
+
W,
|
|
249
251
|
v
|
|
250
|
-
]),
|
|
252
|
+
]), We = w(
|
|
251
253
|
(e, s) => {
|
|
252
|
-
const n =
|
|
254
|
+
const n = N ? $(N, e.id) : !1, f = Y.has(e.id), d = A ? !A(e, s) : e.isDragDisabled ?? !1;
|
|
253
255
|
return /* @__PURE__ */ L(
|
|
254
|
-
|
|
256
|
+
qe,
|
|
255
257
|
{
|
|
256
258
|
item: e,
|
|
257
259
|
level: s,
|
|
258
|
-
isCollapsed:
|
|
259
|
-
onToggle:
|
|
260
|
-
onToggleCollapse:
|
|
261
|
-
isAnyDragging:
|
|
260
|
+
isCollapsed: m[e.id] || !1,
|
|
261
|
+
onToggle: G,
|
|
262
|
+
onToggleCollapse: ee,
|
|
263
|
+
isAnyDragging: N !== null,
|
|
262
264
|
isValidDrop: n,
|
|
263
|
-
enableDragDrop:
|
|
264
|
-
enableCollapse:
|
|
265
|
-
shouldBlink:
|
|
266
|
-
isDragDisabled: d
|
|
265
|
+
enableDragDrop: _,
|
|
266
|
+
enableCollapse: K,
|
|
267
|
+
shouldBlink: f,
|
|
268
|
+
isDragDisabled: d,
|
|
269
|
+
renderLabelExtras: u,
|
|
270
|
+
renderActions: C
|
|
267
271
|
},
|
|
268
272
|
e.id
|
|
269
273
|
);
|
|
270
274
|
},
|
|
271
275
|
[
|
|
272
|
-
N,
|
|
273
|
-
M,
|
|
274
|
-
G,
|
|
275
|
-
S,
|
|
276
|
-
Z,
|
|
277
276
|
m,
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
277
|
+
G,
|
|
278
|
+
ee,
|
|
279
|
+
N,
|
|
280
|
+
$,
|
|
281
|
+
_,
|
|
282
|
+
Y,
|
|
283
|
+
K,
|
|
284
|
+
A,
|
|
285
|
+
u,
|
|
286
|
+
C
|
|
281
287
|
]
|
|
282
|
-
),
|
|
283
|
-
p && (
|
|
284
|
-
}, [p, h, c,
|
|
285
|
-
p && (g(b),
|
|
288
|
+
), je = M(h).length > 0, le = T(() => p ? h.length > 1e3 ? R !== V : JSON.stringify(h) !== JSON.stringify(b) : !1, [p, h, b, R, V]), Fe = w(() => {
|
|
289
|
+
p && (X(h), be(R), c?.(h));
|
|
290
|
+
}, [p, h, c, X, R]), Je = w(() => {
|
|
291
|
+
p && (g(b), Z(V), o?.());
|
|
286
292
|
}, [p, b, o, g, V]);
|
|
287
|
-
return /* @__PURE__ */
|
|
293
|
+
return /* @__PURE__ */ ce(
|
|
288
294
|
"div",
|
|
289
295
|
{
|
|
290
|
-
className:
|
|
296
|
+
className: et("flex flex-col", pe),
|
|
291
297
|
"data-component": "nested-list",
|
|
292
|
-
"data-has-changes":
|
|
298
|
+
"data-has-changes": le ? "" : void 0,
|
|
293
299
|
"data-list-collapsed": B ? "" : void 0,
|
|
294
300
|
children: [
|
|
295
|
-
/* @__PURE__ */
|
|
301
|
+
/* @__PURE__ */ ce("div", { className: "flex-shrink-0", children: [
|
|
296
302
|
/* @__PURE__ */ L(
|
|
297
|
-
|
|
303
|
+
Ze,
|
|
298
304
|
{
|
|
299
|
-
hasItemsWithChildren:
|
|
305
|
+
hasItemsWithChildren: je,
|
|
300
306
|
isListCollapsed: B,
|
|
301
|
-
onCollapseAll:
|
|
302
|
-
enableSearch:
|
|
303
|
-
enableSelectAll:
|
|
304
|
-
groupLabel:
|
|
307
|
+
onCollapseAll: _e,
|
|
308
|
+
enableSearch: he,
|
|
309
|
+
enableSelectAll: ue,
|
|
310
|
+
groupLabel: me,
|
|
305
311
|
allChecked: E,
|
|
306
|
-
isIndeterminate:
|
|
307
|
-
onSelectAll:
|
|
312
|
+
isIndeterminate: Ve,
|
|
313
|
+
onSelectAll: He,
|
|
308
314
|
searchText: z,
|
|
309
315
|
onSearchChange: (e) => {
|
|
310
|
-
|
|
316
|
+
ke(e.target.value);
|
|
311
317
|
},
|
|
312
|
-
searchPlaceholder:
|
|
318
|
+
searchPlaceholder: ve,
|
|
313
319
|
selectAllLabel: P("nestedList.selectAll"),
|
|
314
|
-
enableCollapse:
|
|
320
|
+
enableCollapse: Ne
|
|
315
321
|
}
|
|
316
322
|
),
|
|
317
323
|
/* @__PURE__ */ L(
|
|
318
|
-
|
|
324
|
+
$e,
|
|
319
325
|
{
|
|
320
326
|
isListCollapsed: B,
|
|
321
327
|
enableGroupBy: k,
|
|
322
|
-
categories:
|
|
328
|
+
categories: Be,
|
|
323
329
|
selectedCategories: O,
|
|
324
|
-
onToggleCategory:
|
|
330
|
+
onToggleCategory: ye
|
|
325
331
|
}
|
|
326
332
|
)
|
|
327
333
|
] }),
|
|
328
334
|
/* @__PURE__ */ L("div", { className: "flex-1 min-h-0 overflow-hidden", children: /* @__PURE__ */ L(
|
|
329
|
-
|
|
335
|
+
Me,
|
|
330
336
|
{
|
|
331
337
|
isListCollapsed: B,
|
|
332
|
-
enableDragDrop:
|
|
333
|
-
sensors:
|
|
334
|
-
items:
|
|
335
|
-
renderItem:
|
|
336
|
-
activeId:
|
|
338
|
+
enableDragDrop: _,
|
|
339
|
+
sensors: xe,
|
|
340
|
+
items: Oe,
|
|
341
|
+
renderItem: We,
|
|
342
|
+
activeId: N,
|
|
337
343
|
onDragStart: (e) => {
|
|
338
|
-
|
|
344
|
+
y(e.active.id);
|
|
339
345
|
},
|
|
340
346
|
onDragOver: (e) => {
|
|
341
|
-
|
|
347
|
+
H(e.over?.id);
|
|
342
348
|
},
|
|
343
349
|
onDragEnd: (e) => {
|
|
344
|
-
|
|
350
|
+
y(null), H(null), x.current = !0, ze(e, (s) => {
|
|
345
351
|
const n = s(h);
|
|
346
352
|
g(n), t(n);
|
|
347
353
|
});
|
|
348
354
|
},
|
|
349
355
|
onDragCancel: () => {
|
|
350
|
-
|
|
356
|
+
y(null), H(null);
|
|
351
357
|
}
|
|
352
358
|
}
|
|
353
359
|
) }),
|
|
354
360
|
/* @__PURE__ */ L(
|
|
355
|
-
|
|
361
|
+
Ge,
|
|
356
362
|
{
|
|
357
363
|
enableApplyDiscard: p,
|
|
358
|
-
hasChanges:
|
|
359
|
-
onDiscard:
|
|
360
|
-
onApply:
|
|
361
|
-
cancelButtonLabel:
|
|
362
|
-
submitButtonLabel:
|
|
364
|
+
hasChanges: le,
|
|
365
|
+
onDiscard: Je,
|
|
366
|
+
onApply: Fe,
|
|
367
|
+
cancelButtonLabel: Le,
|
|
368
|
+
submitButtonLabel: ge
|
|
363
369
|
}
|
|
364
370
|
)
|
|
365
371
|
]
|
|
@@ -367,5 +373,5 @@ const ce = (i, t) => {
|
|
|
367
373
|
);
|
|
368
374
|
};
|
|
369
375
|
export {
|
|
370
|
-
|
|
376
|
+
St as NestedList
|
|
371
377
|
};
|
|
@@ -35,7 +35,18 @@ export interface ExtendedHeaderComponentParams extends Partial<IHeaderParams> {
|
|
|
35
35
|
enableBooleanParsing?: boolean;
|
|
36
36
|
enableDateParsing?: boolean;
|
|
37
37
|
/** Which picker to render for date columns. Default: 'date' */
|
|
38
|
-
datePickerVariant?: 'date' | 'month';
|
|
38
|
+
datePickerVariant?: 'date' | 'month' | 'week';
|
|
39
|
+
/** Display format for dates in this column (date-fns token string). Default: "MM/dd/yyyy" */
|
|
40
|
+
dateDisplayFormat?: string;
|
|
41
|
+
/** Fiscal calendar configuration for week/month picker */
|
|
42
|
+
fiscalConfig?: {
|
|
43
|
+
calendarType?: 'calendar' | 'fiscal';
|
|
44
|
+
fiscalMode?: 'basic' | 'advanced' | 'custom';
|
|
45
|
+
selectionMode?: 'week' | 'fiscalMonth';
|
|
46
|
+
fiscalMonthPattern?: number[];
|
|
47
|
+
fiscalYearStartMonth?: number;
|
|
48
|
+
weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
49
|
+
};
|
|
39
50
|
/** Generic info data for the info modal */
|
|
40
51
|
infoData?: InfoContent;
|
|
41
52
|
/** How to display the information (tooltip or modal) */
|
|
@@ -162,8 +173,11 @@ export interface AdvancedFilterGroup {
|
|
|
162
173
|
* Contains top-level logic and array of rules/groups.
|
|
163
174
|
*/
|
|
164
175
|
export interface AdvancedFilterModel {
|
|
165
|
-
/** Top-level logical operator */
|
|
176
|
+
/** Top-level logical operator (fallback when columnLogic is missing for a column) */
|
|
166
177
|
logic: 'AND' | 'OR';
|
|
167
178
|
/** Array of filter rules or groups */
|
|
168
179
|
rules: (AdvancedFilterRule | AdvancedFilterGroup)[];
|
|
180
|
+
/** Per-column logic operators. Key = columnId, value = AND/OR.
|
|
181
|
+
* When present, takes precedence over the top-level `logic` for that column. */
|
|
182
|
+
columnLogic?: Record<string, 'AND' | 'OR'>;
|
|
169
183
|
}
|
|
@@ -11,6 +11,8 @@ export interface DatePickerProps extends Omit<InputProps, 'value' | 'onChange' |
|
|
|
11
11
|
startMonth?: Date;
|
|
12
12
|
endMonth?: Date;
|
|
13
13
|
showFooter?: boolean;
|
|
14
|
+
/** Which day the week starts on. 0 = Sunday, 1 = Monday, etc. */
|
|
15
|
+
weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
14
16
|
}
|
|
15
17
|
export interface DateRangePickerProps extends Omit<InputProps, 'value' | 'onChange' | 'type' | 'suffix' | 'suffixClick'> {
|
|
16
18
|
value?: DateRange;
|
|
@@ -23,6 +25,8 @@ export interface DateRangePickerProps extends Omit<InputProps, 'value' | 'onChan
|
|
|
23
25
|
startMonth?: Date;
|
|
24
26
|
endMonth?: Date;
|
|
25
27
|
showFooter?: boolean;
|
|
28
|
+
/** Which day the week starts on. 0 = Sunday, 1 = Monday, etc. */
|
|
29
|
+
weekStartsOn?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
26
30
|
}
|
|
27
31
|
export interface MonthPickerProps extends Omit<InputProps, 'value' | 'onChange' | 'type' | 'suffix' | 'suffixClick'> {
|
|
28
32
|
value?: MonthSelection;
|
|
@@ -7,6 +7,8 @@ export interface NestedListItem {
|
|
|
7
7
|
children?: NestedListItem[];
|
|
8
8
|
category?: string;
|
|
9
9
|
isDragDisabled?: boolean;
|
|
10
|
+
/** Extension point for domain-specific data (e.g., column metadata) */
|
|
11
|
+
data?: Record<string, unknown>;
|
|
10
12
|
}
|
|
11
13
|
/**
|
|
12
14
|
* Selection mode for parent-child relationships in nested lists
|
|
@@ -47,6 +49,16 @@ export interface NestedListProps {
|
|
|
47
49
|
category?: string;
|
|
48
50
|
}>) => void;
|
|
49
51
|
onDragEnd?: (activeId: string, overId: string | null) => void;
|
|
52
|
+
/** Render content right after the label (e.g., sort/filter indicators) */
|
|
53
|
+
renderLabelExtras?: (item: NestedListItem, context: {
|
|
54
|
+
isLeaf: boolean;
|
|
55
|
+
level: number;
|
|
56
|
+
}) => React.ReactNode;
|
|
57
|
+
/** Render content at the end of the row (e.g., PinSwitch, legend for section headers) */
|
|
58
|
+
renderActions?: (item: NestedListItem, context: {
|
|
59
|
+
isLeaf: boolean;
|
|
60
|
+
level: number;
|
|
61
|
+
}) => React.ReactNode;
|
|
50
62
|
enableSearch?: boolean;
|
|
51
63
|
enableDragDrop?: boolean;
|
|
52
64
|
enableSelectAll?: boolean;
|
|
@@ -21,6 +21,7 @@ export interface CalendarMessages {
|
|
|
21
21
|
}
|
|
22
22
|
export interface DatePickerMessages {
|
|
23
23
|
selectDate: string;
|
|
24
|
+
selectDateRange: string;
|
|
24
25
|
selectWeek: string;
|
|
25
26
|
selectWeekRange: string;
|
|
26
27
|
selectWeeks: string;
|
|
@@ -120,6 +121,15 @@ export interface DataTableMessages {
|
|
|
120
121
|
numericM: string;
|
|
121
122
|
numericB: string;
|
|
122
123
|
numericFullPrecision: string;
|
|
124
|
+
/** Column indicator labels */
|
|
125
|
+
indicatorSort: string;
|
|
126
|
+
indicatorSearch: string;
|
|
127
|
+
indicatorSortedAriaLabel: string;
|
|
128
|
+
indicatorFilteredAriaLabel: string;
|
|
129
|
+
/** Pin switch accessibility labels */
|
|
130
|
+
pinSwitchPinnedLeft: string;
|
|
131
|
+
pinSwitchPinnedRight: string;
|
|
132
|
+
pinSwitchNotPinned: string;
|
|
123
133
|
/** Saved table views (toolbar / settings sheet) */
|
|
124
134
|
savedViewsNotApplicable: string;
|
|
125
135
|
savedViewsOpenMenu: string;
|