@procore/data-table 14.28.0-cdn.0 → 14.28.0-cdn.10
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 +14 -1
- package/dist/legacy/index.cjs +158 -69
- package/dist/legacy/index.d.cts +1 -0
- package/dist/legacy/index.d.ts +1 -0
- package/dist/legacy/index.js +159 -70
- package/dist/modern/index.cjs +158 -66
- package/dist/modern/index.d.cts +1 -0
- package/dist/modern/index.d.ts +1 -0
- package/dist/modern/index.js +159 -67
- package/package.json +3 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
-
##
|
|
3
|
+
## 14.28.0-cdn.10
|
|
4
4
|
|
|
5
5
|
### Minor Changes
|
|
6
6
|
|
|
@@ -12,6 +12,19 @@
|
|
|
12
12
|
- Updated dependencies [8baa7c3]
|
|
13
13
|
- @procore/core-react@12.21.0-cdn.0
|
|
14
14
|
|
|
15
|
+
## 14.28.0
|
|
16
|
+
|
|
17
|
+
### Minor Changes
|
|
18
|
+
|
|
19
|
+
- e6586a3: If a row is not selectable, make isRowSelected = false
|
|
20
|
+
- 92682a0: Fix: ensure "Select All" checkbox stays visible and functional when the first column is hidden
|
|
21
|
+
- 3f72970: Add placeholder implementation for MultiSelectCellRenderer component
|
|
22
|
+
- 89c28a0: Prevent infinite requests when getRowId returns duplicate IDs in ServerSideDataTable.
|
|
23
|
+
|
|
24
|
+
### Patch Changes
|
|
25
|
+
|
|
26
|
+
- 5d92cf2: Fix Misalignment in Table Headers with Nested Column Definitions
|
|
27
|
+
|
|
15
28
|
## 14.27.1
|
|
16
29
|
|
|
17
30
|
### Patch Changes
|
package/dist/legacy/index.cjs
CHANGED
|
@@ -1424,7 +1424,7 @@ ag-grid, ag-grid-angular, ag-grid-ng2, ag-grid-polymer, ag-grid-aurelia {
|
|
|
1424
1424
|
animation-iteration-count: infinite;
|
|
1425
1425
|
animation-name: ag-shake-left-to-right;
|
|
1426
1426
|
}
|
|
1427
|
-
@keyframes _ag-shake-left-to-
|
|
1427
|
+
@keyframes _ag-shake-left-to-right_if78k_369 {
|
|
1428
1428
|
from {
|
|
1429
1429
|
padding-left: 6px;
|
|
1430
1430
|
padding-right: 2px;
|
|
@@ -5425,7 +5425,7 @@ input[class^=ag-][type=button]:focus, button[class^=ag-]:focus {
|
|
|
5425
5425
|
animation-iteration-count: infinite;
|
|
5426
5426
|
animation-timing-function: linear;
|
|
5427
5427
|
}
|
|
5428
|
-
@keyframes
|
|
5428
|
+
@keyframes _spin_if78k_1 {
|
|
5429
5429
|
from {
|
|
5430
5430
|
transform: rotate(0deg);
|
|
5431
5431
|
}
|
|
@@ -7680,6 +7680,9 @@ input[class^=ag-][type=range]:disabled {
|
|
|
7680
7680
|
.ag-theme-alpine.ag-theme-alpine .ag-icon-tree-open::before {
|
|
7681
7681
|
content: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='8px' height='4px'><path d='M0 0H8L4 4L0 0Z' fill='%232066DF'/></svg>");
|
|
7682
7682
|
}
|
|
7683
|
+
.ag-theme-alpine.ag-theme-alpine .ag-header-cell-resize {
|
|
7684
|
+
right: -5px;
|
|
7685
|
+
}
|
|
7683
7686
|
.ag-theme-alpine.ag-theme-alpine .ag-header-cell-resize::after {
|
|
7684
7687
|
width: 1px;
|
|
7685
7688
|
height: 100%;
|
|
@@ -7933,7 +7936,7 @@ input[class^=ag-][type=range]:disabled {
|
|
|
7933
7936
|
padding-left: 16px;
|
|
7934
7937
|
}
|
|
7935
7938
|
|
|
7936
|
-
div.
|
|
7939
|
+
div._contextPanel_if78k_7159 {
|
|
7937
7940
|
width: 400px;
|
|
7938
7941
|
transition: all ease 500ms;
|
|
7939
7942
|
flex: 0 0 auto;
|
|
@@ -7942,7 +7945,7 @@ div._contextPanel_1ajw9_7156 {
|
|
|
7942
7945
|
border: 1px solid #d6dadc;
|
|
7943
7946
|
display: flex;
|
|
7944
7947
|
}
|
|
7945
|
-
div._contextPanel--
|
|
7948
|
+
div._contextPanel--hidden_if78k_7168 {
|
|
7946
7949
|
border: none;
|
|
7947
7950
|
overflow: hidden;
|
|
7948
7951
|
padding: 0px;
|
|
@@ -7950,50 +7953,50 @@ div._contextPanel--hidden_1ajw9_7165 {
|
|
|
7950
7953
|
width: 0px;
|
|
7951
7954
|
}
|
|
7952
7955
|
|
|
7953
|
-
.
|
|
7956
|
+
._contextPanelWrapper_if78k_7176 {
|
|
7954
7957
|
position: relative;
|
|
7955
7958
|
flex-grow: 1;
|
|
7956
7959
|
}
|
|
7957
7960
|
|
|
7958
|
-
.
|
|
7961
|
+
._contextPanelBody_if78k_7181 {
|
|
7959
7962
|
width: clamp(380px, 400px, 100%);
|
|
7960
7963
|
}
|
|
7961
7964
|
|
|
7962
|
-
._contextPanel-
|
|
7965
|
+
._contextPanel-stickyHeader_if78k_7185 {
|
|
7963
7966
|
background-color: #ffffff;
|
|
7964
7967
|
position: sticky;
|
|
7965
7968
|
top: 0;
|
|
7966
7969
|
z-index: 5;
|
|
7967
7970
|
}
|
|
7968
7971
|
|
|
7969
|
-
._filters-
|
|
7972
|
+
._filters-list_if78k_7192 {
|
|
7970
7973
|
padding: 0;
|
|
7971
7974
|
margin: 0;
|
|
7972
7975
|
}
|
|
7973
|
-
._filters-
|
|
7976
|
+
._filters-list_if78k_7192 ol {
|
|
7974
7977
|
padding: 0;
|
|
7975
7978
|
margin: 0;
|
|
7976
7979
|
}
|
|
7977
7980
|
|
|
7978
|
-
._col-drag-column-
|
|
7981
|
+
._col-drag-column-icon_if78k_7201 {
|
|
7979
7982
|
color: #6a767c;
|
|
7980
7983
|
}
|
|
7981
7984
|
|
|
7982
|
-
._tabular-
|
|
7985
|
+
._tabular-nums_if78k_7205 {
|
|
7983
7986
|
font-variant-numeric: tabular-nums;
|
|
7984
7987
|
}`;
|
|
7985
7988
|
document.head.appendChild(document.createElement("style")).appendChild(document.createTextNode(css));
|
|
7986
7989
|
var styles_default = {
|
|
7987
|
-
"contextPanel": "
|
|
7988
|
-
"contextPanel--hidden": "_contextPanel--
|
|
7989
|
-
"contextPanelWrapper": "
|
|
7990
|
-
"contextPanelBody": "
|
|
7991
|
-
"contextPanel-stickyHeader": "_contextPanel-
|
|
7992
|
-
"filters-list": "_filters-
|
|
7993
|
-
"col-drag-column-icon": "_col-drag-column-
|
|
7994
|
-
"tabular-nums": "_tabular-
|
|
7995
|
-
"ag-shake-left-to-right": "_ag-shake-left-to-
|
|
7996
|
-
"spin": "
|
|
7990
|
+
"contextPanel": "_contextPanel_if78k_7159",
|
|
7991
|
+
"contextPanel--hidden": "_contextPanel--hidden_if78k_7168",
|
|
7992
|
+
"contextPanelWrapper": "_contextPanelWrapper_if78k_7176",
|
|
7993
|
+
"contextPanelBody": "_contextPanelBody_if78k_7181",
|
|
7994
|
+
"contextPanel-stickyHeader": "_contextPanel-stickyHeader_if78k_7185",
|
|
7995
|
+
"filters-list": "_filters-list_if78k_7192",
|
|
7996
|
+
"col-drag-column-icon": "_col-drag-column-icon_if78k_7201",
|
|
7997
|
+
"tabular-nums": "_tabular-nums_if78k_7205",
|
|
7998
|
+
"ag-shake-left-to-right": "_ag-shake-left-to-right_if78k_369",
|
|
7999
|
+
"spin": "_spin_if78k_1"
|
|
7997
8000
|
};
|
|
7998
8001
|
|
|
7999
8002
|
// src/utils/getCellValueTypographyProps.ts
|
|
@@ -54371,6 +54374,9 @@ function useFilterState({
|
|
|
54371
54374
|
},
|
|
54372
54375
|
[gridApi]
|
|
54373
54376
|
);
|
|
54377
|
+
const filterableColumns = React80__default.default.useMemo(() => {
|
|
54378
|
+
return columnDefinitions.filter((colDef) => !!colDef.filterRenderer).sort(sortColumnDefinitionsByFilterIndex);
|
|
54379
|
+
}, [columnDefinitions]);
|
|
54374
54380
|
const getFieldFilters = React80__default.default.useCallback(() => {
|
|
54375
54381
|
return filterableColumns.map((column2) => {
|
|
54376
54382
|
const filterInstance = getFieldFilter(column2.field);
|
|
@@ -54384,10 +54390,7 @@ function useFilterState({
|
|
|
54384
54390
|
...instanceOptions
|
|
54385
54391
|
};
|
|
54386
54392
|
}).filter((filter) => filter.instance !== void 0);
|
|
54387
|
-
}, [getFieldFilter, gridApi]);
|
|
54388
|
-
const filterableColumns = React80__default.default.useMemo(() => {
|
|
54389
|
-
return columnDefinitions.filter((colDef) => !!colDef.filterRenderer).sort(sortColumnDefinitionsByFilterIndex);
|
|
54390
|
-
}, [columnDefinitions]);
|
|
54393
|
+
}, [getFieldFilter, gridApi, filterableColumns]);
|
|
54391
54394
|
const filterEventFunction = function filterEventFunction2() {
|
|
54392
54395
|
if (listenersEnabled.current) {
|
|
54393
54396
|
const allFilters = getFieldFilters();
|
|
@@ -54503,6 +54506,10 @@ function ClientSideMultiSelectFilterRenderer({
|
|
|
54503
54506
|
value = [],
|
|
54504
54507
|
...props
|
|
54505
54508
|
}) {
|
|
54509
|
+
const filterOptions = React80__default.default.useMemo(
|
|
54510
|
+
() => (options ?? []).map((option) => option ?? ""),
|
|
54511
|
+
[options]
|
|
54512
|
+
);
|
|
54506
54513
|
return /* @__PURE__ */ React80__default.default.createElement(
|
|
54507
54514
|
coreReact.MultiSelect,
|
|
54508
54515
|
{
|
|
@@ -54518,8 +54525,8 @@ function ClientSideMultiSelectFilterRenderer({
|
|
|
54518
54525
|
return getLabel((_a = columnDefinition.filterProps) == null ? void 0 : _a.getLabel, option);
|
|
54519
54526
|
},
|
|
54520
54527
|
onChange,
|
|
54521
|
-
options,
|
|
54522
|
-
value: ramda.intersection(value || [],
|
|
54528
|
+
options: filterOptions,
|
|
54529
|
+
value: ramda.intersection(value || [], filterOptions)
|
|
54523
54530
|
}
|
|
54524
54531
|
);
|
|
54525
54532
|
}
|
|
@@ -57255,7 +57262,7 @@ var SortComponent = (props) => {
|
|
|
57255
57262
|
return null;
|
|
57256
57263
|
};
|
|
57257
57264
|
var isRowSelected = (rowNode) => {
|
|
57258
|
-
return Boolean(rowNode.selectable ? rowNode.isSelected() :
|
|
57265
|
+
return Boolean(rowNode.selectable ? rowNode.isSelected() : false);
|
|
57259
57266
|
};
|
|
57260
57267
|
var GenericHeaderRenderer = (props) => {
|
|
57261
57268
|
var _a;
|
|
@@ -57311,22 +57318,26 @@ var GenericHeaderRenderer = (props) => {
|
|
|
57311
57318
|
}, []);
|
|
57312
57319
|
React80__default.default.useEffect(() => {
|
|
57313
57320
|
function calculatePosition() {
|
|
57314
|
-
const
|
|
57315
|
-
if (!(
|
|
57321
|
+
const visibleColumns = props.columnApi.getAllDisplayedColumns();
|
|
57322
|
+
if (!(visibleColumns == null ? void 0 : visibleColumns.length))
|
|
57316
57323
|
return;
|
|
57317
|
-
|
|
57318
|
-
|
|
57319
|
-
setIsFirstColumn(true);
|
|
57320
|
-
} else {
|
|
57321
|
-
setIsFirstColumn(false);
|
|
57322
|
-
}
|
|
57324
|
+
const isCurrentFirst = visibleColumns[0].getColId() === colId;
|
|
57325
|
+
setIsFirstColumn(isCurrentFirst);
|
|
57323
57326
|
}
|
|
57324
57327
|
props.api.addEventListener("columnMoved", calculatePosition);
|
|
57328
|
+
props.api.addEventListener("columnPinned", calculatePosition);
|
|
57329
|
+
props.api.addEventListener("columnVisible", calculatePosition);
|
|
57325
57330
|
calculatePosition();
|
|
57326
57331
|
return () => {
|
|
57327
57332
|
removeEventListenerFromGrid("columnMoved", calculatePosition, props.api);
|
|
57333
|
+
removeEventListenerFromGrid("columnPinned", calculatePosition, props.api);
|
|
57334
|
+
removeEventListenerFromGrid(
|
|
57335
|
+
"columnVisible",
|
|
57336
|
+
calculatePosition,
|
|
57337
|
+
props.api
|
|
57338
|
+
);
|
|
57328
57339
|
};
|
|
57329
|
-
}, []);
|
|
57340
|
+
}, [colId, props.api]);
|
|
57330
57341
|
const onSortToggled = (event) => {
|
|
57331
57342
|
var _a2, _b, _c;
|
|
57332
57343
|
let currentSort = null;
|
|
@@ -57544,7 +57555,7 @@ var GenericHeaderRenderer = (props) => {
|
|
|
57544
57555
|
}
|
|
57545
57556
|
function updateSelectAllCheckbox(e) {
|
|
57546
57557
|
var _a2;
|
|
57547
|
-
if (e.source === "uiSelectAll") {
|
|
57558
|
+
if (e && e.source === "uiSelectAll") {
|
|
57548
57559
|
return;
|
|
57549
57560
|
}
|
|
57550
57561
|
const selectionState = props.api.getServerSideSelectionState();
|
|
@@ -57557,7 +57568,10 @@ var GenericHeaderRenderer = (props) => {
|
|
|
57557
57568
|
);
|
|
57558
57569
|
const isPagination = Boolean(props.api.paginationGetRowCount());
|
|
57559
57570
|
const currentRows = getCurrentRows(props.api, isPagination);
|
|
57560
|
-
const
|
|
57571
|
+
const selectableRows = currentRows.filter(
|
|
57572
|
+
(rowNode) => rowNode.selectable
|
|
57573
|
+
);
|
|
57574
|
+
const isAllSelected = isPagination ? selectableRows.length > 0 && selectableRows.every(isRowSelected) : isSelectionStateSelectAll;
|
|
57561
57575
|
const isPartialSelected = isPagination ? !isAllSelected && currentRows.some(isRowSelected) : isSelectionStatePartialSelected;
|
|
57562
57576
|
if (isAllSelected) {
|
|
57563
57577
|
setSelectAll("all" /* All */);
|
|
@@ -57569,6 +57583,7 @@ var GenericHeaderRenderer = (props) => {
|
|
|
57569
57583
|
}
|
|
57570
57584
|
props.api.addEventListener(selectionChanged, updateSelectAllCheckbox);
|
|
57571
57585
|
props.api.addEventListener(paginationChanged, updateSelectAllCheckbox);
|
|
57586
|
+
updateSelectAllCheckbox();
|
|
57572
57587
|
return () => {
|
|
57573
57588
|
removeEventListenerFromGrid(
|
|
57574
57589
|
selectionChanged,
|
|
@@ -57806,6 +57821,11 @@ function getGroupNodes(params) {
|
|
|
57806
57821
|
function CustomLoader(params) {
|
|
57807
57822
|
const I18n = coreReact.useI18nContext();
|
|
57808
57823
|
const groupNodes = getGroupNodes(params);
|
|
57824
|
+
const internalTableContext = useInternalTableContext();
|
|
57825
|
+
const hasDuplicateRowIds = internalTableContext.hasDuplicateRowIds ?? false;
|
|
57826
|
+
if (hasDuplicateRowIds) {
|
|
57827
|
+
return null;
|
|
57828
|
+
}
|
|
57809
57829
|
if (params.node === groupNodes.firstLoading) {
|
|
57810
57830
|
return /* @__PURE__ */ React80__default.default.createElement(coreReact.Flex, { style: { paddingLeft: "16px" } }, /* @__PURE__ */ React80__default.default.createElement(
|
|
57811
57831
|
LevelIndents,
|
|
@@ -58513,7 +58533,8 @@ var InternalTableContext = React80__default.default.createContext({
|
|
|
58513
58533
|
},
|
|
58514
58534
|
totalRowCount: 0,
|
|
58515
58535
|
setTotalRowCount: () => {
|
|
58516
|
-
}
|
|
58536
|
+
},
|
|
58537
|
+
hasDuplicateRowIds: false
|
|
58517
58538
|
});
|
|
58518
58539
|
var useInternalTableContext = () => React80__default.default.useContext(InternalTableContext);
|
|
58519
58540
|
var prng = ulid$1.detectPrng(true);
|
|
@@ -105759,6 +105780,9 @@ var de_DE_default = {
|
|
|
105759
105780
|
selectCell: {
|
|
105760
105781
|
placeholder: "{{label}} ausw\xE4hlen"
|
|
105761
105782
|
},
|
|
105783
|
+
multiSelectCell: {
|
|
105784
|
+
placeholder: "Werte ausw\xE4hlen"
|
|
105785
|
+
},
|
|
105762
105786
|
booleanCell: {
|
|
105763
105787
|
options: {
|
|
105764
105788
|
yes: "Ja",
|
|
@@ -105824,7 +105848,7 @@ var en_AU_default = {
|
|
|
105824
105848
|
close: "Close",
|
|
105825
105849
|
locationFilter: {
|
|
105826
105850
|
selectAll: "Select all",
|
|
105827
|
-
includeSublocations: "Include
|
|
105851
|
+
includeSublocations: "Include sub-locations",
|
|
105828
105852
|
searchLocations: "Search locations",
|
|
105829
105853
|
locations: "Locations"
|
|
105830
105854
|
},
|
|
@@ -105875,7 +105899,7 @@ var en_AU_default = {
|
|
|
105875
105899
|
autoSizeAllColumns: "Autosize all columns",
|
|
105876
105900
|
hideColumn: "Hide column",
|
|
105877
105901
|
resetColumns: "Reset columns",
|
|
105878
|
-
unGroupBy: "Un-
|
|
105902
|
+
unGroupBy: "Un-group by {{label}}",
|
|
105879
105903
|
groupBy: "Group by {{label}}"
|
|
105880
105904
|
},
|
|
105881
105905
|
grandTotals: "Grand totals",
|
|
@@ -105922,6 +105946,9 @@ var en_AU_default = {
|
|
|
105922
105946
|
selectCell: {
|
|
105923
105947
|
placeholder: "Select {{label}}"
|
|
105924
105948
|
},
|
|
105949
|
+
multiSelectCell: {
|
|
105950
|
+
placeholder: "Select values"
|
|
105951
|
+
},
|
|
105925
105952
|
booleanCell: {
|
|
105926
105953
|
options: {
|
|
105927
105954
|
yes: "Yes",
|
|
@@ -106038,7 +106065,7 @@ var en_CA_default = {
|
|
|
106038
106065
|
autoSizeAllColumns: "Autosize all columns",
|
|
106039
106066
|
hideColumn: "Hide column",
|
|
106040
106067
|
resetColumns: "Reset columns",
|
|
106041
|
-
unGroupBy: "Un-
|
|
106068
|
+
unGroupBy: "Un-group by {{label}}",
|
|
106042
106069
|
groupBy: "Group by {{label}}"
|
|
106043
106070
|
},
|
|
106044
106071
|
grandTotals: "Grand totals",
|
|
@@ -106085,6 +106112,9 @@ var en_CA_default = {
|
|
|
106085
106112
|
selectCell: {
|
|
106086
106113
|
placeholder: "Select {{label}}"
|
|
106087
106114
|
},
|
|
106115
|
+
multiSelectCell: {
|
|
106116
|
+
placeholder: "Select values"
|
|
106117
|
+
},
|
|
106088
106118
|
booleanCell: {
|
|
106089
106119
|
options: {
|
|
106090
106120
|
yes: "Yes",
|
|
@@ -106248,6 +106278,9 @@ var en_GB_default = {
|
|
|
106248
106278
|
selectCell: {
|
|
106249
106279
|
placeholder: "Select {{label}}"
|
|
106250
106280
|
},
|
|
106281
|
+
multiSelectCell: {
|
|
106282
|
+
placeholder: "Select values"
|
|
106283
|
+
},
|
|
106251
106284
|
booleanCell: {
|
|
106252
106285
|
options: {
|
|
106253
106286
|
yes: "Yes",
|
|
@@ -106577,6 +106610,9 @@ var es_ES_default = {
|
|
|
106577
106610
|
selectCell: {
|
|
106578
106611
|
placeholder: "Seleccionar {{label}}"
|
|
106579
106612
|
},
|
|
106613
|
+
multiSelectCell: {
|
|
106614
|
+
placeholder: "Seleccionar valores"
|
|
106615
|
+
},
|
|
106580
106616
|
booleanCell: {
|
|
106581
106617
|
options: {
|
|
106582
106618
|
yes: "S\xED",
|
|
@@ -106613,7 +106649,7 @@ var es_default = {
|
|
|
106613
106649
|
description: "Una vez que su equipo cree \xEDtems, podr\xE1 acceder a ellos aqu\xED. ",
|
|
106614
106650
|
title: "No hay \xEDtems para mostrar en este momento",
|
|
106615
106651
|
itemsTitle: "No hay %{itemsLabel} para mostrar en este momento",
|
|
106616
|
-
tooltip: "El bot\xF3n %{featureName} se habilitar\xE1 una vez que agregue informaci\xF3n
|
|
106652
|
+
tooltip: "El bot\xF3n %{featureName} se habilitar\xE1 una vez que agregue informaci\xF3n a la %{tableName}.",
|
|
106617
106653
|
searchTooltip: "La b\xFAsqueda se habilitar\xE1 una vez que agregue informaci\xF3n a %{tableName}",
|
|
106618
106654
|
featureFilter: "Filtro",
|
|
106619
106655
|
featureQuickFilter: "Filtro r\xE1pido",
|
|
@@ -106627,7 +106663,7 @@ var es_default = {
|
|
|
106627
106663
|
bulkEdit: "Edici\xF3n masiva",
|
|
106628
106664
|
cancel: "Cancelar",
|
|
106629
106665
|
editValues: "Editar valores",
|
|
106630
|
-
error: "Lo sentimos, no se pudieron actualizar los \xEDtems.
|
|
106666
|
+
error: "Lo sentimos, no se pudieron actualizar los \xEDtems. Int\xE9ntelo de nuevo.",
|
|
106631
106667
|
placeholderForField: "Ingrese %{fieldName}",
|
|
106632
106668
|
selection: "%{count} %{number} seleccionado",
|
|
106633
106669
|
success: "Los \xEDtems se actualizaron correctamente.",
|
|
@@ -106673,14 +106709,14 @@ var es_default = {
|
|
|
106673
106709
|
}
|
|
106674
106710
|
},
|
|
106675
106711
|
loading: {
|
|
106676
|
-
initial: "Cargando informaci\xF3n
|
|
106712
|
+
initial: "Cargando informaci\xF3n...",
|
|
106677
106713
|
secondary: "Cargando informaci\xF3n. Gracias por su paciencia."
|
|
106678
106714
|
},
|
|
106679
106715
|
menuOptions: {
|
|
106680
106716
|
sortMenuItem: {
|
|
106681
106717
|
label: "Ordenar por esta columna",
|
|
106682
|
-
sortAscItem: "Ordenar columna
|
|
106683
|
-
sortDescItem: "Ordenar columna
|
|
106718
|
+
sortAscItem: "Ordenar columna - Ascendente",
|
|
106719
|
+
sortDescItem: "Ordenar columna - Descendente",
|
|
106684
106720
|
sortResetItem: "Columna no ordenada"
|
|
106685
106721
|
},
|
|
106686
106722
|
expandAllGroups: "Expandir todos los grupos",
|
|
@@ -106740,6 +106776,9 @@ var es_default = {
|
|
|
106740
106776
|
selectCell: {
|
|
106741
106777
|
placeholder: "Seleccionar {{label}}"
|
|
106742
106778
|
},
|
|
106779
|
+
multiSelectCell: {
|
|
106780
|
+
placeholder: "Seleccionar valores"
|
|
106781
|
+
},
|
|
106743
106782
|
booleanCell: {
|
|
106744
106783
|
options: {
|
|
106745
106784
|
yes: "S\xED",
|
|
@@ -106790,7 +106829,7 @@ var fr_CA_default = {
|
|
|
106790
106829
|
bulkEdit: "Modifier en bloc",
|
|
106791
106830
|
cancel: "Annuler",
|
|
106792
106831
|
editValues: "Modifier les valeurs",
|
|
106793
|
-
error: "D\xE9sol\xE9, les items n'ont pas pu \xEAtre mis \xE0 jour.
|
|
106832
|
+
error: "D\xE9sol\xE9, les items n'ont pas pu \xEAtre mis \xE0 jour. Veuillez r\xE9essayer.",
|
|
106794
106833
|
placeholderForField: "Entrez %{fieldName}",
|
|
106795
106834
|
selection: "%{count} %{number} s\xE9lectionn\xE9",
|
|
106796
106835
|
success: "Les items ont \xE9t\xE9 mis \xE0 jour avec succ\xE8s.",
|
|
@@ -106903,6 +106942,9 @@ var fr_CA_default = {
|
|
|
106903
106942
|
selectCell: {
|
|
106904
106943
|
placeholder: "S\xE9lectionner {{label}}"
|
|
106905
106944
|
},
|
|
106945
|
+
multiSelectCell: {
|
|
106946
|
+
placeholder: "S\xE9lectionner les valeurs"
|
|
106947
|
+
},
|
|
106906
106948
|
booleanCell: {
|
|
106907
106949
|
options: {
|
|
106908
106950
|
yes: "Oui",
|
|
@@ -106953,7 +106995,7 @@ var fr_FR_default = {
|
|
|
106953
106995
|
bulkEdit: "Modifier en masse",
|
|
106954
106996
|
cancel: "Annuler",
|
|
106955
106997
|
editValues: "Modifier les valeurs",
|
|
106956
|
-
error: "D\xE9sol\xE9, les \xE9l\xE9ments n'ont pas pu \xEAtre mis \xE0 jour.
|
|
106998
|
+
error: "D\xE9sol\xE9, les \xE9l\xE9ments n'ont pas pu \xEAtre mis \xE0 jour. Veuillez r\xE9essayer.",
|
|
106957
106999
|
placeholderForField: "Saisissez %{fieldName}",
|
|
106958
107000
|
selection: "%{count} %{number} s\xE9lectionn\xE9",
|
|
106959
107001
|
success: "Les \xE9l\xE9ments ont bien \xE9t\xE9 mis \xE0 jour.",
|
|
@@ -107066,6 +107108,9 @@ var fr_FR_default = {
|
|
|
107066
107108
|
selectCell: {
|
|
107067
107109
|
placeholder: "S\xE9lectionner {{label}}"
|
|
107068
107110
|
},
|
|
107111
|
+
multiSelectCell: {
|
|
107112
|
+
placeholder: "S\xE9lectionner les valeurs"
|
|
107113
|
+
},
|
|
107069
107114
|
booleanCell: {
|
|
107070
107115
|
options: {
|
|
107071
107116
|
yes: "Oui",
|
|
@@ -107229,6 +107274,9 @@ var is_IS_default = {
|
|
|
107229
107274
|
selectCell: {
|
|
107230
107275
|
placeholder: "Veldu {{label}}"
|
|
107231
107276
|
},
|
|
107277
|
+
multiSelectCell: {
|
|
107278
|
+
placeholder: "Veldu Gildi"
|
|
107279
|
+
},
|
|
107232
107280
|
booleanCell: {
|
|
107233
107281
|
options: {
|
|
107234
107282
|
yes: "J\xE1",
|
|
@@ -107392,6 +107440,9 @@ var ja_JP_default = {
|
|
|
107392
107440
|
selectCell: {
|
|
107393
107441
|
placeholder: "{{label}}\u3092\u9078\u629E\u3059\u308B"
|
|
107394
107442
|
},
|
|
107443
|
+
multiSelectCell: {
|
|
107444
|
+
placeholder: "\u5024\u3092\u9078\u629E"
|
|
107445
|
+
},
|
|
107395
107446
|
booleanCell: {
|
|
107396
107447
|
options: {
|
|
107397
107448
|
yes: "\u306F\u3044",
|
|
@@ -107555,6 +107606,9 @@ var pl_PL_default = {
|
|
|
107555
107606
|
selectCell: {
|
|
107556
107607
|
placeholder: "Wybierz {{label}}"
|
|
107557
107608
|
},
|
|
107609
|
+
multiSelectCell: {
|
|
107610
|
+
placeholder: "Wybierz warto\u015Bci"
|
|
107611
|
+
},
|
|
107558
107612
|
booleanCell: {
|
|
107559
107613
|
options: {
|
|
107560
107614
|
yes: "Tak",
|
|
@@ -107757,8 +107811,8 @@ var pt_BR_default = {
|
|
|
107757
107811
|
description: "Depois que sua equipe criar esses itens, voc\xEA poder\xE1 acess\xE1-los aqui. ",
|
|
107758
107812
|
title: "N\xE3o H\xE1 Itens para Exibir Agora",
|
|
107759
107813
|
itemsTitle: "N\xE3o H\xE1 %{itemsLabel} para Exibir Agora",
|
|
107760
|
-
tooltip: "O bot\xE3o %{featureName} ser\xE1 ativado assim que voc\xEA adicionar informa\xE7\xF5es
|
|
107761
|
-
searchTooltip: "A pesquisa ser\xE1 ativada assim que voc\xEA adicionar informa\xE7\xF5es \xE0
|
|
107814
|
+
tooltip: "O bot\xE3o %{featureName} ser\xE1 ativado assim que voc\xEA adicionar informa\xE7\xF5es \xE0 %{tableName}",
|
|
107815
|
+
searchTooltip: "A pesquisa ser\xE1 ativada assim que voc\xEA adicionar informa\xE7\xF5es \xE0 %{tableName}",
|
|
107762
107816
|
featureFilter: "Filtrar",
|
|
107763
107817
|
featureQuickFilter: "Filtro r\xE1pido",
|
|
107764
107818
|
featureGroupBy: "Agrupar por",
|
|
@@ -107771,7 +107825,7 @@ var pt_BR_default = {
|
|
|
107771
107825
|
bulkEdit: "Edi\xE7\xE3o em Massa",
|
|
107772
107826
|
cancel: "Cancelar",
|
|
107773
107827
|
editValues: "Editar Valores",
|
|
107774
|
-
error: "
|
|
107828
|
+
error: "Sentimos muito, mas n\xE3o foi poss\xEDvel atualizar os itens. Tente novamente.",
|
|
107775
107829
|
placeholderForField: "Digite %{fieldName}",
|
|
107776
107830
|
selection: "%{count} %{number} selecionado",
|
|
107777
107831
|
success: "Os itens foram atualizados com sucesso.",
|
|
@@ -107884,6 +107938,9 @@ var pt_BR_default = {
|
|
|
107884
107938
|
selectCell: {
|
|
107885
107939
|
placeholder: "Selecionar {{label}}"
|
|
107886
107940
|
},
|
|
107941
|
+
multiSelectCell: {
|
|
107942
|
+
placeholder: "Selecionar Valores"
|
|
107943
|
+
},
|
|
107887
107944
|
booleanCell: {
|
|
107888
107945
|
options: {
|
|
107889
107946
|
yes: "Sim",
|
|
@@ -107934,7 +107991,7 @@ var th_TH_default = {
|
|
|
107934
107991
|
bulkEdit: "\u0E01\u0E32\u0E23\u0E41\u0E01\u0E49\u0E44\u0E02\u0E41\u0E1A\u0E1A\u0E01\u0E25\u0E38\u0E48\u0E21",
|
|
107935
107992
|
cancel: "\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01",
|
|
107936
107993
|
editValues: "\u0E41\u0E01\u0E49\u0E44\u0E02\u0E04\u0E48\u0E32",
|
|
107937
|
-
error: "\u0E02\u0E2D\u0E2D\u0E20\u0E31\u0E22 \u0E44\u0E21\u0E48\u0E2A\u0E32\u0E21\u0E32\u0E23\u0E16\u0E2D\u0E31\u0E1B\u0E40\u0E14\u0E15\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23\u0E44\u0E14\u0E49 \
|
|
107994
|
+
error: "\u0E02\u0E2D\u0E2D\u0E20\u0E31\u0E22 \u0E44\u0E21\u0E48\u0E2A\u0E32\u0E21\u0E32\u0E23\u0E16\u0E2D\u0E31\u0E1B\u0E40\u0E14\u0E15\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23\u0E44\u0E14\u0E49 \u0E25\u0E2D\u0E07\u0E2D\u0E35\u0E01\u0E04\u0E23\u0E31\u0E49\u0E07.",
|
|
107938
107995
|
placeholderForField: "\u0E1B\u0E49\u0E2D\u0E19 %{fieldName}",
|
|
107939
107996
|
selection: "%{count} %{number} \u0E17\u0E35\u0E48\u0E40\u0E25\u0E37\u0E2D\u0E01",
|
|
107940
107997
|
success: "\u0E2D\u0E31\u0E1B\u0E40\u0E14\u0E15\u0E23\u0E32\u0E22\u0E01\u0E32\u0E23\u0E2A\u0E33\u0E40\u0E23\u0E47\u0E08\u0E41\u0E25\u0E49\u0E27",
|
|
@@ -108047,6 +108104,9 @@ var th_TH_default = {
|
|
|
108047
108104
|
selectCell: {
|
|
108048
108105
|
placeholder: "\u0E40\u0E25\u0E37\u0E2D\u0E01 {{label}}"
|
|
108049
108106
|
},
|
|
108107
|
+
multiSelectCell: {
|
|
108108
|
+
placeholder: "\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E04\u0E48\u0E32"
|
|
108109
|
+
},
|
|
108050
108110
|
booleanCell: {
|
|
108051
108111
|
options: {
|
|
108052
108112
|
yes: "\u0E43\u0E0A\u0E48",
|
|
@@ -108210,6 +108270,9 @@ var zh_SG_default = {
|
|
|
108210
108270
|
selectCell: {
|
|
108211
108271
|
placeholder: "\u9009\u62E9{{label}}"
|
|
108212
108272
|
},
|
|
108273
|
+
multiSelectCell: {
|
|
108274
|
+
placeholder: "\u9009\u62E9\u503C"
|
|
108275
|
+
},
|
|
108213
108276
|
booleanCell: {
|
|
108214
108277
|
options: {
|
|
108215
108278
|
yes: "\u662F",
|
|
@@ -109245,16 +109308,16 @@ var DataTable = ({
|
|
|
109245
109308
|
);
|
|
109246
109309
|
const contextPanel = useContextPanel();
|
|
109247
109310
|
const clientI18n = coreReact.useI18nContext();
|
|
109248
|
-
const isCDNEnabled =
|
|
109311
|
+
const isCDNEnabled = cdnTranslations.isCDNFeatureFlagEnabled(clientI18n, enableCDN);
|
|
109249
109312
|
const cdnTranslations$1 = cdnTranslations.useRequestTranslations(
|
|
109250
109313
|
{
|
|
109251
109314
|
locale: clientI18n.locale,
|
|
109252
109315
|
type: "file",
|
|
109253
109316
|
absolute_file_path: (locale) => `core/packages/data-table/src/locales/${locale}.json`
|
|
109254
109317
|
},
|
|
109255
|
-
{ en: translations.en },
|
|
109318
|
+
{ en: translations.en, pseudo: translations.pseudo },
|
|
109256
109319
|
{
|
|
109257
|
-
translations,
|
|
109320
|
+
oldTranslations: translations,
|
|
109258
109321
|
enableCDN: isCDNEnabled
|
|
109259
109322
|
}
|
|
109260
109323
|
);
|
|
@@ -109266,7 +109329,6 @@ var DataTable = ({
|
|
|
109266
109329
|
}),
|
|
109267
109330
|
cdnTranslations$1.translations
|
|
109268
109331
|
),
|
|
109269
|
-
requestedTranslations: cdnTranslations$1,
|
|
109270
109332
|
enableCDN: isCDNEnabled
|
|
109271
109333
|
});
|
|
109272
109334
|
const rowSelectionRef = React80__default.default.useRef({
|
|
@@ -109318,6 +109380,7 @@ var DataTable = ({
|
|
|
109318
109380
|
);
|
|
109319
109381
|
const [gridApi, setGridApi] = React80__default.default.useState();
|
|
109320
109382
|
const [columnApi, setColumnApi] = React80__default.default.useState();
|
|
109383
|
+
const [hasDuplicateRowIds, setHasDuplicateRowIds] = React80__default.default.useState(false);
|
|
109321
109384
|
const searchStorage = useSearchStorage();
|
|
109322
109385
|
const filterState = useFilterState({
|
|
109323
109386
|
columnDefinitions: columns,
|
|
@@ -109395,7 +109458,9 @@ var DataTable = ({
|
|
|
109395
109458
|
gridApi == null ? void 0 : gridApi.hideOverlay.bind(gridApi),
|
|
109396
109459
|
filterStorage.filtersState,
|
|
109397
109460
|
searchStorage.searchValue,
|
|
109398
|
-
setTotalRowCount
|
|
109461
|
+
setTotalRowCount,
|
|
109462
|
+
setHasDuplicateRowIds,
|
|
109463
|
+
getRowId
|
|
109399
109464
|
)
|
|
109400
109465
|
);
|
|
109401
109466
|
gridApi == null ? void 0 : gridApi.paginationGoToPage(0);
|
|
@@ -109490,7 +109555,8 @@ var DataTable = ({
|
|
|
109490
109555
|
tableRef,
|
|
109491
109556
|
totalRowCount,
|
|
109492
109557
|
setTotalRowCount,
|
|
109493
|
-
updateServerSideDataSource
|
|
109558
|
+
updateServerSideDataSource,
|
|
109559
|
+
hasDuplicateRowIds
|
|
109494
109560
|
}
|
|
109495
109561
|
},
|
|
109496
109562
|
children
|
|
@@ -109501,12 +109567,34 @@ var rowDragMoveEvent;
|
|
|
109501
109567
|
var rowDragEndEvent;
|
|
109502
109568
|
function getServerSideDatasource(onServerSideDataRequestCallbackRef, onEmptyResponseCallback = () => {
|
|
109503
109569
|
}, onNonEmptyResponseCallback = () => {
|
|
109504
|
-
}, filters, search, setTotalRowCount) {
|
|
109570
|
+
}, filters, search, setTotalRowCount, setHasDuplicateRowIds, getRowId) {
|
|
109505
109571
|
return {
|
|
109506
109572
|
getRows: async (params) => {
|
|
109507
109573
|
if (onServerSideDataRequestCallbackRef.current) {
|
|
109508
109574
|
const { request, success, fail } = params;
|
|
109509
109575
|
const onSuccess = (loadSuccessParams) => {
|
|
109576
|
+
const { rowData } = loadSuccessParams;
|
|
109577
|
+
if (rowData && Array.isArray(rowData) && getRowId) {
|
|
109578
|
+
const uniqueRowIds = /* @__PURE__ */ new Set();
|
|
109579
|
+
for (const row2 of rowData) {
|
|
109580
|
+
const id = getRowId({
|
|
109581
|
+
data: row2,
|
|
109582
|
+
level: 0,
|
|
109583
|
+
api: {},
|
|
109584
|
+
columnApi: {},
|
|
109585
|
+
context: {}
|
|
109586
|
+
});
|
|
109587
|
+
if (uniqueRowIds.has(id)) {
|
|
109588
|
+
setHasDuplicateRowIds(true);
|
|
109589
|
+
logger.error(
|
|
109590
|
+
"Duplicate row IDs detected in rowData. Check getRowId() to ensure it returns unique IDs."
|
|
109591
|
+
);
|
|
109592
|
+
fail();
|
|
109593
|
+
return;
|
|
109594
|
+
}
|
|
109595
|
+
uniqueRowIds.add(id);
|
|
109596
|
+
}
|
|
109597
|
+
}
|
|
109510
109598
|
if (!loadSuccessParams.rowCount && request.groupKeys.length === 0) {
|
|
109511
109599
|
onEmptyResponseCallback();
|
|
109512
109600
|
} else {
|
|
@@ -109545,7 +109633,7 @@ var Table = (props) => {
|
|
|
109545
109633
|
const internalTableContext = useInternalTableContext();
|
|
109546
109634
|
const clientSideRowData = props.rows ? { rowData: props.rows } : {};
|
|
109547
109635
|
const serverSideInfiniteScroll = internalTableContext.onServerSideDataRequest ? { serverSideInfiniteScroll: true } : {};
|
|
109548
|
-
const { columnApi, getRowHeight, gridApi } = internalTableContext;
|
|
109636
|
+
const { columnApi, getRowHeight, gridApi, filterState } = internalTableContext;
|
|
109549
109637
|
const [viewportWidth, setViewportWidth] = React80__default.default.useState(0);
|
|
109550
109638
|
const rowActionsWidth = React80__default.default.useRef(0);
|
|
109551
109639
|
const [tableHeight, setTableHeight] = React80__default.default.useState(0);
|
|
@@ -109786,6 +109874,13 @@ var Table = (props) => {
|
|
|
109786
109874
|
setSiblingGroupsRowSelection(selectedGroupIndex, gridApi);
|
|
109787
109875
|
}
|
|
109788
109876
|
}, [internalTableContext.selectedGroupIndex]);
|
|
109877
|
+
React80__default.default.useEffect(() => {
|
|
109878
|
+
filterState.allAvailableFilters.forEach((filter) => {
|
|
109879
|
+
if (Array.isArray(filter.filterValues) && filter.filterValues.length === 0) {
|
|
109880
|
+
tableApi.removeFilter(filter.field);
|
|
109881
|
+
}
|
|
109882
|
+
});
|
|
109883
|
+
}, [filterState.allAvailableFilters]);
|
|
109789
109884
|
function footerValueGetter(params) {
|
|
109790
109885
|
if (props.getSubtotalLabel) {
|
|
109791
109886
|
return props.getSubtotalLabel(
|
|
@@ -110524,13 +110619,7 @@ function ClientSideFilterInner(props) {
|
|
|
110524
110619
|
var _a, _b;
|
|
110525
110620
|
const { Component: Component4, columnDefinition, onChange, options, value } = props;
|
|
110526
110621
|
const filterHeading = ((_b = (_a = columnDefinition.filterProps) == null ? void 0 : _a.getFilterHeadingText) == null ? void 0 : _b.call(_a, columnDefinition)) ?? columnDefinition.headerName;
|
|
110527
|
-
const filterOptions = React80__default.default.useMemo(
|
|
110528
|
-
() => {
|
|
110529
|
-
var _a2;
|
|
110530
|
-
return (_a2 = options ?? []) == null ? void 0 : _a2.filter((option) => !!option);
|
|
110531
|
-
},
|
|
110532
|
-
[options]
|
|
110533
|
-
);
|
|
110622
|
+
const filterOptions = React80__default.default.useMemo(() => options ?? [], [options]);
|
|
110534
110623
|
return /* @__PURE__ */ React80__default.default.createElement(coreReact.Box, { as: "li", display: "block", paddingBottom: "xl", style: { width: "100%" } }, filterHeading ? /* @__PURE__ */ React80__default.default.createElement(
|
|
110535
110624
|
coreReact.Label,
|
|
110536
110625
|
{
|
package/dist/legacy/index.d.cts
CHANGED
|
@@ -1378,6 +1378,7 @@ interface InternalTableContext {
|
|
|
1378
1378
|
getColumnDefinition: (field: string) => ColumnDefinition | undefined;
|
|
1379
1379
|
totalRowCount: number;
|
|
1380
1380
|
setTotalRowCount: React__default.Dispatch<React__default.SetStateAction<number>>;
|
|
1381
|
+
hasDuplicateRowIds: boolean;
|
|
1381
1382
|
setSelectedGroupIndex?: React__default.Dispatch<React__default.SetStateAction<string | null>>;
|
|
1382
1383
|
}
|
|
1383
1384
|
declare const InternalTableContext: React__default.Context<InternalTableContext>;
|
package/dist/legacy/index.d.ts
CHANGED
|
@@ -1378,6 +1378,7 @@ interface InternalTableContext {
|
|
|
1378
1378
|
getColumnDefinition: (field: string) => ColumnDefinition | undefined;
|
|
1379
1379
|
totalRowCount: number;
|
|
1380
1380
|
setTotalRowCount: React__default.Dispatch<React__default.SetStateAction<number>>;
|
|
1381
|
+
hasDuplicateRowIds: boolean;
|
|
1381
1382
|
setSelectedGroupIndex?: React__default.Dispatch<React__default.SetStateAction<string | null>>;
|
|
1382
1383
|
}
|
|
1383
1384
|
declare const InternalTableContext: React__default.Context<InternalTableContext>;
|