impact-nova 2.5.16 → 2.6.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +27 -25
- package/dist/components/data/ag-grid-react/ag-grid.types.d.ts +28 -1
- package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.d.ts +0 -3
- package/dist/components/data/ag-grid-react/cell-renderers/date-display-renderer.js +31 -38
- package/dist/components/data/ag-grid-react/cell-renderers/input-display-renderer.d.ts +1 -1
- package/dist/components/data/ag-grid-react/chat/chat-capabilities.d.ts +9 -0
- package/dist/components/data/ag-grid-react/chat/chat-capabilities.js +22 -0
- package/dist/components/data/ag-grid-react/chat/chat-column.d.ts +20 -0
- package/dist/components/data/ag-grid-react/chat/chat-column.js +81 -0
- package/dist/components/data/ag-grid-react/chat/chat-composer.d.ts +10 -0
- package/dist/components/data/ag-grid-react/chat/chat-composer.js +352 -0
- package/dist/components/data/ag-grid-react/chat/chat-constants.d.ts +17 -0
- package/dist/components/data/ag-grid-react/chat/chat-constants.js +22 -0
- package/dist/components/data/ag-grid-react/chat/chat-format.d.ts +41 -0
- package/dist/components/data/ag-grid-react/chat/chat-format.js +94 -0
- package/dist/components/data/ag-grid-react/chat/chat-host.d.ts +10 -0
- package/dist/components/data/ag-grid-react/chat/chat-host.js +651 -0
- package/dist/components/data/ag-grid-react/chat/chat-host.types.d.ts +13 -0
- package/dist/components/data/ag-grid-react/chat/chat-html.d.ts +2 -0
- package/dist/components/data/ag-grid-react/chat/chat-html.js +40 -0
- package/dist/components/data/ag-grid-react/chat/chat-identity.d.ts +13 -0
- package/dist/components/data/ag-grid-react/chat/chat-identity.js +24 -0
- package/dist/components/data/ag-grid-react/chat/chat-menu.d.ts +13 -0
- package/dist/components/data/ag-grid-react/chat/chat-menu.js +15 -0
- package/dist/components/data/ag-grid-react/chat/chat-notify.d.ts +17 -0
- package/dist/components/data/ag-grid-react/chat/chat-notify.js +124 -0
- package/dist/components/data/ag-grid-react/chat/chat-persist.d.ts +13 -0
- package/dist/components/data/ag-grid-react/chat/chat-persist.js +34 -0
- package/dist/components/data/ag-grid-react/chat/chat-priority.d.ts +13 -0
- package/dist/components/data/ag-grid-react/chat/chat-priority.js +79 -0
- package/dist/components/data/ag-grid-react/chat/chat-summaries.d.ts +2 -0
- package/dist/components/data/ag-grid-react/chat/chat-summaries.js +24 -0
- package/dist/components/data/ag-grid-react/chat/chat-thread-ui.d.ts +72 -0
- package/dist/components/data/ag-grid-react/chat/chat-thread-ui.js +713 -0
- package/dist/components/data/ag-grid-react/chat/chat-toggle.d.ts +6 -0
- package/dist/components/data/ag-grid-react/chat/chat-toggle.js +25 -0
- package/dist/components/data/ag-grid-react/chat/chat-ui-actions.d.ts +13 -0
- package/dist/components/data/ag-grid-react/chat/chat-ui-actions.js +26 -0
- package/dist/components/data/ag-grid-react/chat/chat-window.d.ts +14 -0
- package/dist/components/data/ag-grid-react/chat/chat-window.js +82 -0
- package/dist/components/data/ag-grid-react/chat/chat-workspace.d.ts +91 -0
- package/dist/components/data/ag-grid-react/chat/chat-workspace.js +555 -0
- package/dist/components/data/ag-grid-react/chat/chat.types.d.ts +319 -0
- package/dist/components/data/ag-grid-react/chat/index.d.ts +6 -0
- package/dist/components/data/ag-grid-react/chat/index.js +24 -0
- package/dist/components/data/ag-grid-react/chat.story-data.d.ts +34 -0
- package/dist/components/data/ag-grid-react/chat.story-sources.d.ts +4 -0
- package/dist/components/data/ag-grid-react/comments/assets/comments-no-results.png.js +4 -0
- package/dist/components/data/ag-grid-react/comments/comment-mode-toggle.d.ts +6 -0
- package/dist/components/data/ag-grid-react/comments/comment-mode-toggle.js +29 -0
- package/dist/components/data/ag-grid-react/comments/comments-actions-menu.d.ts +8 -0
- package/dist/components/data/ag-grid-react/comments/comments-actions-menu.js +18 -0
- package/dist/components/data/ag-grid-react/comments/comments-ag-grid-presence.d.ts +18 -0
- package/dist/components/data/ag-grid-react/comments/comments-ag-grid-presence.js +16 -0
- package/dist/components/data/ag-grid-react/comments/comments-capabilities.d.ts +11 -0
- package/dist/components/data/ag-grid-react/comments/comments-capabilities.js +26 -0
- package/dist/components/data/ag-grid-react/comments/comments-constants.d.ts +12 -0
- package/dist/components/data/ag-grid-react/comments/comments-constants.js +21 -0
- package/dist/components/data/ag-grid-react/comments/comments-format.d.ts +20 -0
- package/dist/components/data/ag-grid-react/comments/comments-format.js +49 -0
- package/dist/components/data/ag-grid-react/comments/comments-generation.d.ts +14 -0
- package/dist/components/data/ag-grid-react/comments/comments-generation.js +18 -0
- package/dist/components/data/ag-grid-react/comments/comments-host.d.ts +10 -0
- package/dist/components/data/ag-grid-react/comments/comments-host.js +343 -0
- package/dist/components/data/ag-grid-react/comments/comments-host.types.d.ts +18 -0
- package/dist/components/data/ag-grid-react/comments/comments-identity.d.ts +7 -0
- package/dist/components/data/ag-grid-react/comments/comments-identity.js +20 -0
- package/dist/components/data/ag-grid-react/comments/comments-menu.d.ts +29 -0
- package/dist/components/data/ag-grid-react/comments/comments-menu.js +35 -0
- package/dist/components/data/ag-grid-react/comments/comments-overlay-anchor.d.ts +22 -0
- package/dist/components/data/ag-grid-react/comments/comments-overlay-anchor.js +98 -0
- package/dist/components/data/ag-grid-react/comments/comments-overlay.d.ts +21 -0
- package/dist/components/data/ag-grid-react/comments/comments-overlay.js +406 -0
- package/dist/components/data/ag-grid-react/comments/comments-panel.d.ts +9 -0
- package/dist/components/data/ag-grid-react/comments/comments-panel.js +272 -0
- package/dist/components/data/ag-grid-react/comments/comments-persist.d.ts +11 -0
- package/dist/components/data/ag-grid-react/comments/comments-persist.js +19 -0
- package/dist/components/data/ag-grid-react/comments/comments-reveal.d.ts +11 -0
- package/dist/components/data/ag-grid-react/comments/comments-reveal.js +31 -0
- package/dist/components/data/ag-grid-react/comments/comments-ui-actions.d.ts +18 -0
- package/dist/components/data/ag-grid-react/comments/comments-ui-actions.js +22 -0
- package/dist/components/data/ag-grid-react/comments/comments-window.d.ts +10 -0
- package/dist/components/data/ag-grid-react/comments/comments-window.js +62 -0
- package/dist/components/data/ag-grid-react/comments/comments.types.d.ts +178 -0
- package/dist/components/data/ag-grid-react/comments/index.d.ts +5 -0
- package/dist/components/data/ag-grid-react/comments/index.js +15 -0
- package/dist/components/data/ag-grid-react/comments-cell-renderers-showcase.d.ts +25 -0
- package/dist/components/data/ag-grid-react/comments.story-data.d.ts +37 -0
- package/dist/components/data/ag-grid-react/comments.story-sources.d.ts +11 -0
- package/dist/components/data/ag-grid-react/grid-cell-address.d.ts +21 -0
- package/dist/components/data/ag-grid-react/grid-cell-address.js +21 -0
- package/dist/components/data/ag-grid-react/grid-row-reveal.d.ts +34 -0
- package/dist/components/data/ag-grid-react/grid-row-reveal.js +33 -0
- package/dist/components/data/ag-grid-react/headers/advanced-filter/advanced-filter-dialog.js +75 -65
- package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.d.ts +1 -1
- package/dist/components/data/ag-grid-react/headers/advanced-filter/column-filter-section.js +54 -54
- package/dist/components/data/ag-grid-react/headers/components/date-filter-picker.d.ts +1 -1
- package/dist/components/data/ag-grid-react/headers/header-search-input.js +122 -119
- package/dist/components/data/ag-grid-react/headers/utils/date-utils.d.ts +2 -1
- package/dist/components/data/ag-grid-react/headers/utils/date-utils.js +25 -20
- package/dist/components/data/ag-grid-react/headers/utils/filter-utils.d.ts +1 -1
- package/dist/components/data/ag-grid-react/index.d.ts +1 -1
- package/dist/components/data/ag-grid-react/index.js +481 -254
- package/dist/components/data/ag-grid-react/notes/index.d.ts +2 -0
- package/dist/components/data/ag-grid-react/notes/index.js +1 -0
- package/dist/components/data/ag-grid-react/notes/notes-ag-grid-adapter.d.ts +25 -0
- package/dist/components/data/ag-grid-react/notes/notes-ag-grid-adapter.js +32 -0
- package/dist/components/data/ag-grid-react/notes/notes-constants.d.ts +2 -0
- package/dist/components/data/ag-grid-react/notes/notes-constants.js +4 -0
- package/dist/components/data/ag-grid-react/notes/notes.types.d.ts +12 -0
- package/dist/components/data/ag-grid-react/notes.story-sources.d.ts +7 -0
- package/dist/components/data/ag-grid-react/nova-system-column.d.ts +7 -0
- package/dist/components/data/ag-grid-react/nova-system-column.js +18 -0
- package/dist/components/data/ag-grid-react/theme.js +6 -2
- package/dist/components/data/ag-grid-react/value-formatter.types.d.ts +4 -0
- package/dist/components/data/ag-grid-react/value-formatters.d.ts +0 -19
- package/dist/components/data/ag-grid-react/value-formatters.js +88 -90
- package/dist/components/data/data-table/build-column-tree-from-grid.d.ts +0 -1
- package/dist/components/data/data-table/build-column-tree-from-grid.js +49 -53
- package/dist/components/data/data-table/data-table-column-apply.d.ts +0 -2
- package/dist/components/data/data-table/data-table-column-apply.js +73 -84
- package/dist/components/data/data-table/data-table-column-def-pin.js +34 -31
- package/dist/components/data/data-table/data-table-column-list.js +64 -94
- package/dist/components/data/data-table/data-table-column-tree-cache.d.ts +6 -12
- package/dist/components/data/data-table/data-table-column-tree-cache.js +131 -250
- package/dist/components/data/data-table/data-table-context.js +5 -5
- package/dist/components/data/data-table/data-table-sheet-context.js +1 -1
- package/dist/components/data/data-table/data-table-sheet.js +2 -1
- package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.d.ts +0 -5
- package/dist/components/data/data-table/patch-column-tree-indicators-from-grid.js +11 -28
- package/dist/components/data/data-table/use-data-table-column-list-sync.d.ts +0 -10
- package/dist/components/data/data-table/use-data-table-column-list-sync.js +196 -250
- package/dist/components/data/nested-list/components/NestedListContent.d.ts +2 -10
- package/dist/components/data/nested-list/components/NestedListContent.js +138 -253
- package/dist/components/data/nested-list/components/SortableItem.d.ts +1 -2
- package/dist/components/data/nested-list/components/SortableItem.js +60 -62
- package/dist/components/data/nested-list/hooks/useNestedListDragDrop.d.ts +20 -10
- package/dist/components/data/nested-list/hooks/useNestedListDragDrop.js +233 -44
- package/dist/components/data/nested-list/nested-list-constants.d.ts +1 -4
- package/dist/components/data/nested-list/nested-list-constants.js +4 -10
- package/dist/components/data/nested-list/nested-list.js +336 -322
- package/dist/components/data/nested-list/nested-list.types.d.ts +0 -17
- package/dist/components/data-display/calendar/calendar-config.js +22 -21
- package/dist/components/data-display/calendar/calendar-day-button.js +21 -21
- package/dist/components/data-display/calendar/calendar-day-picker-view.js +36 -35
- package/dist/components/data-display/calendar/calendar-fiscal-labels.d.ts +3 -3
- package/dist/components/data-display/calendar/calendar-fiscal-labels.js +50 -62
- package/dist/components/data-display/calendar/calendar.js +138 -137
- package/dist/components/data-display/calendar/fiscal-period-caption-select.js +23 -22
- package/dist/components/data-display/calendar/use-calendar-i18n.d.ts +1 -0
- package/dist/components/data-display/calendar/use-calendar-i18n.js +10 -9
- package/dist/components/data-display/chart/chart.js +72 -72
- package/dist/components/data-display/chart/chart.utils.d.ts +1 -1
- package/dist/components/data-display/chart/chart.utils.js +40 -31
- package/dist/components/feedback/sheet/sheet.js +1 -1
- package/dist/components/feedback/toast/toast.d.ts +1 -1
- package/dist/components/feedback/toast/toast.variants.d.ts +1 -1
- package/dist/components/flows/filter-panel/filter-panel.d.ts +1 -1
- package/dist/components/flows/filter-panel/filter-panel.js +65 -64
- package/dist/components/flows/filter-panel/filter-panel.types.d.ts +1 -0
- package/dist/components/forms/date-picker/date-picker.js +125 -126
- package/dist/components/forms/date-picker/date-range-picker.js +191 -192
- package/dist/components/forms/date-picker/multi-date-picker.js +66 -67
- package/dist/components/forms/date-picker/multi-week-picker.js +82 -83
- package/dist/components/forms/date-picker/use-picker-i18n.d.ts +6 -0
- package/dist/components/forms/date-picker/use-picker-i18n.js +11 -0
- package/dist/components/forms/date-picker/week-picker.js +146 -147
- package/dist/components/forms/date-picker/week-range-picker.js +158 -159
- package/dist/components/ui/local-raster-icons/message3d.webp.js +4 -0
- package/dist/components/ui/local-raster-icons/rasterIcons.d.ts +1 -0
- package/dist/components/ui/local-raster-icons/rasterIcons.js +27 -25
- package/dist/form-react/Fields/WeekRangePicker.js +16 -16
- package/dist/i18n/defaultMessages.d.ts +144 -0
- package/dist/i18n/defaultMessages.js +161 -19
- package/dist/i18n/format/collator.d.ts +1 -0
- package/dist/i18n/format/collator.js +7 -0
- package/dist/i18n/format/date-pattern.d.ts +5 -0
- package/dist/i18n/format/date-pattern.js +20 -0
- package/dist/i18n/format/format-date.d.ts +9 -0
- package/dist/i18n/format/format-date.js +56 -0
- package/dist/i18n/format/format-number.d.ts +20 -0
- package/dist/i18n/format/format-number.js +68 -0
- package/dist/i18n/format/formatter-cache.d.ts +9 -0
- package/dist/i18n/format/formatter-cache.js +66 -0
- package/dist/i18n/format/index.d.ts +6 -0
- package/dist/i18n/format/parse-number.d.ts +6 -0
- package/dist/i18n/format/parse-number.js +53 -0
- package/dist/i18n/getDateFnsLocale.d.ts +5 -4
- package/dist/i18n/getDateFnsLocale.js +46 -16
- package/dist/i18n/i18n.types.d.ts +13 -0
- package/dist/i18n/impact-nova-i18n-context.d.ts +1 -1
- package/dist/i18n/impact-nova-i18n-context.js +33 -25
- package/dist/i18n/impact-nova-i18n-defaults.js +8 -6
- package/dist/i18n/index.d.ts +4 -1
- package/dist/i18n/index.js +41 -16
- package/dist/i18n/locale-config.d.ts +28 -0
- package/dist/i18n/locale-config.js +32 -0
- package/dist/i18n/locales/de.js +142 -0
- package/dist/i18n/locales/es.js +142 -0
- package/dist/i18n/locales/hi.js +142 -0
- package/dist/i18n/locales/kn.js +142 -0
- package/dist/i18n/week-start.d.ts +6 -0
- package/dist/i18n/week-start.js +30 -0
- package/dist/impact-nova-components.css +249 -0
- package/dist/impact-nova-tokens.scss +6 -0
- package/dist/impact-nova.css +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +624 -601
- package/dist/llms/index.js +26 -2
- package/dist/llms/rules/ag-grid.js +1 -1
- package/dist/llms/rules/best-practices.js +1 -1
- package/dist/llms/rules/data-table-chat.js +1 -0
- package/dist/llms/rules/data-table-comments.js +1 -0
- package/dist/llms/rules/data-table-notes.js +1 -0
- package/dist/llms/rules/installation.js +1 -1
- package/dist/llms/rules/migration.js +1 -1
- package/dist/llms/rules/real-world-patterns.js +1 -1
- package/dist/llms/rules/requirements.js +1 -1
- package/dist/llms/rules/troubleshooting.js +1 -1
- package/dist/providers/app-providers.d.ts +3 -1
- package/dist/providers/app-providers.js +22 -11
- package/package.json +13 -1
- package/dist/components/data/data-table/column-picker-authority.d.ts +0 -34
- package/dist/components/data/data-table/column-picker-authority.js +0 -116
- package/dist/components/data/data-table/column-picker-drop-validation.d.ts +0 -7
- package/dist/components/data/data-table/column-picker-drop-validation.js +0 -37
- package/dist/components/data/data-table/data-table-column-list-tree-apply.d.ts +0 -10
- package/dist/components/data/data-table/data-table-column-list-tree-apply.js +0 -79
- package/dist/components/data/data-table/data-table-flat-column-virtual-rows.d.ts +0 -26
- package/dist/components/data/data-table/data-table-flat-column-virtual-rows.js +0 -195
- package/dist/components/data/data-table/data-table-picker-column-eligibility.d.ts +0 -1
- package/dist/components/data/data-table/data-table-picker-column-eligibility.js +0 -7
- package/dist/components/data/data-table/reconcile-column-tree-from-grid.d.ts +0 -12
- package/dist/components/data/data-table/reconcile-column-tree-from-grid.js +0 -12
- package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.d.ts +0 -24
- package/dist/components/data/nested-list/hooks/useVirtualNestedListDrag.js +0 -128
- package/dist/components/data/nested-list/nested-list-display-utils.d.ts +0 -11
- package/dist/components/data/nested-list/nested-list-display-utils.js +0 -74
- package/dist/components/data/nested-list/nested-list-drop-engine.d.ts +0 -31
- package/dist/components/data/nested-list/nested-list-drop-engine.js +0 -209
- package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.d.ts +0 -26
- package/dist/components/data/nested-list/nested-list-flat-virtual-handlers.js +0 -67
- package/dist/components/data/nested-list/nested-list-item-tree-mutations.d.ts +0 -4
- package/dist/components/data/nested-list/nested-list-item-tree-mutations.js +0 -43
- package/dist/components/data/nested-list/nested-list-lazy-flat-rows.d.ts +0 -3
- package/dist/components/data/nested-list/nested-list-lazy-flat-rows.js +0 -34
- package/dist/components/data/nested-list/nested-list-row-estimates.d.ts +0 -9
- package/dist/components/data/nested-list/nested-list-row-estimates.js +0 -14
- package/dist/components/data/nested-list/nested-list-scroll-anchor.d.ts +0 -36
- package/dist/components/data/nested-list/nested-list-scroll-anchor.js +0 -47
- package/dist/components/data/nested-list/nested-list-virtual-drop.d.ts +0 -59
- package/dist/components/data/nested-list/nested-list-virtual-drop.js +0 -341
- package/dist/lib/hash/fnv1a128.d.ts +0 -16
- package/dist/lib/hash/fnv1a128.js +0 -21
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { CellNote, DataTableNotesConfig } from './notes.types';
|
|
2
|
+
export type NotesGetNoteParams = {
|
|
3
|
+
rowNode: {
|
|
4
|
+
id?: string | null;
|
|
5
|
+
};
|
|
6
|
+
column: {
|
|
7
|
+
getColId: () => string;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export type NotesSetNoteParams = NotesGetNoteParams & {
|
|
11
|
+
note?: CellNote | null;
|
|
12
|
+
};
|
|
13
|
+
export type NotesDataSourceAdapter = {
|
|
14
|
+
getNote: (params: NotesGetNoteParams) => CellNote | undefined;
|
|
15
|
+
setNote: (params: NotesSetNoteParams) => void;
|
|
16
|
+
};
|
|
17
|
+
export declare function noteOwnsCellPointer(notes: DataTableNotesConfig | undefined, commentMode: boolean | undefined, event: {
|
|
18
|
+
node?: {
|
|
19
|
+
id?: string | null;
|
|
20
|
+
} | null;
|
|
21
|
+
column?: {
|
|
22
|
+
getColId?: () => string;
|
|
23
|
+
} | null;
|
|
24
|
+
}): boolean;
|
|
25
|
+
export declare function createNotesDataSource(config: DataTableNotesConfig, onMissingRowId?: () => void): NotesDataSourceAdapter;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { cellAddressFromGridEvent as s } from "../grid-cell-address.js";
|
|
2
|
+
function d(e) {
|
|
3
|
+
const r = e.rowNode.id, o = e.column.getColId();
|
|
4
|
+
if (!(!r || !o))
|
|
5
|
+
return { rowId: r, colId: o };
|
|
6
|
+
}
|
|
7
|
+
function u(e, r, o) {
|
|
8
|
+
if (r || !e) return !1;
|
|
9
|
+
const t = s(o);
|
|
10
|
+
return t != null && e.getNote(t) != null;
|
|
11
|
+
}
|
|
12
|
+
function l(e, r) {
|
|
13
|
+
let o = !1;
|
|
14
|
+
return {
|
|
15
|
+
getNote(t) {
|
|
16
|
+
const n = d(t);
|
|
17
|
+
if (!n) {
|
|
18
|
+
!t.rowNode.id && !o && (o = !0, r?.());
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
return e.getNote(n);
|
|
22
|
+
},
|
|
23
|
+
setNote(t) {
|
|
24
|
+
const n = d(t);
|
|
25
|
+
n && e.setNote(n, t.note ?? void 0);
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
export {
|
|
30
|
+
l as createNotesDataSource,
|
|
31
|
+
u as noteOwnsCellPointer
|
|
32
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { GridCellAddress } from '../grid-cell-address';
|
|
2
|
+
export type CellNote = {
|
|
3
|
+
text: string;
|
|
4
|
+
readOnly?: boolean;
|
|
5
|
+
author?: string;
|
|
6
|
+
createdAt?: string;
|
|
7
|
+
updatedAt?: string;
|
|
8
|
+
};
|
|
9
|
+
export type DataTableNotesConfig = {
|
|
10
|
+
getNote: (address: GridCellAddress) => CellNote | undefined;
|
|
11
|
+
setNote: (address: GridCellAddress, note: CellNote | undefined) => void;
|
|
12
|
+
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** Copy-paste blocks for Data Display / DataTable / Notes Docs tab. */
|
|
2
|
+
export declare const NOTES_QUICK_START_SOURCE = "import { useMemo, useRef } from \"react\";\nimport { DataTable, DataTableContent } from \"impact-nova/data-table\";\nimport type { CellNote, DataTableNotesConfig, GridCellAddress } from \"impact-nova/ag-grid-react/notes\";\n\nconst store = new Map<string, CellNote>();\nfunction key(address: GridCellAddress) {\n return address.rowId + \"\\0\" + address.colId;\n}\n\nconst notes: DataTableNotesConfig = {\n getNote: (address) => store.get(key(address)),\n setNote: (address, note) => {\n if (!note) store.delete(key(address));\n else store.set(key(address), note);\n },\n};\n\n<DataTable className=\"h-[640px]\">\n <DataTableContent\n getRowId={(params) => params.data.id}\n columnDefs={columnDefs}\n rowData={rowData}\n notes={notes}\n />\n</DataTable>\n\n// Right-click \u2192 Add note. Hover a noted cell for the AG Grid note popup.\n// Identity is { rowId, colId } \u2014 not DOM, not rowIndex, not page.\n";
|
|
3
|
+
export declare const NOTES_CLIENT_PAGE_SOURCE = "import { DataTable, DataTableContent } from \"impact-nova/data-table\";\n\n<DataTableContent\n getRowId={(params) => params.data.id}\n rowData={allRows}\n columnDefs={columnDefs}\n pagination\n paginationPageSize={12}\n notes={notes}\n/>\n";
|
|
4
|
+
export declare const NOTES_SERVER_PAGE_SOURCE = "import { DataTable, DataTableContent } from \"impact-nova/data-table\";\n\n// Only the current page is in rowData. Notes live in YOUR store keyed by { rowId, colId }.\n<DataTableContent\n getRowId={(params) => params.data.id}\n rowData={pageRows}\n columnDefs={columnDefs}\n notes={notes}\n/>\n";
|
|
5
|
+
export declare const NOTES_CUSTOM_APPEARANCE_SOURCE = "import { DataTable, DataTableContent } from \"impact-nova/data-table\";\n\n<div\n className=\"h-[640px]\"\n style={{\n [\"--iv-note-indicator-color\"]: \"var(--color-destructive)\",\n [\"--iv-note-indicator-size\"]: \"12px\",\n }}\n>\n <DataTableContent getRowId={(p) => p.data.id} notes={notes} columnDefs={columnDefs} rowData={rowData} />\n</div>\n";
|
|
6
|
+
export declare const NOTES_WITH_COMMENTS_SOURCE = "import { DataTable, DataTableContent } from \"impact-nova/data-table\";\nimport type { DataTableCommentsConfig } from \"impact-nova/ag-grid-react/comments\";\nimport type { DataTableNotesConfig } from \"impact-nova/ag-grid-react/notes\";\n\n<DataTableContent\n getRowId={(params) => params.data.id}\n comments={comments}\n notes={notes}\n columnDefs={columnDefs}\n rowData={rowData}\n/>\n\n// Same cell may have both. Blue triangle = Comment. Yellow = Note. Split = both.\n// Hover opens the AG Grid note. Context menu keeps Add/Open comment and native note actions.\n";
|
|
7
|
+
export declare const NOTES_CUSTOM_WITH_COMMENTS_SOURCE = "import { DataTable, DataTableContent } from \"impact-nova/data-table\";\n\n<div\n className=\"h-[640px]\"\n style={{\n [\"--iv-comment-indicator-color\"]: \"var(--color-success)\",\n [\"--iv-note-indicator-color\"]: \"var(--color-destructive)\",\n }}\n>\n <DataTable className=\"h-full\">\n <DataTableContent\n getRowId={(p) => p.data.id}\n comments={{\n ...comments,\n messageActions: [{ id: \"open\", label: \"Open\", onSelect: ({ message }) => openRecord(message.id) }],\n }}\n notes={notes}\n columnDefs={columnDefs}\n rowData={rowData}\n />\n </DataTable>\n</div>\n";
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/** Nova-owned grid columns (`iv-chat`, …). Never persist, list, auto-size, or export these. */
|
|
2
|
+
export declare const NOVA_SYSTEM_COL_ID_PREFIX = "iv-";
|
|
3
|
+
export declare function isNovaSystemColId(colId: string | null | undefined): boolean;
|
|
4
|
+
export declare function omitNovaSystemColumnIds(colIds: readonly string[]): string[];
|
|
5
|
+
export declare function exportColumnColIds(columns: ReadonlyArray<{
|
|
6
|
+
getColId?: () => string;
|
|
7
|
+
} | null | undefined> | null | undefined): string[];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const e = "iv-";
|
|
2
|
+
function s(t) {
|
|
3
|
+
return typeof t == "string" && t.startsWith("iv-");
|
|
4
|
+
}
|
|
5
|
+
function i(t) {
|
|
6
|
+
if (!t?.length) return [];
|
|
7
|
+
const n = [];
|
|
8
|
+
for (const r of t) {
|
|
9
|
+
const o = r?.getColId?.();
|
|
10
|
+
o && !s(o) && n.push(o);
|
|
11
|
+
}
|
|
12
|
+
return n;
|
|
13
|
+
}
|
|
14
|
+
export {
|
|
15
|
+
e as NOVA_SYSTEM_COL_ID_PREFIX,
|
|
16
|
+
i as exportColumnColIds,
|
|
17
|
+
s as isNovaSystemColId
|
|
18
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { themeQuartz as
|
|
2
|
-
const d =
|
|
1
|
+
import { themeQuartz as o, iconSetMaterial as e } from "ag-grid-enterprise";
|
|
2
|
+
const d = o.withPart(e).withParams({
|
|
3
3
|
accentColor: "#4259EE",
|
|
4
4
|
backgroundColor: "#FFFFFF",
|
|
5
5
|
borderColor: "#D9DDE7",
|
|
@@ -57,6 +57,8 @@ const d = e.withPart(o).withParams({
|
|
|
57
57
|
menuBorder: !1,
|
|
58
58
|
tooltipBorder: !1,
|
|
59
59
|
pinnedRowBorder: !1,
|
|
60
|
+
noteIndicatorColor: "#E1BC29",
|
|
61
|
+
noteIndicatorSize: 12,
|
|
60
62
|
browserColorScheme: "light"
|
|
61
63
|
}, "light").withParams({
|
|
62
64
|
accentColor: "#E5E5E5",
|
|
@@ -116,6 +118,8 @@ const d = e.withPart(o).withParams({
|
|
|
116
118
|
menuBorder: !1,
|
|
117
119
|
tooltipBorder: !1,
|
|
118
120
|
pinnedRowBorder: !1,
|
|
121
|
+
noteIndicatorColor: "#F59E0B",
|
|
122
|
+
noteIndicatorSize: 12,
|
|
119
123
|
browserColorScheme: "dark"
|
|
120
124
|
}, "dark");
|
|
121
125
|
export {
|
|
@@ -6,6 +6,10 @@ export interface FormatterGridContext {
|
|
|
6
6
|
currency?: string;
|
|
7
7
|
decimals?: number;
|
|
8
8
|
locale?: string;
|
|
9
|
+
dateLocale?: string;
|
|
10
|
+
numberLocale?: string;
|
|
11
|
+
booleanYes?: string;
|
|
12
|
+
booleanNo?: string;
|
|
9
13
|
[key: string]: unknown;
|
|
10
14
|
}
|
|
11
15
|
export interface BackendFormatterConfigBase {
|
|
@@ -1,22 +1,3 @@
|
|
|
1
1
|
import { ValueFormatterParams } from 'ag-grid-community';
|
|
2
|
-
/**
|
|
3
|
-
* AG Grid value formatters registry
|
|
4
|
-
* Use with AgGridWrapper's valueFormatters prop
|
|
5
|
-
*
|
|
6
|
-
* @example
|
|
7
|
-
* ```typescript
|
|
8
|
-
* <AgGridWrapper
|
|
9
|
-
* valueFormatters={AG_GRID_VALUE_FORMATTERS}
|
|
10
|
-
* context={{ currency: 'EUR', decimals: 0 }}
|
|
11
|
-
* columnDefs={[
|
|
12
|
-
* { field: 'price', valueFormatter: 'currency' },
|
|
13
|
-
* { field: 'discount', valueFormatter: 'percentage' },
|
|
14
|
-
* ]}
|
|
15
|
-
* />
|
|
16
|
-
* ```
|
|
17
|
-
*/
|
|
18
2
|
export declare const AG_GRID_VALUE_FORMATTERS: Record<string, (params: ValueFormatterParams) => string>;
|
|
19
|
-
/**
|
|
20
|
-
* Type-safe formatter names
|
|
21
|
-
*/
|
|
22
3
|
export type AGGridFormatterName = keyof typeof AG_GRID_VALUE_FORMATTERS;
|
|
@@ -1,110 +1,108 @@
|
|
|
1
|
-
import { getBackendFormatterColDef as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
import { getBackendFormatterColDef as m, getNullDisplay as a, getFormatterConfig as S } from "./value-formatter.types.js";
|
|
2
|
+
import { DEFAULT_LOCALE as T } from "../../../i18n/locale-config.js";
|
|
3
|
+
import { formatDateTime as L, formatDate as _ } from "../../../i18n/format/format-date.js";
|
|
4
|
+
import { formatPercent as N, formatCompactNumber as b, formatNumber as d, formatCurrency as x } from "../../../i18n/format/format-number.js";
|
|
5
|
+
import { getNumberFormat as V } from "../../../i18n/format/formatter-cache.js";
|
|
6
|
+
function s(t) {
|
|
7
|
+
return t.context;
|
|
8
|
+
}
|
|
9
|
+
function g(t, e) {
|
|
10
|
+
return t || e?.numberLocale || e?.locale || T;
|
|
11
|
+
}
|
|
12
|
+
function $(t, e) {
|
|
13
|
+
return t || e?.dateLocale || e?.locale || T;
|
|
14
|
+
}
|
|
15
|
+
function D(t) {
|
|
16
|
+
return t === "thou" || t === "mil" || t === "bil" ? t : null;
|
|
17
|
+
}
|
|
18
|
+
const C = (t) => {
|
|
19
|
+
const e = S(m(t)), o = s(t);
|
|
7
20
|
if (t.value == null) return a(e, o);
|
|
8
|
-
const n = e.currency || "USD",
|
|
9
|
-
if (isNaN(
|
|
10
|
-
const
|
|
11
|
-
if (
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
currency: n
|
|
15
|
-
}).formatToParts(0).find((F) => F.type === "currency")?.value || n;
|
|
16
|
-
return `${l}${m}${u}`;
|
|
21
|
+
const n = e.currency || "USD", c = g(e.locale, o), i = o?.formatType || e.formatType, r = Number(t.value);
|
|
22
|
+
if (isNaN(r)) return String(t.value);
|
|
23
|
+
const l = D(i);
|
|
24
|
+
if (l) {
|
|
25
|
+
const u = b(Math.abs(r), c, l), y = V(c, { style: "currency", currency: n }).formatToParts(0).find((F) => F.type === "currency")?.value || n;
|
|
26
|
+
return `${r < 0 ? "-" : ""}${y}${u}`;
|
|
17
27
|
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
currency: n
|
|
25
|
-
}).format(i);
|
|
26
|
-
}, D = (t) => {
|
|
27
|
-
const e = b(s(t)), o = f(t);
|
|
28
|
+
return i === "full_precision" ? x(r, c, n, {
|
|
29
|
+
minimumFractionDigits: 2,
|
|
30
|
+
maximumFractionDigits: 20
|
|
31
|
+
}) : x(r, c, n);
|
|
32
|
+
}, h = (t) => {
|
|
33
|
+
const e = S(m(t)), o = s(t);
|
|
28
34
|
if (t.value == null) return a(e, o);
|
|
29
|
-
const n = e.symbol || "$",
|
|
30
|
-
if (isNaN(
|
|
31
|
-
const
|
|
32
|
-
let
|
|
33
|
-
return
|
|
34
|
-
minimumFractionDigits:
|
|
35
|
-
maximumFractionDigits:
|
|
36
|
-
})
|
|
37
|
-
|
|
38
|
-
|
|
35
|
+
const n = e.symbol || "$", c = e.position || "prefix", i = e.decimals ?? 2, r = g(e.locale, o), l = o?.formatType || e.formatType, u = Number(t.value);
|
|
36
|
+
if (isNaN(u)) return String(t.value);
|
|
37
|
+
const y = D(l);
|
|
38
|
+
let f;
|
|
39
|
+
return y ? f = `${u < 0 ? "-" : ""}${b(Math.abs(u), r, y)}` : l === "full_precision" ? f = d(u, r, {
|
|
40
|
+
minimumFractionDigits: i,
|
|
41
|
+
maximumFractionDigits: 20
|
|
42
|
+
}) : f = d(u, r, {
|
|
43
|
+
minimumFractionDigits: i,
|
|
44
|
+
maximumFractionDigits: i
|
|
45
|
+
}), c === "prefix" ? `${n}${f}` : `${f}${n}`;
|
|
46
|
+
}, A = (t) => {
|
|
47
|
+
const e = m(t), o = s(t);
|
|
39
48
|
if (t.value == null) return a(e, o);
|
|
40
|
-
const n = e.decimals ?? 0,
|
|
41
|
-
if (isNaN(
|
|
42
|
-
const
|
|
43
|
-
return
|
|
49
|
+
const n = e.decimals ?? 0, c = g(e.locale, o), i = o?.formatType || e.formatType, r = Number(t.value);
|
|
50
|
+
if (isNaN(r)) return String(t.value);
|
|
51
|
+
const l = D(i);
|
|
52
|
+
return l ? `${r < 0 ? "-" : ""}${b(Math.abs(r), c, l)}` : i === "full_precision" ? d(r, c, {
|
|
53
|
+
minimumFractionDigits: n,
|
|
54
|
+
maximumFractionDigits: 20
|
|
55
|
+
}) : d(r, c, {
|
|
44
56
|
minimumFractionDigits: n,
|
|
45
57
|
maximumFractionDigits: n
|
|
46
|
-
})
|
|
47
|
-
},
|
|
48
|
-
const e =
|
|
58
|
+
});
|
|
59
|
+
}, v = (t) => {
|
|
60
|
+
const e = m(t), o = s(t);
|
|
49
61
|
if (t.value == null) return a(e, o);
|
|
50
62
|
const n = Number(t.value);
|
|
51
63
|
if (isNaN(n)) return String(t.value);
|
|
52
|
-
const
|
|
53
|
-
return
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
}, $ = (t) => {
|
|
57
|
-
const e = s(t), o = f(t);
|
|
64
|
+
const c = g(e.locale, o);
|
|
65
|
+
return b(n, c, "auto");
|
|
66
|
+
}, M = (t) => {
|
|
67
|
+
const e = m(t), o = s(t);
|
|
58
68
|
if (t.value == null) return a(e, o);
|
|
59
69
|
const n = Number(t.value);
|
|
60
70
|
if (isNaN(n)) return String(t.value);
|
|
61
|
-
const
|
|
62
|
-
return
|
|
63
|
-
style: "percent",
|
|
71
|
+
const c = e.decimals ?? 2, i = e.divideBy ?? 100, r = o?.formatType || e.formatType, l = g(e.locale, o), u = n / i;
|
|
72
|
+
return r === "full_precision" ? N(u, l, {
|
|
64
73
|
minimumFractionDigits: 2,
|
|
65
74
|
maximumFractionDigits: 20
|
|
66
|
-
})
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
const e = s(t), o = f(t);
|
|
75
|
+
}) : N(u, l, {
|
|
76
|
+
minimumFractionDigits: c,
|
|
77
|
+
maximumFractionDigits: c
|
|
78
|
+
});
|
|
79
|
+
}, E = (t) => {
|
|
80
|
+
const e = m(t), o = s(t);
|
|
73
81
|
if (!t.value) return a(e, o);
|
|
74
|
-
const n = e.dateStyle || "medium",
|
|
75
|
-
return
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
}, T = (t) => {
|
|
79
|
-
const e = s(t), o = f(t);
|
|
82
|
+
const n = e.dateStyle || "medium", c = $(e.locale, o);
|
|
83
|
+
return _(t.value, c, { dateStyle: n }) || String(t.value);
|
|
84
|
+
}, B = (t) => {
|
|
85
|
+
const e = m(t), o = s(t);
|
|
80
86
|
if (!t.value) return a(e, o);
|
|
81
|
-
const n = e.dateStyle || "medium",
|
|
82
|
-
return
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
}).format(i);
|
|
86
|
-
}, w = (t) => {
|
|
87
|
-
const e = s(t), o = f(t);
|
|
87
|
+
const n = e.dateStyle || "medium", c = e.timeStyle || "short", i = $(e.locale, o);
|
|
88
|
+
return L(t.value, i, { dateStyle: n, timeStyle: c }) || String(t.value);
|
|
89
|
+
}, R = (t) => {
|
|
90
|
+
const e = m(t), o = s(t);
|
|
88
91
|
if (t.value == null) return a(e, o);
|
|
89
|
-
const n = e.trueValue || "Yes",
|
|
90
|
-
return t.value ? n :
|
|
91
|
-
},
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
// Date formatters
|
|
103
|
-
date: S,
|
|
104
|
-
dateTime: T,
|
|
105
|
-
// Boolean formatter
|
|
106
|
-
boolean: w
|
|
92
|
+
const n = e.trueValue || o?.booleanYes || "Yes", c = e.falseValue || o?.booleanNo || "No";
|
|
93
|
+
return t.value ? n : c;
|
|
94
|
+
}, Y = {
|
|
95
|
+
currency: C,
|
|
96
|
+
currencySymbol: h,
|
|
97
|
+
number: A,
|
|
98
|
+
compact: v,
|
|
99
|
+
compactNumber: v,
|
|
100
|
+
largeNumber: v,
|
|
101
|
+
percentage: M,
|
|
102
|
+
date: E,
|
|
103
|
+
dateTime: B,
|
|
104
|
+
boolean: R
|
|
107
105
|
};
|
|
108
106
|
export {
|
|
109
|
-
|
|
107
|
+
Y as AG_GRID_VALUE_FORMATTERS
|
|
110
108
|
};
|
|
@@ -4,7 +4,6 @@ export interface ColumnItemData extends Record<string, unknown> {
|
|
|
4
4
|
hasSortApplied?: boolean;
|
|
5
5
|
hasFilterApplied?: boolean;
|
|
6
6
|
pinned?: 'left' | 'right' | null;
|
|
7
|
-
columnGroupChain?: readonly string[];
|
|
8
7
|
}
|
|
9
8
|
export interface BuildColumnTreeLabels {
|
|
10
9
|
frozenColumns: string;
|
|
@@ -1,98 +1,94 @@
|
|
|
1
|
+
import { isNovaSystemColId as T } from "../ag-grid-react/nova-system-column.js";
|
|
1
2
|
import { resolveColumnPinnedFromGridState as B } from "./data-table-column-apply.js";
|
|
2
|
-
import { isPickerEligibleColumnId as E } from "./data-table-picker-column-eligibility.js";
|
|
3
3
|
function H(l) {
|
|
4
|
-
const
|
|
4
|
+
const u = [];
|
|
5
5
|
let c = l.getOriginalParent();
|
|
6
6
|
for (; c; ) {
|
|
7
|
-
const
|
|
8
|
-
|
|
7
|
+
const a = c.getColGroupDef();
|
|
8
|
+
a?.headerName && a?.children && u.push(c), c = c.getOriginalParent();
|
|
9
9
|
}
|
|
10
|
-
return
|
|
10
|
+
return u.reverse(), u;
|
|
11
11
|
}
|
|
12
|
-
function
|
|
13
|
-
const c = l.getColumnState(),
|
|
12
|
+
function K(l, u) {
|
|
13
|
+
const c = l.getColumnState(), a = l.getGridOption("context"), z = typeof a?.activeSearchColumnId == "string" ? a.activeSearchColumnId : null, _ = l.getAllGridColumns?.() ?? l.getColumns() ?? [], F = new Map(
|
|
14
14
|
_.map((e) => [e.getColId(), e])
|
|
15
|
-
),
|
|
16
|
-
|
|
15
|
+
), f = [], h = [], D = /* @__PURE__ */ new Map(), G = /* @__PURE__ */ new Map(), m = /* @__PURE__ */ new Map();
|
|
16
|
+
m.set(f, "f"), m.set(h, "s");
|
|
17
17
|
let M = 0;
|
|
18
18
|
const x = (e) => {
|
|
19
|
-
let o =
|
|
20
|
-
return o === void 0 && (o = `n${M++}`,
|
|
19
|
+
let o = m.get(e);
|
|
20
|
+
return o === void 0 && (o = `n${M++}`, m.set(e, o)), o;
|
|
21
21
|
}, O = (e, o) => {
|
|
22
|
-
const
|
|
23
|
-
if (
|
|
24
|
-
return
|
|
25
|
-
const s =
|
|
26
|
-
|
|
27
|
-
const
|
|
28
|
-
id: s === 0 ? `${
|
|
29
|
-
label:
|
|
22
|
+
const n = e.getGroupId(), i = x(o), r = `${n}::${i}`, t = D.get(r);
|
|
23
|
+
if (t && t.list === o && o[o.length - 1] === t.node)
|
|
24
|
+
return t.node;
|
|
25
|
+
const s = G.get(r) || 0;
|
|
26
|
+
G.set(r, s + 1);
|
|
27
|
+
const I = e.getColGroupDef(), d = {
|
|
28
|
+
id: s === 0 ? `${n}__${i}` : `${n}__${i}__${s}`,
|
|
29
|
+
label: I?.headerName || n,
|
|
30
30
|
checked: !0,
|
|
31
31
|
children: [],
|
|
32
32
|
category: "group"
|
|
33
33
|
};
|
|
34
|
-
return o.push(d),
|
|
34
|
+
return o.push(d), D.set(r, { list: o, node: d }), d;
|
|
35
35
|
};
|
|
36
|
-
let
|
|
36
|
+
let p = 0, S = 0, C = 0, v = 0;
|
|
37
37
|
c.forEach((e) => {
|
|
38
38
|
const o = F.get(e.colId) ?? l.getColumn(e.colId);
|
|
39
39
|
if (!o) return;
|
|
40
|
-
const
|
|
41
|
-
if (i != null && i.trim() === "" ||
|
|
40
|
+
const n = o.getColDef(), i = n.headerName;
|
|
41
|
+
if (i != null && i.trim() === "" || e.colId === "ag-Grid-SelectionColumn" || T(e.colId))
|
|
42
42
|
return;
|
|
43
|
-
const r =
|
|
44
|
-
let
|
|
45
|
-
if ((!
|
|
43
|
+
const r = n.headerName;
|
|
44
|
+
let t = typeof r == "string" && r.trim() !== "" ? r : l.getDisplayNameForColumn(o, "header");
|
|
45
|
+
if ((!t || t.trim() === "") && (t = n.field ?? e.colId), !t || t.trim() === "")
|
|
46
46
|
return;
|
|
47
|
-
const s = !e.hide,
|
|
47
|
+
const s = !e.hide, I = !!e.sort, y = o.isFilterActive() || z === e.colId, d = B(e, o), b = {
|
|
48
48
|
id: e.colId,
|
|
49
|
-
label:
|
|
49
|
+
label: t,
|
|
50
50
|
checked: s,
|
|
51
51
|
data: {
|
|
52
|
-
hasSortApplied:
|
|
53
|
-
hasFilterApplied:
|
|
52
|
+
hasSortApplied: I,
|
|
53
|
+
hasFilterApplied: y,
|
|
54
54
|
pinned: d
|
|
55
55
|
}
|
|
56
56
|
};
|
|
57
|
-
d ? (
|
|
58
|
-
const
|
|
59
|
-
if (
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
let g = w, D = null;
|
|
65
|
-
for (const T of G)
|
|
66
|
-
D = O(T, g), g = D.children;
|
|
67
|
-
D.children.push(f);
|
|
57
|
+
d ? (p++, s && S++) : (C++, s && v++);
|
|
58
|
+
const N = d ? f : h, $ = H(o);
|
|
59
|
+
if ($.length > 0) {
|
|
60
|
+
let w = N, k = null;
|
|
61
|
+
for (const P of $)
|
|
62
|
+
k = O(P, w), w = k.children;
|
|
63
|
+
k.children.push(b);
|
|
68
64
|
} else
|
|
69
|
-
|
|
65
|
+
N.push(b);
|
|
70
66
|
});
|
|
71
|
-
const
|
|
67
|
+
const g = (e) => {
|
|
72
68
|
let o = e.length > 0;
|
|
73
|
-
for (const
|
|
74
|
-
|
|
69
|
+
for (const n of e)
|
|
70
|
+
n.children && (n.checked = g(n.children)), n.checked || (o = !1);
|
|
75
71
|
return o;
|
|
76
72
|
};
|
|
77
|
-
return
|
|
73
|
+
return g(f), g(h), [
|
|
78
74
|
{
|
|
79
75
|
id: "root-frozen",
|
|
80
|
-
label:
|
|
81
|
-
checked:
|
|
82
|
-
children:
|
|
76
|
+
label: u.frozenColumns,
|
|
77
|
+
checked: p > 0 && S === p,
|
|
78
|
+
children: f,
|
|
83
79
|
category: "structure",
|
|
84
80
|
isDragDisabled: !0
|
|
85
81
|
},
|
|
86
82
|
{
|
|
87
83
|
id: "root-scrollable",
|
|
88
|
-
label:
|
|
89
|
-
checked:
|
|
90
|
-
children:
|
|
84
|
+
label: u.scrollableColumns,
|
|
85
|
+
checked: C > 0 && v === C,
|
|
86
|
+
children: h,
|
|
91
87
|
category: "structure",
|
|
92
88
|
isDragDisabled: !0
|
|
93
89
|
}
|
|
94
90
|
];
|
|
95
91
|
}
|
|
96
92
|
export {
|
|
97
|
-
|
|
93
|
+
K as buildColumnTreeFromGrid
|
|
98
94
|
};
|
|
@@ -26,8 +26,6 @@ export declare function fingerprintColumnTreeVisibility(items: NestedListItem[])
|
|
|
26
26
|
export declare function fingerprintColumnTreeItems(items: NestedListItem[]): string;
|
|
27
27
|
/** Fingerprint for sort/filter indicator badges on column-picker leaves. */
|
|
28
28
|
export declare function fingerprintColumnTreeIndicators(items: NestedListItem[]): string;
|
|
29
|
-
/** Grid-only sort/filter indicator fingerprint — no tree walk, no per-column isFilterActive. */
|
|
30
|
-
export declare function fingerprintGridColumnIndicators(gridApi: GridApi): string;
|
|
31
29
|
/**
|
|
32
30
|
* Run after `applyColumnState` returns. AG Grid applies pin/order/hide synchronously;
|
|
33
31
|
* `queueMicrotask` lets any same-turn grid events finish before we release the panel lock.
|