@procore/data-table 13.2.2 → 13.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/legacy/index.d.mts +3 -3
- package/dist/legacy/index.d.ts +3 -3
- package/dist/legacy/index.js +210 -24
- package/dist/legacy/index.mjs +210 -24
- package/dist/modern/index.d.mts +3 -3
- package/dist/modern/index.d.ts +3 -3
- package/dist/modern/index.js +210 -23
- package/dist/modern/index.mjs +210 -23
- package/package.json +2 -2
package/dist/legacy/index.mjs
CHANGED
|
@@ -55291,7 +55291,7 @@ function ClientSideRowCheckbox(props) {
|
|
|
55291
55291
|
"data-qa": "rowCheckbox",
|
|
55292
55292
|
onClick: noop2,
|
|
55293
55293
|
onChange: () => {
|
|
55294
|
-
props.node.setSelected(!selected);
|
|
55294
|
+
props.node.setSelected(!selected, void 0, "checkboxSelected");
|
|
55295
55295
|
}
|
|
55296
55296
|
}
|
|
55297
55297
|
));
|
|
@@ -55331,7 +55331,13 @@ function ServerSideRowCheckbox(props) {
|
|
|
55331
55331
|
onClick: noop2,
|
|
55332
55332
|
onChange: () => {
|
|
55333
55333
|
var _a2, _b2;
|
|
55334
|
-
props.node.isSelected() ? (_a2 = tableRef == null ? void 0 : tableRef.current) == null ? void 0 : _a2.deselectRows(
|
|
55334
|
+
props.node.isSelected() ? (_a2 = tableRef == null ? void 0 : tableRef.current) == null ? void 0 : _a2.deselectRows(
|
|
55335
|
+
[props.node.id],
|
|
55336
|
+
"checkboxSelected"
|
|
55337
|
+
) : (_b2 = tableRef == null ? void 0 : tableRef.current) == null ? void 0 : _b2.selectRows(
|
|
55338
|
+
[props.node.id],
|
|
55339
|
+
"checkboxSelected"
|
|
55340
|
+
);
|
|
55335
55341
|
}
|
|
55336
55342
|
}
|
|
55337
55343
|
));
|
|
@@ -56467,8 +56473,12 @@ var GenericHeaderRenderer = (props) => {
|
|
|
56467
56473
|
if (!onSSDR || !isFirstColumn2 || !props.selectionSSREnabled) {
|
|
56468
56474
|
return;
|
|
56469
56475
|
}
|
|
56470
|
-
function updateSelectAllCheckbox() {
|
|
56471
|
-
|
|
56476
|
+
function updateSelectAllCheckbox(e) {
|
|
56477
|
+
if (e.source === "uiSelectAll") {
|
|
56478
|
+
return;
|
|
56479
|
+
}
|
|
56480
|
+
const isPagination = Boolean(props.api.paginationGetRowCount());
|
|
56481
|
+
const currentRows = getCurrentRows(props.api, isPagination);
|
|
56472
56482
|
const isAllSelected = currentRows.length && currentRows.every(isRowSelected);
|
|
56473
56483
|
const isPartialSelected = !isAllSelected && currentRows.some(isRowSelected);
|
|
56474
56484
|
if (isAllSelected) {
|
|
@@ -56485,19 +56495,36 @@ var GenericHeaderRenderer = (props) => {
|
|
|
56485
56495
|
props.api.removeEventListener(selectionChanged, updateSelectAllCheckbox);
|
|
56486
56496
|
props.api.removeEventListener(paginationChanged, updateSelectAllCheckbox);
|
|
56487
56497
|
};
|
|
56488
|
-
}, [isFirstColumn2,
|
|
56489
|
-
const toggleSelectAll = () => {
|
|
56498
|
+
}, [isFirstColumn2, props.selectionSSREnabled, props.api, onSSDR]);
|
|
56499
|
+
const toggleSelectAll = React82.useCallback(() => {
|
|
56490
56500
|
var _a2, _b, _c;
|
|
56491
56501
|
const nextSelectedState = selectAll === "all" /* All */ ? "none" /* None */ : "all" /* All */;
|
|
56492
56502
|
setSelectAll(nextSelectedState);
|
|
56493
56503
|
(_a2 = props.onSelectAll) == null ? void 0 : _a2.call(props, nextSelectedState);
|
|
56494
56504
|
const isSelectAll = nextSelectedState == "all" /* All */;
|
|
56495
56505
|
if (props.selectionSSREnabled) {
|
|
56496
|
-
|
|
56506
|
+
const isPagination = Boolean(props.api.paginationGetRowCount());
|
|
56507
|
+
const rowsIdsToSelectOrDeselect = getCurrentRows(
|
|
56508
|
+
props.api,
|
|
56509
|
+
isPagination
|
|
56510
|
+
).map((node) => node.id);
|
|
56511
|
+
isSelectAll ? (_b = tableRef == null ? void 0 : tableRef.current) == null ? void 0 : _b.selectRows(
|
|
56512
|
+
rowsIdsToSelectOrDeselect,
|
|
56513
|
+
"uiSelectAll"
|
|
56514
|
+
) : (_c = tableRef == null ? void 0 : tableRef.current) == null ? void 0 : _c.deselectRows(
|
|
56515
|
+
rowsIdsToSelectOrDeselect,
|
|
56516
|
+
"uiSelectAll"
|
|
56517
|
+
);
|
|
56497
56518
|
} else {
|
|
56498
56519
|
isSelectAll ? props.api.selectAllFiltered() : props.api.deselectAllFiltered();
|
|
56499
56520
|
}
|
|
56500
|
-
}
|
|
56521
|
+
}, [
|
|
56522
|
+
setSelectAll,
|
|
56523
|
+
selectAll,
|
|
56524
|
+
props.onSelectAll,
|
|
56525
|
+
props.selectionSSREnabled,
|
|
56526
|
+
props.api
|
|
56527
|
+
]);
|
|
56501
56528
|
return /* @__PURE__ */ React82.createElement(
|
|
56502
56529
|
Flex,
|
|
56503
56530
|
{
|
|
@@ -56533,9 +56560,7 @@ var GenericHeaderRenderer = (props) => {
|
|
|
56533
56560
|
checked: selectAll === "all" /* All */,
|
|
56534
56561
|
indeterminate: selectAll === "partial",
|
|
56535
56562
|
onClick: (e) => e.stopPropagation(),
|
|
56536
|
-
onChange:
|
|
56537
|
-
toggleSelectAll();
|
|
56538
|
-
}
|
|
56563
|
+
onChange: toggleSelectAll
|
|
56539
56564
|
}
|
|
56540
56565
|
),
|
|
56541
56566
|
/* @__PURE__ */ React82.createElement("div", { className: "ag-header-cell-label" }, /* @__PURE__ */ React82.createElement(
|
|
@@ -56607,6 +56632,20 @@ function GenericColumnGroupHeader(props) {
|
|
|
56607
56632
|
));
|
|
56608
56633
|
}
|
|
56609
56634
|
|
|
56635
|
+
// src/utils/pagination.ts
|
|
56636
|
+
var getPaginationPageStartEnd = ({
|
|
56637
|
+
activePage,
|
|
56638
|
+
items: totalItems,
|
|
56639
|
+
perPage
|
|
56640
|
+
}) => {
|
|
56641
|
+
const numPages = Math.ceil(totalItems / perPage);
|
|
56642
|
+
const actualActivePage = numPages === 0 ? 0 : activePage + 1;
|
|
56643
|
+
return {
|
|
56644
|
+
end: Math.min(actualActivePage * perPage, totalItems),
|
|
56645
|
+
start: Math.max((actualActivePage - 1) * perPage, 0)
|
|
56646
|
+
};
|
|
56647
|
+
};
|
|
56648
|
+
|
|
56610
56649
|
// src/utils/cellHelpers.tsx
|
|
56611
56650
|
function withDataTableEditor(Component4, editorType) {
|
|
56612
56651
|
return React82.forwardRef(
|
|
@@ -56688,7 +56727,7 @@ function getFrameworkComponents(headerMenuConfig, onSelectAll, selectionSSREnabl
|
|
|
56688
56727
|
DefaultFrameworkComponents["autoGroupCellRenderer"] = AutoGroupCellRenderer;
|
|
56689
56728
|
return { ...DefaultFrameworkComponents, ...customFrameworkComponents };
|
|
56690
56729
|
}
|
|
56691
|
-
function getCurrentRows(gridApi) {
|
|
56730
|
+
function getCurrentRows(gridApi, useCurrentPageOnly) {
|
|
56692
56731
|
var _a;
|
|
56693
56732
|
let currentRows = [];
|
|
56694
56733
|
if (((_a = gridApi == null ? void 0 : gridApi.getModel()) == null ? void 0 : _a.getType()) === "clientSide") {
|
|
@@ -56699,6 +56738,16 @@ function getCurrentRows(gridApi) {
|
|
|
56699
56738
|
gridApi == null ? void 0 : gridApi.forEachNode((rowNode) => {
|
|
56700
56739
|
currentRows.push(rowNode);
|
|
56701
56740
|
});
|
|
56741
|
+
if (useCurrentPageOnly) {
|
|
56742
|
+
const { start, end } = getPaginationPageStartEnd({
|
|
56743
|
+
items: (gridApi == null ? void 0 : gridApi.paginationGetRowCount()) || 0,
|
|
56744
|
+
perPage: (gridApi == null ? void 0 : gridApi.paginationGetPageSize()) || 0,
|
|
56745
|
+
activePage: (gridApi == null ? void 0 : gridApi.paginationGetCurrentPage()) || 0
|
|
56746
|
+
});
|
|
56747
|
+
return currentRows.filter(
|
|
56748
|
+
(row2) => row2.rowIndex >= start && row2.rowIndex < end
|
|
56749
|
+
);
|
|
56750
|
+
}
|
|
56702
56751
|
}
|
|
56703
56752
|
return currentRows;
|
|
56704
56753
|
}
|
|
@@ -58816,10 +58865,8 @@ var useRowSelectionState = () => {
|
|
|
58816
58865
|
}
|
|
58817
58866
|
selectionEventFunction();
|
|
58818
58867
|
gridApi == null ? void 0 : gridApi.addEventListener("selectionChanged", selectionEventFunction);
|
|
58819
|
-
gridApi == null ? void 0 : gridApi.addEventListener("paginationChanged", selectionEventFunction);
|
|
58820
58868
|
return () => {
|
|
58821
58869
|
gridApi == null ? void 0 : gridApi.removeEventListener("selectionChanged", selectionEventFunction);
|
|
58822
|
-
gridApi == null ? void 0 : gridApi.removeEventListener("paginationChanged", selectionEventFunction);
|
|
58823
58870
|
};
|
|
58824
58871
|
}, [gridApi]);
|
|
58825
58872
|
return selectedRows;
|
|
@@ -79803,6 +79850,150 @@ var is_IS_default = {
|
|
|
79803
79850
|
}
|
|
79804
79851
|
};
|
|
79805
79852
|
|
|
79853
|
+
// src/locales/ja-JP.json
|
|
79854
|
+
var ja_JP_default = {
|
|
79855
|
+
dataTable: {
|
|
79856
|
+
emptyState: {
|
|
79857
|
+
noFilteredResults: {
|
|
79858
|
+
description: "\u30B9\u30DA\u30EB\u3068\u30D5\u30A3\u30EB\u30BF\u30FC\u30AA\u30D7\u30B7\u30E7\u30F3\u3092\u78BA\u8A8D\u3059\u308B\u304B\u3001\u5225\u306E\u30AD\u30FC\u30EF\u30FC\u30C9\u3092\u691C\u7D22\u3057\u307E\u3059\u3002",
|
|
79859
|
+
title: "\u691C\u7D22\u306B\u4E00\u81F4\u3059\u308B\u9805\u76EE\u306F\u3042\u308A\u307E\u305B\u3093",
|
|
79860
|
+
itemsTitle: "\u691C\u7D22\u306B\u4E00\u81F4\u3059\u308B%{itemsLabel}\u306F\u3042\u308A\u307E\u305B\u3093"
|
|
79861
|
+
},
|
|
79862
|
+
noResults: {
|
|
79863
|
+
description: "\u30C1\u30FC\u30E0\u304C\u3053\u308C\u3089\u306E\u9805\u76EE\u3092\u4F5C\u6210\u3057\u305F\u3089\u3001\u3053\u3061\u3089\u3067\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u3059\u3002 ",
|
|
79864
|
+
title: "\u73FE\u5728\u3001\u8868\u793A\u3059\u308B\u9805\u76EE\u304C\u3042\u308A\u307E\u305B\u3093",
|
|
79865
|
+
itemsTitle: "\u73FE\u5728\u3001\u8868\u793A\u3059\u308B%{itemsLabel}\u304C\u3042\u308A\u307E\u305B\u3093",
|
|
79866
|
+
tooltip: "\u60C5\u5831\u3092%{tableName}\u306B\u8FFD\u52A0\u3059\u308B\u3068\u3001[%{featureName}]\u30DC\u30BF\u30F3\u304C\u6709\u52B9\u306B\u306A\u308A\u307E\u3059",
|
|
79867
|
+
featureFilter: "\u30D5\u30A3\u30EB\u30BF\u30FC",
|
|
79868
|
+
featureSearch: "\u691C\u7D22",
|
|
79869
|
+
featureGroupBy: "\u30B0\u30EB\u30FC\u30D7\u5316",
|
|
79870
|
+
featureConfigure: "\u69CB\u6210",
|
|
79871
|
+
tableNameFallback: "\u8868"
|
|
79872
|
+
}
|
|
79873
|
+
},
|
|
79874
|
+
bulkActions: {
|
|
79875
|
+
apply: "\u9069\u7528\u3059\u308B",
|
|
79876
|
+
bulkEdit: "\u4E00\u62EC\u7DE8\u96C6",
|
|
79877
|
+
cancel: "\u30AD\u30E3\u30F3\u30BB\u30EB",
|
|
79878
|
+
editValues: "\u5024\u3092\u7DE8\u96C6\u3059\u308B",
|
|
79879
|
+
error: "\u7533\u3057\u8A33\u3042\u308A\u307E\u305B\u3093\u304C\u3001\u9805\u76EE\u3092\u66F4\u65B0\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F\u3002\u518D\u5EA6\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002",
|
|
79880
|
+
placeholderForField: "%{fieldName}\u3092\u5165\u529B\u3059\u308B",
|
|
79881
|
+
selection: "%{count}%{number}\u3092\u9078\u629E\u3057\u307E\u3057\u305F",
|
|
79882
|
+
success: "\u9805\u76EE\u306F\u6B63\u5E38\u306B\u66F4\u65B0\u3055\u308C\u307E\u3057\u305F\u3002",
|
|
79883
|
+
one: "\u9805\u76EE",
|
|
79884
|
+
many: "\u9805\u76EE"
|
|
79885
|
+
},
|
|
79886
|
+
exporting: "\u30A8\u30AF\u30B9\u30DD\u30FC\u30C8\u4E2D...",
|
|
79887
|
+
filters: {
|
|
79888
|
+
filters: "\u30D5\u30A3\u30EB\u30BF\u30FC",
|
|
79889
|
+
moreFilters: "\u305D\u306E\u4ED6\u306E\u30D5\u30A3\u30EB\u30BF\u30FC",
|
|
79890
|
+
clearAllFilters: "\u3059\u3079\u3066\u306E\u30D5\u30A3\u30EB\u30BF\u30FC\u3092\u30AF\u30EA\u30A2",
|
|
79891
|
+
close: "\u9589\u3058\u308B",
|
|
79892
|
+
locationFilter: {
|
|
79893
|
+
selectAll: "\u3059\u3079\u3066\u3092\u9078\u629E\u3059\u308B",
|
|
79894
|
+
includeSublocations: "\u30B5\u30D6\u30ED\u30B1\u30FC\u30B7\u30E7\u30F3\u3092\u542B\u3081\u308B",
|
|
79895
|
+
searchLocations: "\u5834\u6240\u3092\u691C\u7D22",
|
|
79896
|
+
locations: "\u5834\u6240"
|
|
79897
|
+
},
|
|
79898
|
+
numberFilter: {
|
|
79899
|
+
labels: {
|
|
79900
|
+
and: "\u305D\u3057\u3066",
|
|
79901
|
+
input_placeholder: "\u5024\u3092\u5165\u529B",
|
|
79902
|
+
placeholder: "\u9805\u76EE\u3092\u9078\u629E\u3059\u308B"
|
|
79903
|
+
},
|
|
79904
|
+
options: {
|
|
79905
|
+
any_value: "\u4EFB\u610F\u306E\u5024",
|
|
79906
|
+
is_between: "\u9593\u306B\u3042\u308B",
|
|
79907
|
+
greater_than: "\u3088\u308A\u5927\u304D\u3044",
|
|
79908
|
+
greater_than_equal_to: "\u4EE5\u4E0A\u3067\u3042\u308B",
|
|
79909
|
+
less_than: "\u672A\u6E80\u3067\u3042\u308B",
|
|
79910
|
+
less_than_equal_to: "\u4EE5\u4E0B\u3067\u3059",
|
|
79911
|
+
no_value: "\u5024\u304C\u3042\u308A\u307E\u305B\u3093"
|
|
79912
|
+
}
|
|
79913
|
+
}
|
|
79914
|
+
},
|
|
79915
|
+
loading: {
|
|
79916
|
+
initial: "\u60C5\u5831\u3092\u8AAD\u307F\u8FBC\u3093\u3067\u3044\u307E\u3059\u3002",
|
|
79917
|
+
secondary: "\u60C5\u5831\u3092\u8AAD\u307F\u8FBC\u3093\u3067\u3044\u307E\u3059\u3002\u3057\u3070\u3089\u304F\u304A\u5F85\u3061\u304F\u3060\u3055\u3044\u3002"
|
|
79918
|
+
},
|
|
79919
|
+
menuOptions: {
|
|
79920
|
+
sortMenuItem: {
|
|
79921
|
+
label: "\u3053\u306E\u5217\u3067\u4E26\u3079\u66FF\u3048\u308B",
|
|
79922
|
+
sortAscItem: "\u5217\u3092\u6607\u9806\u306B\u4E26\u3079\u66FF\u3048\u308B",
|
|
79923
|
+
sortDescItem: "\u5217\u3092\u964D\u9806\u306B\u4E26\u3079\u66FF\u3048\u308B",
|
|
79924
|
+
sortResetItem: "\u5217\u306F\u4E26\u3079\u66FF\u3048\u3089\u308C\u3066\u3044\u307E\u305B\u3093"
|
|
79925
|
+
},
|
|
79926
|
+
expandAllGroups: "\u3059\u3079\u3066\u306E\u30B0\u30EB\u30FC\u30D7\u3092\u5C55\u958B\u3059\u308B",
|
|
79927
|
+
collapseAllGroups: "\u3059\u3079\u3066\u306E\u30B0\u30EB\u30FC\u30D7\u3092\u6298\u308A\u305F\u305F\u3080",
|
|
79928
|
+
pinColumn: "\u5217\u3092\u30D4\u30F3\u7559\u3081\u3059\u308B",
|
|
79929
|
+
pinLeft: "\u5DE6\u5074\u3092\u30D4\u30F3\u7559\u3081\u3059\u308B",
|
|
79930
|
+
pinRight: "\u53F3\u5074\u3092\u30D4\u30F3\u7559\u3081\u3059\u308B",
|
|
79931
|
+
noPin: "\u30D4\u30F3\u7559\u3081\u306F\u3042\u308A\u307E\u305B\u3093",
|
|
79932
|
+
autoSizeThisColumn: "\u3053\u306E\u5217\u3092\u81EA\u52D5\u30B5\u30A4\u30BA\u8ABF\u6574\u3059\u308B",
|
|
79933
|
+
autoSizeAllColumns: "\u3059\u3079\u3066\u306E\u5217\u3092\u81EA\u52D5\u30B5\u30A4\u30BA\u8ABF\u6574\u3059\u308B",
|
|
79934
|
+
resetColumns: "\u5217\u3092\u30EA\u30BB\u30C3\u30C8\u3059\u308B",
|
|
79935
|
+
unGroupBy: "{{label}}\u3067\u30B0\u30EB\u30FC\u30D7\u5316\u3092\u89E3\u9664\u3059\u308B",
|
|
79936
|
+
groupBy: "{{label}}\u3067\u30B0\u30EB\u30FC\u30D7\u5316\u3059\u308B"
|
|
79937
|
+
},
|
|
79938
|
+
grandTotals: "\u5358\u7D14\u96C6\u8A08",
|
|
79939
|
+
search: "\u691C\u7D22",
|
|
79940
|
+
subtotals: "\u5C0F\u8A08",
|
|
79941
|
+
tableSettings: {
|
|
79942
|
+
configureColumns: "\u5217\u3092\u69CB\u6210",
|
|
79943
|
+
resetToDefault: "\u3059\u3079\u3066\u3092\u8868\u793A\u3059\u308B",
|
|
79944
|
+
rowHeight: "\u5217\u306E\u9AD8\u3055",
|
|
79945
|
+
small: "\u5C0F",
|
|
79946
|
+
medium: "\u4E2D",
|
|
79947
|
+
large: "\u5927",
|
|
79948
|
+
tableSettings: "\u8868\u306E\u8A2D\u5B9A",
|
|
79949
|
+
groupBy: "\u30B0\u30EB\u30FC\u30D7\u5316:",
|
|
79950
|
+
reset: "\u30EA\u30BB\u30C3\u30C8",
|
|
79951
|
+
selectColumnGroup: "\u30B0\u30EB\u30FC\u30D7\u5316\u3059\u308B\u5217\u3092\u9078\u629E"
|
|
79952
|
+
},
|
|
79953
|
+
rowGroupToggle: {
|
|
79954
|
+
expandTierOne: "\u8868\u306E\u6700\u521D\u306E\u30B0\u30EB\u30FC\u30D7\u3092\u958B\u304D\u307E\u3059\u3002",
|
|
79955
|
+
expandAll: "\u8868\u306E\u3059\u3079\u3066\u306E\u30B0\u30EB\u30FC\u30D7\u3092\u958B\u304D\u307E\u3059\u3002",
|
|
79956
|
+
collapseAll: "\u8868\u306E\u3059\u3079\u3066\u306E\u30B0\u30EB\u30FC\u30D7\u3092\u9589\u3058\u307E\u3059\u3002"
|
|
79957
|
+
},
|
|
79958
|
+
columnGroupToggle: {
|
|
79959
|
+
collapse: "\u5217\u30B0\u30EB\u30FC\u30D7\u3092\u6298\u308A\u7573\u3080",
|
|
79960
|
+
expand: "\u5217\u30B0\u30EB\u30FC\u30D7\u3092\u5C55\u958B\u3059\u308B"
|
|
79961
|
+
},
|
|
79962
|
+
cells: {
|
|
79963
|
+
textCell: {
|
|
79964
|
+
placeholder: "\u30C6\u30AD\u30B9\u30C8\u3092\u5165\u529B\u3059\u308B"
|
|
79965
|
+
},
|
|
79966
|
+
currencyCell: {
|
|
79967
|
+
placeholder: "\u901A\u8CA8\u3092\u5165\u529B\u3059\u308B"
|
|
79968
|
+
},
|
|
79969
|
+
numberCell: {
|
|
79970
|
+
placeholder: "\u756A\u53F7\u3092\u5165\u529B\u3059\u308B"
|
|
79971
|
+
},
|
|
79972
|
+
percentCell: {
|
|
79973
|
+
placeholder: "%\u3092\u5165\u529B"
|
|
79974
|
+
},
|
|
79975
|
+
pillCell: {
|
|
79976
|
+
placeholder: "{{label}}\u3092\u9078\u629E\u3059\u308B"
|
|
79977
|
+
},
|
|
79978
|
+
selectCell: {
|
|
79979
|
+
placeholder: "{{label}}\u3092\u9078\u629E\u3059\u308B"
|
|
79980
|
+
},
|
|
79981
|
+
booleanCell: {
|
|
79982
|
+
options: {
|
|
79983
|
+
yes: "\u306F\u3044",
|
|
79984
|
+
no: "\u3044\u3044\u3048"
|
|
79985
|
+
}
|
|
79986
|
+
}
|
|
79987
|
+
},
|
|
79988
|
+
filterRenders: {
|
|
79989
|
+
dateFilter: {
|
|
79990
|
+
single: "\u5358\u72EC",
|
|
79991
|
+
range: "\u7BC4\u56F2"
|
|
79992
|
+
}
|
|
79993
|
+
}
|
|
79994
|
+
}
|
|
79995
|
+
};
|
|
79996
|
+
|
|
79806
79997
|
// src/locales/pt-BR.json
|
|
79807
79998
|
var pt_BR_default = {
|
|
79808
79999
|
dataTable: {
|
|
@@ -80247,6 +80438,7 @@ var translations = {
|
|
|
80247
80438
|
"fr-CA": fr_CA_default,
|
|
80248
80439
|
"fr-FR": fr_FR_default,
|
|
80249
80440
|
"is-IS": is_IS_default,
|
|
80441
|
+
"ja-JP": ja_JP_default,
|
|
80250
80442
|
"pt-BR": pt_BR_default,
|
|
80251
80443
|
"th-TH": th_TH_default,
|
|
80252
80444
|
"zh-SG": zh_SG_default
|
|
@@ -80856,24 +81048,24 @@ var useTableApi = ({
|
|
|
80856
81048
|
});
|
|
80857
81049
|
};
|
|
80858
81050
|
const selectRows = React82.useCallback(
|
|
80859
|
-
(rowIds) => {
|
|
81051
|
+
(rowIds, source) => {
|
|
80860
81052
|
rowIds == null ? void 0 : rowIds.forEach((id) => {
|
|
80861
81053
|
const rowNode = gridApi == null ? void 0 : gridApi.getRowNode(id.toString());
|
|
80862
81054
|
if (!rowNode)
|
|
80863
81055
|
return;
|
|
80864
|
-
rowNode.setSelected(true);
|
|
81056
|
+
rowNode.setSelected(true, void 0, source);
|
|
80865
81057
|
onSelectionChanged(rowNode);
|
|
80866
81058
|
});
|
|
80867
81059
|
},
|
|
80868
81060
|
[gridApi]
|
|
80869
81061
|
);
|
|
80870
81062
|
const deselectRows = React82.useCallback(
|
|
80871
|
-
(rowIds) => {
|
|
81063
|
+
(rowIds, source) => {
|
|
80872
81064
|
rowIds == null ? void 0 : rowIds.forEach((id) => {
|
|
80873
81065
|
const rowNode = gridApi == null ? void 0 : gridApi.getRowNode(id.toString());
|
|
80874
81066
|
if (!rowNode)
|
|
80875
81067
|
return;
|
|
80876
|
-
rowNode.setSelected(false);
|
|
81068
|
+
rowNode.setSelected(false, void 0, source);
|
|
80877
81069
|
onSelectionChanged(rowNode);
|
|
80878
81070
|
});
|
|
80879
81071
|
},
|
|
@@ -82256,19 +82448,13 @@ var TablePagination = ({
|
|
|
82256
82448
|
page: 0,
|
|
82257
82449
|
items: 0
|
|
82258
82450
|
});
|
|
82259
|
-
const { rowSelectionRef } = useInternalTableContext();
|
|
82260
82451
|
React82.useEffect(() => {
|
|
82261
82452
|
function onPaginationChanged(params) {
|
|
82262
|
-
var _a;
|
|
82263
82453
|
if (gridApi && params.api.paginationGetCurrentPage() !== pagination.page || pagination.items !== params.api.paginationGetRowCount()) {
|
|
82264
82454
|
setPagination({
|
|
82265
82455
|
page: params.api.paginationGetCurrentPage(),
|
|
82266
82456
|
items: params.api.paginationGetRowCount()
|
|
82267
82457
|
});
|
|
82268
|
-
if (params.api.getModel().getType() === "serverSide") {
|
|
82269
|
-
((_a = rowSelectionRef == null ? void 0 : rowSelectionRef.current) == null ? void 0 : _a.affectedRows) && (rowSelectionRef.current.affectedRows = {});
|
|
82270
|
-
gridApi == null ? void 0 : gridApi.deselectAll();
|
|
82271
|
-
}
|
|
82272
82458
|
}
|
|
82273
82459
|
}
|
|
82274
82460
|
gridApi == null ? void 0 : gridApi.addEventListener("paginationChanged", onPaginationChanged);
|
package/dist/modern/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _ag_grid_community_core from '@ag-grid-community/core';
|
|
2
|
-
import { ICellRendererParams, NumberFilterModel as NumberFilterModel$1, ColDef, IRowNode, ICellEditorParams, RowDataTransaction, RowNodeTransaction, ServerSideTransaction, GridApi, ICellEditor, RefreshCellsParams, RowNode as RowNode$1, Column, ColumnPinnedType, RowHeightParams, CheckboxSelectionCallbackParams, ExcelDataType, RowGroupOpenedEvent, Module, RowSelectedEvent, ColumnEverythingChangedEvent, GetRowIdParams, ColumnApi, IFilter, IScalarFilterParams, ISimpleFilterParams } from '@ag-grid-community/core';
|
|
2
|
+
import { ICellRendererParams, NumberFilterModel as NumberFilterModel$1, ColDef, IRowNode, ICellEditorParams, RowDataTransaction, RowNodeTransaction, ServerSideTransaction, GridApi, ICellEditor, RefreshCellsParams, RowNode as RowNode$1, Column, SelectionEventSourceType, ColumnPinnedType, RowHeightParams, CheckboxSelectionCallbackParams, ExcelDataType, RowGroupOpenedEvent, Module, RowSelectedEvent, ColumnEverythingChangedEvent, GetRowIdParams, ColumnApi, IFilter, IScalarFilterParams, ISimpleFilterParams } from '@ag-grid-community/core';
|
|
3
3
|
import * as React$1 from 'react';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
import { AgGridReactProps, AgReactUiProps } from '@ag-grid-community/react';
|
|
@@ -588,13 +588,13 @@ interface TableApi {
|
|
|
588
588
|
* The row node ID is the one you provide from the callback `getRowId(data)`,
|
|
589
589
|
* otherwise the ID is a number auto-generated by the grid when the row data is set.
|
|
590
590
|
*/
|
|
591
|
-
selectRows: (rowIds: (string | number)[]) => void;
|
|
591
|
+
selectRows: (rowIds: (string | number)[], source?: SelectionEventSourceType) => void;
|
|
592
592
|
/**
|
|
593
593
|
* Deselects row nodes by their respective row node IDs.
|
|
594
594
|
* The row node ID is the one you provide from the callback `getRowId(data)`,
|
|
595
595
|
* otherwise the ID is a number auto-generated by the grid when the row data is set.
|
|
596
596
|
*/
|
|
597
|
-
deselectRows: (rowIds: (string | number)[]) => void;
|
|
597
|
+
deselectRows: (rowIds: (string | number)[], source?: SelectionEventSourceType) => void;
|
|
598
598
|
/**
|
|
599
599
|
* Set a function determining if selection is enabled for each row as it's loaded into the table.
|
|
600
600
|
* Note: Changing this will not affect existing rows that have already been loaded. Additionally,
|
package/dist/modern/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _ag_grid_community_core from '@ag-grid-community/core';
|
|
2
|
-
import { ICellRendererParams, NumberFilterModel as NumberFilterModel$1, ColDef, IRowNode, ICellEditorParams, RowDataTransaction, RowNodeTransaction, ServerSideTransaction, GridApi, ICellEditor, RefreshCellsParams, RowNode as RowNode$1, Column, ColumnPinnedType, RowHeightParams, CheckboxSelectionCallbackParams, ExcelDataType, RowGroupOpenedEvent, Module, RowSelectedEvent, ColumnEverythingChangedEvent, GetRowIdParams, ColumnApi, IFilter, IScalarFilterParams, ISimpleFilterParams } from '@ag-grid-community/core';
|
|
2
|
+
import { ICellRendererParams, NumberFilterModel as NumberFilterModel$1, ColDef, IRowNode, ICellEditorParams, RowDataTransaction, RowNodeTransaction, ServerSideTransaction, GridApi, ICellEditor, RefreshCellsParams, RowNode as RowNode$1, Column, SelectionEventSourceType, ColumnPinnedType, RowHeightParams, CheckboxSelectionCallbackParams, ExcelDataType, RowGroupOpenedEvent, Module, RowSelectedEvent, ColumnEverythingChangedEvent, GetRowIdParams, ColumnApi, IFilter, IScalarFilterParams, ISimpleFilterParams } from '@ag-grid-community/core';
|
|
3
3
|
import * as React$1 from 'react';
|
|
4
4
|
import React__default from 'react';
|
|
5
5
|
import { AgGridReactProps, AgReactUiProps } from '@ag-grid-community/react';
|
|
@@ -588,13 +588,13 @@ interface TableApi {
|
|
|
588
588
|
* The row node ID is the one you provide from the callback `getRowId(data)`,
|
|
589
589
|
* otherwise the ID is a number auto-generated by the grid when the row data is set.
|
|
590
590
|
*/
|
|
591
|
-
selectRows: (rowIds: (string | number)[]) => void;
|
|
591
|
+
selectRows: (rowIds: (string | number)[], source?: SelectionEventSourceType) => void;
|
|
592
592
|
/**
|
|
593
593
|
* Deselects row nodes by their respective row node IDs.
|
|
594
594
|
* The row node ID is the one you provide from the callback `getRowId(data)`,
|
|
595
595
|
* otherwise the ID is a number auto-generated by the grid when the row data is set.
|
|
596
596
|
*/
|
|
597
|
-
deselectRows: (rowIds: (string | number)[]) => void;
|
|
597
|
+
deselectRows: (rowIds: (string | number)[], source?: SelectionEventSourceType) => void;
|
|
598
598
|
/**
|
|
599
599
|
* Set a function determining if selection is enabled for each row as it's loaded into the table.
|
|
600
600
|
* Note: Changing this will not affect existing rows that have already been loaded. Additionally,
|