ia-table 0.14.3 → 0.14.5

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/pivot.d.ts CHANGED
@@ -86,6 +86,7 @@ declare const ACTION_TYPES: {
86
86
  readonly SET_HAS_SPLIT_RENDERER: "SET_HAS_SPLIT_RENDERER";
87
87
  readonly SET_HAS_SPLIT_RENDERER_KEYS: "SET_HAS_SPLIT_RENDERER_KEYS";
88
88
  readonly SET_REMOVE_SELECTION_ON_OPERATION: "SET_REMOVE_SELECTION_ON_OPERATION";
89
+ readonly SET_REMOVE_CHECK_CONFIGURATION_ON_OPERATION: "SET_REMOVE_CHECK_CONFIGURATION_ON_OPERATION";
89
90
  };
90
91
 
91
92
  declare class InfiniteBlock {
@@ -427,7 +428,7 @@ declare interface RowGroupParams {
427
428
 
428
429
  export declare type SmartGridAggregationType = "sum" | "count" | "avg" | "min" | "max";
429
430
 
430
- declare interface SmartGridAPI {
431
+ declare interface SmartGridAPI extends SmartGridPaginationAPI, SmartGridApiExtra {
431
432
  getInfiniteRowModel: () => SmartGridInfiniteRowModel | null;
432
433
  getInfiniteCache: () => SmartGridInfiniteCache | null;
433
434
  getModel: () => SmartGridTableModel;
@@ -440,10 +441,10 @@ declare interface SmartGridAPI {
440
441
  getIsSelectAllRecords: () => boolean;
441
442
  setIsSelectAllRecords: (value: boolean) => void;
442
443
  getSelectedRows: () => SmartGridRowData[];
444
+ getSelectedRowsID: () => (string | number)[];
443
445
  setSelectedRows: (rowIds: (string | number)[]) => void;
444
446
  clearSelection: () => void;
445
447
  selectAll: () => void;
446
- refreshCells: () => void;
447
448
  getCache: () => SmartGridInfiniteCache | null;
448
449
  getCacheState: () => SmartGridCacheState_2 | null;
449
450
  getInfiniteCacheInstance: () => SmartGridInfiniteCache | null;
@@ -463,7 +464,7 @@ declare interface SmartGridAPI {
463
464
  getTableWidth: () => number;
464
465
  sizeColumnsToFit: () => void;
465
466
  setRowData: (newData: SmartGridRowData[]) => boolean | void;
466
- forEachNode: (callback: (node: SmartGridRowNode, index: number) => void) => void;
467
+ forEachNode: (callback: (node: SmartGridRowNode, index: number) => void | Promise<void>) => Promise<void>;
467
468
  getColumnDefs: () => SmartGridColumnDefinition[];
468
469
  getAllColumns: () => SmartGridColumnDefinition[];
469
470
  setColumnDefs: (newColumns: SmartGridColumnDefinition) => void;
@@ -492,8 +493,11 @@ declare interface SmartGridAPI {
492
493
  applySearch: () => void;
493
494
  getCurrentPageData: () => SmartGridRowData[];
494
495
  getWholeTableData: () => SmartGridRowData[];
495
- flashCells: () => void;
496
- redrawRows: () => void;
496
+ refreshCells: (params?: SmartGridRefreshCellsParams) => void;
497
+ flashCells: (params?: SmartGridFlashCellsParams) => void;
498
+ redrawRows: (params?: SmartGridRedrawRowsParams) => void;
499
+ applyTransaction: (transaction: SmartGridRowDataTransaction) => SmartGridRowNodeTransaction;
500
+ getSelectedNodes: () => SmartGridRowNode[];
497
501
  refreshClientSideRowModel: () => void;
498
502
  resetRecentSearchChanges: () => void;
499
503
  onFilterChanged: () => void;
@@ -513,12 +517,16 @@ declare interface SmartGridAPI {
513
517
  fieldName: string;
514
518
  value: unknown;
515
519
  }) => void;
516
- setServerSideDataSource: (dataSource: SmartGridServerSideDataSource, resetCache?: boolean) => void;
520
+ setServerSideDataSource: (dataSource: SmartGridServerSideDataSource, resetCache?: boolean) => SmartGridWrappedDataSource | null;
517
521
  updateSmartGridTableData: (wholeData: SmartGridRowData[]) => void;
518
522
  downloadSmartGridExcel: (fileName?: string, visibleOnly?: boolean) => void;
519
523
  downloadSmartGridCSV: (fileName?: string, visibleOnly?: boolean) => void;
520
524
  }
521
525
 
526
+ declare type SmartGridApiExtra = {
527
+ [key: string]: unknown;
528
+ };
529
+
522
530
  declare interface SmartGridBaseColumnDefinition {
523
531
  field?: string;
524
532
  groupId?: string;
@@ -615,6 +623,7 @@ declare interface SmartGridBaseColumnDefinition {
615
623
  is_multi?: boolean;
616
624
  options_column?: string;
617
625
  aggregation_func?: SmartGridSelectOption[];
626
+ enableCommaSeparated?: boolean;
618
627
  [key: string]: unknown;
619
628
  };
620
629
  headerComponent?: default_2.FC<SmartGridHeaderStyleParams>;
@@ -938,6 +947,7 @@ declare type SmartGridCheckConfigraitonSearchField = {
938
947
  type: string;
939
948
  filterType: string;
940
949
  filter: string;
950
+ filterMax?: string;
941
951
  };
942
952
 
943
953
  declare interface SmartGridCheckConfiguration {
@@ -1034,7 +1044,7 @@ declare interface SmartGridDataSourceParams {
1034
1044
  [key: string]: unknown;
1035
1045
  }
1036
1046
 
1037
- declare type SmartGridDateFormat = "YYYY-MM-DD" | "DD-MM-YYYY" | "MM-DD-YYYY";
1047
+ declare type SmartGridDateFormat = "YYYY-MM-DD" | "DD-MM-YYYY" | "MM-DD-YYYY" | "YYYY/MM/DD" | "DD/MM/YYYY" | "MM/DD/YYYY";
1038
1048
 
1039
1049
  declare type SmartGridDefaultColDef = {
1040
1050
  minWidth: number;
@@ -1042,6 +1052,7 @@ declare type SmartGridDefaultColDef = {
1042
1052
  innerHeaderComponent: React.FC<SmartGridHeaderStyleParams> | null;
1043
1053
  };
1044
1054
  headerComponent?: React.FC<SmartGridHeaderStyleParams> | null;
1055
+ enableCellChangeFlash?: boolean;
1045
1056
  };
1046
1057
 
1047
1058
  declare type SmartGridDispatch = (action: {
@@ -1162,6 +1173,24 @@ declare interface SmartGridFilterModel {
1162
1173
  [key: string]: unknown;
1163
1174
  }
1164
1175
 
1176
+ /**
1177
+ * Parameters for flashCells API (AG Grid compatible)
1178
+ */
1179
+ declare interface SmartGridFlashCellsParams {
1180
+ /** Optional list of row nodes to flash. If not provided with columns, nothing flashes. */
1181
+ rowNodes?: SmartGridRowNode[];
1182
+ /** Optional list of column IDs to flash. If not provided with rowNodes, nothing flashes. */
1183
+ columns?: string[];
1184
+ /** Duration of the flash in milliseconds. Default: 500 */
1185
+ flashDuration?: number;
1186
+ /** Duration of the fade animation in milliseconds. Default: 500 */
1187
+ fadeDuration?: number;
1188
+ /** Custom CSS class to apply during flash */
1189
+ flashCssClass?: string;
1190
+ /** Custom CSS class to apply during fade */
1191
+ fadeCssClass?: string;
1192
+ }
1193
+
1165
1194
  declare type SmartGridFloatingType = "top" | "bottom" | null;
1166
1195
 
1167
1196
  declare interface SmartGridFocusedCell extends SmartGridSelectedCell {
@@ -1422,6 +1451,19 @@ declare interface SmartGridPageSizeRef_2 {
1422
1451
  current: number;
1423
1452
  }
1424
1453
 
1454
+ declare interface SmartGridPaginationAPI {
1455
+ paginationGetPageSize: () => number;
1456
+ paginationGetRowCount: () => number;
1457
+ paginationGetCurrentPage: () => number;
1458
+ paginationGetTotalPages: () => number;
1459
+ paginationGoToPage: (pageNumber: number) => void;
1460
+ paginationGoToFirstPage: () => void;
1461
+ paginationGoToLastPage: () => void;
1462
+ paginationGoToNextPage: () => void;
1463
+ paginationGoToPreviousPage: () => void;
1464
+ paginationIsLastPageFound: () => boolean;
1465
+ }
1466
+
1425
1467
  declare interface SmartGridPaginationModel {
1426
1468
  currentPage: number;
1427
1469
  pageSize: number;
@@ -1677,6 +1719,14 @@ declare type SmartGridRangeFilter = {
1677
1719
  operator?: string;
1678
1720
  };
1679
1721
 
1722
+ /**
1723
+ * Parameters for redrawRows API (AG Grid compatible)
1724
+ */
1725
+ declare interface SmartGridRedrawRowsParams {
1726
+ /** Optional list of row nodes to redraw. If not provided, all rows are redrawn */
1727
+ rowNodes?: SmartGridRowNode[];
1728
+ }
1729
+
1680
1730
  declare interface SmartGridRefreshCacheOptions {
1681
1731
  purge?: boolean;
1682
1732
  partialRefresh?: boolean;
@@ -1684,6 +1734,20 @@ declare interface SmartGridRefreshCacheOptions {
1684
1734
  userInitiated?: boolean;
1685
1735
  }
1686
1736
 
1737
+ /**
1738
+ * Parameters for refreshCells API (AG Grid compatible)
1739
+ */
1740
+ declare interface SmartGridRefreshCellsParams {
1741
+ /** Optional list of row nodes to refresh. If not provided, all rows are refreshed. */
1742
+ rowNodes?: SmartGridRowNode[];
1743
+ /** Optional list of column IDs to refresh. If not provided, all columns are refreshed. */
1744
+ columns?: string[];
1745
+ /** If true, forces refresh even if the cell value hasn't changed. Default: false */
1746
+ force?: boolean;
1747
+ /** If true, suppresses the flash animation. Default: false */
1748
+ suppressFlash?: boolean;
1749
+ }
1750
+
1687
1751
  declare interface SmartGridRefreshOptions {
1688
1752
  purge?: boolean;
1689
1753
  resetPage?: boolean;
@@ -1724,6 +1788,20 @@ declare interface SmartGridRowData {
1724
1788
  };
1725
1789
  }
1726
1790
 
1791
+ /**
1792
+ * Transaction object for applyTransaction API (AG Grid compatible)
1793
+ */
1794
+ declare interface SmartGridRowDataTransaction {
1795
+ /** Rows to add */
1796
+ add?: SmartGridRowData[];
1797
+ /** Index position to add rows at. If not provided, rows are added at the end */
1798
+ addIndex?: number;
1799
+ /** Rows to remove. Only the row ID field is required */
1800
+ remove?: SmartGridRowData[];
1801
+ /** Rows to update. The row ID field is used to match rows */
1802
+ update?: SmartGridRowData[];
1803
+ }
1804
+
1727
1805
  declare interface SmartGridRowDragEndParams {
1728
1806
  api: SmartGridAPI;
1729
1807
  type: "rowDragEnd";
@@ -1797,6 +1875,18 @@ declare interface SmartGridRowNode extends SmartGridUpdateData {
1797
1875
  isGroup?: () => boolean;
1798
1876
  }
1799
1877
 
1878
+ /**
1879
+ * Result of applyTransaction API (AG Grid compatible)
1880
+ */
1881
+ declare interface SmartGridRowNodeTransaction {
1882
+ /** Row nodes that were added */
1883
+ add: SmartGridRowNode[];
1884
+ /** Row nodes that were removed */
1885
+ remove: SmartGridRowNode[];
1886
+ /** Row nodes that were updated */
1887
+ update: SmartGridRowNode[];
1888
+ }
1889
+
1800
1890
  declare interface SmartGridRowSpanInfo {
1801
1891
  [key: string]: SmartGridRowInfo | boolean | undefined;
1802
1892
  isRowSpan?: boolean;
@@ -2027,6 +2117,7 @@ declare interface SmartGridStateContext {
2027
2117
  savedViewsOptions?: SmartGridSavedViewsOptions[];
2028
2118
  } & Record<string, unknown>;
2029
2119
  pivotPanelColumnDef: null | SmartGridColumnDefinition[];
2120
+ removeCheckConfigurationOnOperation: boolean;
2030
2121
  [key: string]: unknown;
2031
2122
  }
2032
2123
 
@@ -2062,7 +2153,7 @@ declare interface SmartGridTableModel {
2062
2153
  getFilterModel: () => SmartGridFilterModel;
2063
2154
  getType: () => SmartGridModelType;
2064
2155
  getRowsToDisplay: () => number;
2065
- forEachNode: (callback: (node: SmartGridRowNode, index: number) => void) => void;
2156
+ forEachNode: (callback: (node: SmartGridRowNode, index: number) => void | Promise<void>) => Promise<void>;
2066
2157
  getRowNode: (id: string | number) => SmartGridRowNode | null;
2067
2158
  getSelectedRows: () => SmartGridRowData[];
2068
2159
  getPaginationModel: () => SmartGridPaginationModel;
package/dist/pivot.js CHANGED
@@ -2,7 +2,7 @@
2
2
  import { jsxs as t, jsx as e, Fragment as Y } from "react/jsx-runtime";
3
3
  import * as j from "react";
4
4
  import q, { useState as D, useCallback as c, useMemo as V, useRef as Q, useEffect as J } from "react";
5
- import { S as X, f as He, g as k, i as ve, o as K, T as pe, B as G, n as Ze, C as U, k as ue, j as oe, M as qe, I as de, l as ee, D as Ue, m as We } from "./right-arrow-BayhBK88.js";
5
+ import { S as X, f as He, g as k, i as ve, o as K, T as pe, B as G, n as Ze, C as U, k as ue, j as oe, M as qe, I as de, l as ee, D as Ue, m as We } from "./right-arrow-DVcW5eaL.js";
6
6
  import { createPortal as Qe } from "react-dom";
7
7
  const Je = ({
8
8
  title: l,