impact-ui 4.0.18 → 5.0.0-alpha.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.
Files changed (178) hide show
  1. package/README.md +8 -9
  2. package/dist/_virtual/_commonjsHelpers.js +0 -2
  3. package/dist/components/Input/index.js +2 -2
  4. package/dist/components/KeyboardShortCuts/ShortcutLandingPage.js +1 -1
  5. package/dist/components/KeyboardShortCuts/ShortcutModal.js +1 -1
  6. package/dist/components/KeyboardShortCuts/allSetBox.js +1 -1
  7. package/dist/components/KeyboardShortCuts/index.d.ts.map +1 -1
  8. package/dist/components/KeyboardShortCuts/index.js +38 -112
  9. package/dist/components/KeyboardShortCuts/tutorial.js +1 -1
  10. package/dist/components/OnboardingTour/index.d.ts +61 -0
  11. package/dist/components/OnboardingTour/index.d.ts.map +1 -0
  12. package/dist/components/OnboardingTour/index.js +232 -0
  13. package/dist/components/OnboardingTour/productTourList.d.ts +39 -0
  14. package/dist/components/OnboardingTour/productTourList.d.ts.map +1 -0
  15. package/dist/components/OnboardingTour/productTourList.js +86 -0
  16. package/dist/components/OnboardingTour/tooltipCard.d.ts +45 -0
  17. package/dist/components/OnboardingTour/tooltipCard.d.ts.map +1 -0
  18. package/dist/components/OnboardingTour/tooltipCard.js +96 -0
  19. package/dist/components/OnboardingTour/useTooltipCardPosition.d.ts +29 -0
  20. package/dist/components/OnboardingTour/useTooltipCardPosition.d.ts.map +1 -0
  21. package/dist/components/OnboardingTour/useTooltipCardPosition.js +221 -0
  22. package/dist/components/Select/index.d.ts.map +1 -1
  23. package/dist/components/Select/index.js +14 -5
  24. package/dist/components/{Table → TableV36}/AdvanceSearchModalItem.d.ts +3 -1
  25. package/dist/components/TableV36/AdvanceSearchModalItem.d.ts.map +1 -0
  26. package/dist/components/{Table → TableV36}/AdvanceSortModal.d.ts +3 -1
  27. package/dist/components/TableV36/AdvanceSortModal.d.ts.map +1 -0
  28. package/dist/components/{Table → TableV36}/AdvanceSortModal.js +41 -37
  29. package/dist/components/{Table → TableV36}/AgGridHeader.d.ts +2 -1
  30. package/dist/components/TableV36/AgGridHeader.d.ts.map +1 -0
  31. package/dist/components/{Table → TableV36}/AgGridHeader.js +93 -105
  32. package/dist/components/TableV36/AgGridHeaderGroup.d.ts +3 -0
  33. package/dist/components/TableV36/AgGridHeaderGroup.d.ts.map +1 -0
  34. package/dist/components/TableV36/AgGridHeaderGroup.js +29 -0
  35. package/dist/components/TableV36/CellTooltip.d.ts +14 -0
  36. package/dist/components/TableV36/CellTooltip.d.ts.map +1 -0
  37. package/dist/components/TableV36/CellTooltip.js +11 -0
  38. package/dist/components/{Table → TableV36}/CommentsPortal.d.ts +5 -3
  39. package/dist/components/TableV36/CommentsPortal.d.ts.map +1 -0
  40. package/dist/components/{Table → TableV36}/CommentsPortal.js +6 -10
  41. package/dist/components/TableV36/HighlightedText.d.ts +11 -0
  42. package/dist/components/TableV36/HighlightedText.d.ts.map +1 -0
  43. package/dist/components/TableV36/HighlightedText.js +20 -0
  44. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModal.d.ts.map +1 -0
  45. package/dist/components/{Table → TableV36}/NewAdvanceSearchModal/NewAdvanceSearchModal.js +26 -26
  46. package/dist/components/{Table → TableV36}/NewAdvanceSearchModal/NewAdvanceSearchModalItem.d.ts +5 -4
  47. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModalItem.d.ts.map +1 -0
  48. package/dist/components/{Table → TableV36}/NewAdvanceSearchModal/NewAdvanceSearchModalItem.js +19 -43
  49. package/dist/components/{Table → TableV36}/NoComments.d.ts +3 -1
  50. package/dist/components/TableV36/NoComments.d.ts.map +1 -0
  51. package/dist/components/{Table → TableV36}/NoComments.js +3 -5
  52. package/dist/components/TableV36/Table.types.d.ts +127 -0
  53. package/dist/components/TableV36/Table.types.d.ts.map +1 -0
  54. package/dist/components/TableV36/TableSkeletonCell.d.ts +18 -0
  55. package/dist/components/TableV36/TableSkeletonCell.d.ts.map +1 -0
  56. package/dist/components/TableV36/TableSkeletonCell.js +38 -0
  57. package/dist/components/TableV36/TableV36PortalContext.d.ts +6 -0
  58. package/dist/components/TableV36/TableV36PortalContext.d.ts.map +1 -0
  59. package/dist/components/TableV36/TableV36PortalContext.js +10 -0
  60. package/dist/components/{TableOld → TableV36}/actionBar.d.ts +3 -1
  61. package/dist/components/TableV36/actionBar.d.ts.map +1 -0
  62. package/dist/components/{Table → TableV36}/actionBar.js +1 -5
  63. package/dist/components/{Table → TableV36}/advanceSearchModal.d.ts +3 -1
  64. package/dist/components/TableV36/advanceSearchModal.d.ts.map +1 -0
  65. package/dist/components/{Table → TableV36}/filterUtils.d.ts +2 -56
  66. package/dist/components/TableV36/filterUtils.d.ts.map +1 -0
  67. package/dist/components/{Table → TableV36}/filterUtils.js +17 -100
  68. package/dist/components/TableV36/index.d.ts +3 -0
  69. package/dist/components/TableV36/index.d.ts.map +1 -0
  70. package/dist/components/TableV36/index.js +1858 -0
  71. package/dist/components/TableV36/mockData.d.ts.map +1 -0
  72. package/dist/components/TableV36/resolveTableLoadingOptions.d.ts +62 -0
  73. package/dist/components/TableV36/resolveTableLoadingOptions.d.ts.map +1 -0
  74. package/dist/components/TableV36/resolveTableLoadingOptions.js +52 -0
  75. package/dist/components/TableV36/resolveTableLoadingOptions.test.d.ts +2 -0
  76. package/dist/components/TableV36/resolveTableLoadingOptions.test.d.ts.map +1 -0
  77. package/dist/components/{TableOld → TableV36}/tableFunctions.d.ts +14 -10
  78. package/dist/components/TableV36/tableFunctions.d.ts.map +1 -0
  79. package/dist/components/{shared/tableColumnSettings/columnsTabV36.js → TableV36/tableFunctions.js} +666 -292
  80. package/dist/components/{Table → TableV36}/tableHeader.d.ts +7 -3
  81. package/dist/components/TableV36/tableHeader.d.ts.map +1 -0
  82. package/dist/components/{Table → TableV36}/tableHeader.js +26 -30
  83. package/dist/components/{TableOld → TableV36}/tableIcons.d.ts.map +1 -1
  84. package/dist/components/{Table → TableV36}/tableMoreOptions.d.ts +7 -3
  85. package/dist/components/TableV36/tableMoreOptions.d.ts.map +1 -0
  86. package/dist/components/{Table → TableV36}/tableMoreOptions.js +66 -86
  87. package/dist/components/{Table → TableV36}/tablePagination.d.ts +3 -1
  88. package/dist/components/TableV36/tablePagination.d.ts.map +1 -0
  89. package/dist/components/{Table → TableV36}/tablePagination.js +9 -16
  90. package/dist/components/{Table → TableV36}/tableSettings.d.ts +6 -3
  91. package/dist/components/TableV36/tableSettings.d.ts.map +1 -0
  92. package/dist/components/{shared/tableColumnSettings/tableSettingsV36.js → TableV36/tableSettings.js} +34 -40
  93. package/dist/components/TableV36/tableUtils.d.ts +17 -0
  94. package/dist/components/TableV36/tableUtils.d.ts.map +1 -0
  95. package/dist/components/TableV36/tableUtils.js +60 -0
  96. package/dist/components/TableV36/withCommentIcon.d.ts +13 -0
  97. package/dist/components/TableV36/withCommentIcon.d.ts.map +1 -0
  98. package/dist/components/TableV36/withCommentIcon.js +134 -0
  99. package/dist/components/TextArea/index.js +1 -1
  100. package/dist/components/index.d.ts +3 -2
  101. package/dist/components/index.d.ts.map +1 -1
  102. package/dist/components/index.js +4 -4
  103. package/dist/components/shared/tableColumnSettings/agGridColumnSettingsApi.d.ts +2 -4
  104. package/dist/components/shared/tableColumnSettings/agGridColumnSettingsApi.d.ts.map +1 -1
  105. package/dist/mcp-component-registry.json +268 -337
  106. package/dist/node_modules/@impactsmartsuite/impact-icons/dist/index.js +250 -115
  107. package/dist/stories/tableStoryDefaults.d.ts +1 -1
  108. package/dist/stories/tableStoryDefaults.d.ts.map +1 -1
  109. package/dist/stories/tableStoryManyColumns.d.ts +1 -1
  110. package/dist/stories/tableV36ChatApiMock.d.ts +420 -0
  111. package/dist/stories/tableV36ChatApiMock.d.ts.map +1 -0
  112. package/dist/utils/helper.js +0 -60
  113. package/package.json +8 -8
  114. package/dist/_virtual/lodash.js +0 -4
  115. package/dist/components/Table/AdvanceSearchModalItem.d.ts.map +0 -1
  116. package/dist/components/Table/AdvanceSearchModalItem.js +0 -313
  117. package/dist/components/Table/AdvanceSortModal.d.ts.map +0 -1
  118. package/dist/components/Table/AgGridHeader.d.ts.map +0 -1
  119. package/dist/components/Table/CommentsPortal.d.ts.map +0 -1
  120. package/dist/components/Table/NewAdvanceSearchModal/NewAdvanceSearchModal.d.ts.map +0 -1
  121. package/dist/components/Table/NewAdvanceSearchModal/NewAdvanceSearchModalItem.d.ts.map +0 -1
  122. package/dist/components/Table/NoComments.d.ts.map +0 -1
  123. package/dist/components/Table/Table.types.d.ts +0 -40
  124. package/dist/components/Table/Table.types.d.ts.map +0 -1
  125. package/dist/components/Table/actionBar.d.ts +0 -7
  126. package/dist/components/Table/actionBar.d.ts.map +0 -1
  127. package/dist/components/Table/advanceSearchModal.d.ts.map +0 -1
  128. package/dist/components/Table/advanceSearchModal.js +0 -601
  129. package/dist/components/Table/agGridLocale.d.ts +0 -33
  130. package/dist/components/Table/agGridLocale.d.ts.map +0 -1
  131. package/dist/components/Table/agGridLocale.js +0 -59
  132. package/dist/components/Table/filterUtils.d.ts.map +0 -1
  133. package/dist/components/Table/filterUtils.test.d.ts +0 -2
  134. package/dist/components/Table/filterUtils.test.d.ts.map +0 -1
  135. package/dist/components/Table/index.d.ts +0 -4
  136. package/dist/components/Table/index.d.ts.map +0 -1
  137. package/dist/components/Table/index.js +0 -1441
  138. package/dist/components/Table/mockData.d.ts.map +0 -1
  139. package/dist/components/Table/tableFunctions.d.ts +0 -57
  140. package/dist/components/Table/tableFunctions.d.ts.map +0 -1
  141. package/dist/components/Table/tableFunctions.js +0 -1317
  142. package/dist/components/Table/tableHeader.d.ts.map +0 -1
  143. package/dist/components/Table/tableIcons.d.ts.map +0 -1
  144. package/dist/components/Table/tableMoreOptions.d.ts.map +0 -1
  145. package/dist/components/Table/tablePagination.d.ts.map +0 -1
  146. package/dist/components/Table/tableSettings.d.ts.map +0 -1
  147. package/dist/components/Table/tableSettings.js +0 -282
  148. package/dist/components/Table/withCommentIcon.d.ts +0 -2
  149. package/dist/components/Table/withCommentIcon.d.ts.map +0 -1
  150. package/dist/components/Table/withCommentIcon.js +0 -88
  151. package/dist/components/TableOld/AgGridHeader.d.ts +0 -14
  152. package/dist/components/TableOld/AgGridHeader.d.ts.map +0 -1
  153. package/dist/components/TableOld/AgGridHeader.js +0 -496
  154. package/dist/components/TableOld/actionBar.d.ts.map +0 -1
  155. package/dist/components/TableOld/actionBar.js +0 -35
  156. package/dist/components/TableOld/index.d.ts +0 -3
  157. package/dist/components/TableOld/index.d.ts.map +0 -1
  158. package/dist/components/TableOld/index.js +0 -645
  159. package/dist/components/TableOld/mockData.d.ts +0 -39
  160. package/dist/components/TableOld/mockData.d.ts.map +0 -1
  161. package/dist/components/TableOld/tableFunctions.d.ts.map +0 -1
  162. package/dist/components/TableOld/tableFunctions.js +0 -1321
  163. package/dist/components/TableOld/tableHeader.d.ts +0 -53
  164. package/dist/components/TableOld/tableHeader.d.ts.map +0 -1
  165. package/dist/components/TableOld/tableHeader.js +0 -229
  166. package/dist/components/TableOld/tableIcons.d.ts +0 -5
  167. package/dist/components/TableOld/tablePagination.d.ts +0 -8
  168. package/dist/components/TableOld/tablePagination.d.ts.map +0 -1
  169. package/dist/components/TableOld/tablePagination.js +0 -80
  170. package/dist/components/TableOld/tableSettings.d.ts +0 -11
  171. package/dist/components/TableOld/tableSettings.d.ts.map +0 -1
  172. package/dist/components/shared/tableColumnSettings/agGridColumnSettingsApi.js +0 -52
  173. package/dist/components/shared/tableColumnSettings/columnsSettingsColumnRow.js +0 -264
  174. package/dist/components/shared/tableColumnSettings/columnsSettingsVirtualList.js +0 -298
  175. package/dist/node_modules/lodash/lodash.js +0 -5486
  176. /package/dist/components/{Table → TableV36}/NewAdvanceSearchModal/NewAdvanceSearchModal.d.ts +0 -0
  177. /package/dist/components/{Table → TableV36}/mockData.d.ts +0 -0
  178. /package/dist/components/{Table → TableV36}/tableIcons.d.ts +0 -0
@@ -1,34 +1,36 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
- import { forwardRef, useState, useRef, useMemo, useEffect, useLayoutEffect, useCallback } from "react";
2
+ import { forwardRef, useState, useRef, useMemo, useEffect, useCallback, memo } from "react";
3
3
  import { useSensors, useSensor, MouseSensor, TouchSensor, DndContext, closestCenter, DragOverlay } from "@dnd-kit/core";
4
- import { arrayMove, SortableContext } from "@dnd-kit/sortable";
5
- import { PersonUser as PersonUser_default, Globe as Globe_default } from "../../../node_modules/@impactsmartsuite/impact-icons/dist/index.js";
6
- import default_1$1 from "../../../node_modules/@mui/icons-material/KeyboardArrowDown.js";
7
- import default_1$3 from "../../../node_modules/@mui/icons-material/KeyboardArrowRight.js";
8
- import default_1 from "../../../node_modules/@mui/icons-material/KeyboardArrowUp.js";
9
- import default_1$2 from "../../../node_modules/@mui/icons-material/Search.js";
10
- import { getAssetUrl } from "../../../utils/assetBase.js";
11
- import { applyVisibilityMapToGrid, resolveColumnStateApi } from "./agGridColumnSettingsApi.js";
12
- import { SortableColumnItem, NestedColumnItem, capitalizeHeader } from "./columnsSettingsColumnRow.js";
13
- import { flattenColumnRows, SETTINGS_VIRTUALIZE_THRESHOLD, computeSettingsListHeights, buildCheckStateMap, scrollListTowardPointer, VirtualColumnList, FrozenListOuter, ScrollableListOuter } from "./columnsSettingsVirtualList.js";
14
- import { debounce } from "../../../utils/debounce.js";
15
- import { isViewNameUnique } from "../../../utils/helper.js";
16
- import { Badge } from "../../Badge/index.js";
17
- import { Button } from "../../Button/index.js";
18
- import { Checkbox } from "../../Checkbox/index.js";
19
- import { Input } from "../../Input/index.js";
20
- import { Modal } from "../../Modal/index.js";
21
- import { Prompt } from "../../Prompt/index.js";
22
- import { RadioButtonGroup } from "../../RadioButtonGroup/index.js";
23
- import { Select } from "../../Select/index.js";
24
- import { useTranslation } from "../../../i18n/useTranslation.js";
25
- import IconButton from "../../../node_modules/@mui/material/IconButton/IconButton.js";
26
- import DragIndicator from "../../../node_modules/@mui/icons-material/esm/DragIndicator.js";
4
+ import { arrayMove, SortableContext, useSortable } from "@dnd-kit/sortable";
5
+ import { CSS } from "@dnd-kit/utilities";
6
+ import { PersonUser as PersonUser_default, Globe as Globe_default } from "../../node_modules/@impactsmartsuite/impact-icons/dist/index.js";
7
+ import default_1$1 from "../../node_modules/@mui/icons-material/KeyboardArrowDown.js";
8
+ import default_1$3 from "../../node_modules/@mui/icons-material/KeyboardArrowRight.js";
9
+ import default_1 from "../../node_modules/@mui/icons-material/KeyboardArrowUp.js";
10
+ import default_1$2 from "../../node_modules/@mui/icons-material/Search.js";
11
+ import { getAssetUrl } from "../../utils/assetBase.js";
12
+ import { debounce } from "../../utils/debounce.js";
13
+ import { isViewNameUnique } from "../../utils/helper.js";
14
+ import { Badge } from "../Badge/index.js";
15
+ import { Button } from "../Button/index.js";
16
+ import { Checkbox } from "../Checkbox/index.js";
17
+ import { Input } from "../Input/index.js";
18
+ import { Modal } from "../Modal/index.js";
19
+ import { Prompt } from "../Prompt/index.js";
20
+ import { RadioButtonGroup } from "../RadioButtonGroup/index.js";
21
+ import { Select } from "../Select/index.js";
22
+ import HighlightedText from "./HighlightedText.js";
23
+ import { useTableV36PortalContainerProps } from "./TableV36PortalContext.js";
24
+ import { collectVisibleLeafIds, syncColumnSearchTextToGrid, ensureColumnGroupsExpanded } from "./tableUtils.js";
25
+ import IconButton from "../../node_modules/@mui/material/IconButton/IconButton.js";
26
+ import DragIndicator from "../../node_modules/@mui/icons-material/esm/DragIndicator.js";
27
27
  const saveViewIcon = getAssetUrl("icons/saveViewIcon.svg");
28
28
  const saveViewEditIcon = getAssetUrl("icons/saveViewEditIcon.svg");
29
29
  const saveViewDeleteIcon = getAssetUrl("icons/saveViewDeleteIcon.svg");
30
30
  const defaultViewIcon = getAssetUrl("icons/defaultViewIcon.svg");
31
31
  const defaultViewActiveIcon = getAssetUrl("icons/defaultViewIconActive.svg");
32
+ const clearIcon = getAssetUrl("icons/close-tags.svg");
33
+ const searchIcon = getAssetUrl("icons/search-table.svg");
32
34
  const DEFAULT_VIEW_TYPE_ICONS = {
33
35
  global: /* @__PURE__ */ jsx(Globe_default, { height: 16, width: 16 }),
34
36
  personal: /* @__PURE__ */ jsx(PersonUser_default, { height: 16, width: 16 })
@@ -38,12 +40,172 @@ const getViewTypeIcon = (viewType, viewTypeOptions) => {
38
40
  const customIcon = (_a = viewTypeOptions == null ? void 0 : viewTypeOptions.find((option) => option.value === viewType)) == null ? void 0 : _a.icon;
39
41
  return customIcon || DEFAULT_VIEW_TYPE_ICONS[viewType] || null;
40
42
  };
43
+ const onColMenuFreezeClick = (params) => {
44
+ const { pinned } = params.column;
45
+ if (pinned) {
46
+ freezeColumn(params, false);
47
+ } else {
48
+ freezeColumn(params, true);
49
+ }
50
+ };
51
+ const getTableMeta = (api) => {
52
+ if (!api) return null;
53
+ if (!api.__impactTableMeta) {
54
+ api.__impactTableMeta = {};
55
+ }
56
+ return api.__impactTableMeta;
57
+ };
58
+ const freezeColumn = (params, isPinned) => {
59
+ const { colId } = params.column;
60
+ params.api.applyColumnState({
61
+ state: [{ colId, pinned: isPinned ? "left" : null }]
62
+ });
63
+ };
64
+ const onColMenuAutoAdjustClick = (params) => {
65
+ const colDefExtra = { ...params.column.colDef.extra };
66
+ params.column.colDef.extra = colDefExtra;
67
+ params.api.autoSizeColumns([params.column]);
68
+ };
69
+ const sortFunc = (columnData, sortBy, api) => {
70
+ api.api.applyColumnState({
71
+ state: [{ colId: columnData.colId, sort: sortBy }],
72
+ defaultState: { sort: null }
73
+ });
74
+ };
75
+ const getMainMenuItems = (params) => {
76
+ var _a, _b, _c;
77
+ if (!(params == null ? void 0 : params.column)) {
78
+ return [];
79
+ }
80
+ const { onFontSizeChange, onNumberFormatChange } = params;
81
+ const { colDef, pinned, sort, actualWidth } = params.column;
82
+ const columnMenuItems = [];
83
+ columnMenuItems.push(
84
+ {
85
+ name: "Column Settings",
86
+ cssClasses: ["settings-main-container"]
87
+ },
88
+ "separator"
89
+ );
90
+ columnMenuItems.push({
91
+ name: "Sort",
92
+ subMenu: [
93
+ {
94
+ name: "Sort A to Z",
95
+ action: () => {
96
+ sortFunc(params.column, "asc", params);
97
+ },
98
+ checked: sort === "asc"
99
+ },
100
+ {
101
+ name: "Sort Z to A",
102
+ checked: sort === "desc",
103
+ action: () => {
104
+ sortFunc(params.column, "desc", params);
105
+ }
106
+ },
107
+ {
108
+ name: "Reset",
109
+ action: () => {
110
+ sortFunc(params.column, null, params);
111
+ }
112
+ }
113
+ ],
114
+ disabled: !(colDef == null ? void 0 : colDef.sortable)
115
+ });
116
+ columnMenuItems.push({
117
+ name: pinned ? "Unfreeze Column" : "Freeze Column",
118
+ action: () => {
119
+ onColMenuFreezeClick(params);
120
+ }
121
+ });
122
+ columnMenuItems.push({
123
+ name: "Column width",
124
+ subMenu: [
125
+ {
126
+ name: "Auto Adjust",
127
+ action: () => {
128
+ onColMenuAutoAdjustClick(params);
129
+ },
130
+ // if extra.width property is not present- column is auto adjusted
131
+ checked: actualWidth !== ((_a = colDef == null ? void 0 : colDef.extra) == null ? void 0 : _a.width)
132
+ },
133
+ {
134
+ name: "Custom width",
135
+ action: () => {
136
+ var _a2;
137
+ params.api.setColumnWidths([
138
+ { key: params.column.colId, newWidth: (_a2 = colDef == null ? void 0 : colDef.extra) == null ? void 0 : _a2.width }
139
+ ]);
140
+ },
141
+ // if extra.width property is present- column has custom width
142
+ checked: ((_b = colDef == null ? void 0 : colDef.extra) == null ? void 0 : _b.width) === actualWidth,
143
+ disabled: !((_c = colDef == null ? void 0 : colDef.extra) == null ? void 0 : _c.width)
144
+ }
145
+ ]
146
+ });
147
+ columnMenuItems.push({
148
+ name: "Wrap Text",
149
+ disabled: true
150
+ });
151
+ columnMenuItems.push(
152
+ {
153
+ name: "Format",
154
+ cssClasses: ["format-main-container"]
155
+ },
156
+ "separator"
157
+ );
158
+ columnMenuItems.push({
159
+ name: "Numeric Values",
160
+ subMenu: [
161
+ {
162
+ name: "Full Number",
163
+ action: () => onNumberFormatChange("full")
164
+ },
165
+ {
166
+ name: "In K",
167
+ action: () => onNumberFormatChange("thousand")
168
+ },
169
+ {
170
+ name: "In Mn",
171
+ action: () => onNumberFormatChange("million")
172
+ },
173
+ {
174
+ name: "In Bn",
175
+ action: () => onNumberFormatChange("billion")
176
+ }
177
+ ],
178
+ disabled: !onFontSizeChange
179
+ });
180
+ columnMenuItems.push({
181
+ name: "Font Size",
182
+ subMenu: [
183
+ {
184
+ name: "Small Font",
185
+ action: () => onFontSizeChange("small")
186
+ },
187
+ {
188
+ name: "Medium Font",
189
+ action: () => onFontSizeChange("medium")
190
+ },
191
+ {
192
+ name: "Large Font",
193
+ action: () => onFontSizeChange("large")
194
+ }
195
+ ],
196
+ disabled: !onNumberFormatChange
197
+ });
198
+ return columnMenuItems;
199
+ };
41
200
  const filterColumnsBySearch = (columns, searchText) => {
42
201
  if (!searchText) return columns;
43
202
  return columns.map((column) => {
44
203
  const matches = column.headerName.toLowerCase().includes(searchText);
204
+ if (matches) {
205
+ return column;
206
+ }
45
207
  const filteredChildren = column.children ? filterColumnsBySearch(column.children, searchText) : null;
46
- if (matches || (filteredChildren == null ? void 0 : filteredChildren.length) > 0) {
208
+ if ((filteredChildren == null ? void 0 : filteredChildren.length) > 0) {
47
209
  return {
48
210
  ...column,
49
211
  children: filteredChildren
@@ -109,9 +271,8 @@ const buildOrderedLeafIds = (topLevelColumns, topLevelOrder) => {
109
271
  return col ? collectLeafColIds(col) : [id];
110
272
  });
111
273
  };
112
- const applyColumnReorderToGrid = (gridApi, { allColumns, frozenOrder, scrollableOrder, pinChanges, childReorder }, gridRef) => {
113
- if (!gridApi) return;
114
- const stateApi = resolveColumnStateApi(gridApi, gridRef) ?? gridApi;
274
+ const applyColumnReorderToGrid = (api, { allColumns, frozenOrder, scrollableOrder, pinChanges, childReorder }) => {
275
+ if (!api) return;
115
276
  let columns = allColumns;
116
277
  if ((childReorder == null ? void 0 : childReorder.parentId) && (childReorder == null ? void 0 : childReorder.siblingOrder)) {
117
278
  columns = reorderSiblingsInTree(columns, childReorder.parentId, childReorder.siblingOrder);
@@ -126,7 +287,7 @@ const applyColumnReorderToGrid = (gridApi, { allColumns, frozenOrder, scrollable
126
287
  pinState.push({ colId: leafId, pinned });
127
288
  });
128
289
  });
129
- stateApi.applyColumnState({ state: pinState });
290
+ api.applyColumnState({ state: pinState });
130
291
  }
131
292
  const orderedLeafIds = [
132
293
  ...buildOrderedLeafIds(columns, frozenOrder),
@@ -138,7 +299,7 @@ const applyColumnReorderToGrid = (gridApi, { allColumns, frozenOrder, scrollable
138
299
  seen.add(id);
139
300
  return true;
140
301
  });
141
- stateApi.applyColumnState({
302
+ api.applyColumnState({
142
303
  state: uniqueLeafIds.map((colId) => ({ colId })),
143
304
  applyOrder: true
144
305
  });
@@ -182,35 +343,28 @@ const applyVisibilityToggle = (columns, colId) => {
182
343
  children: column.children ? updateChildren(column.children, visibility) : null
183
344
  };
184
345
  });
185
- const update = (cols) => {
186
- let changed = false;
187
- const next = cols.map((column) => {
188
- if (column.colId === colId) {
189
- changed = true;
190
- const newVisibility = !column.isVisible;
191
- visibilityMap.set(column.colId, newVisibility);
192
- return {
193
- ...column,
194
- isVisible: newVisibility,
195
- children: column.children ? updateChildren(column.children, newVisibility) : null
196
- };
197
- }
198
- if (column.children) {
199
- const updatedChildren = update(column.children);
200
- if (updatedChildren === column.children) return column;
201
- changed = true;
202
- const isAnyChildVisible = updatedChildren.some((child) => child.isVisible);
203
- visibilityMap.set(column.colId, isAnyChildVisible);
204
- return {
205
- ...column,
206
- isVisible: isAnyChildVisible,
207
- children: updatedChildren
208
- };
209
- }
210
- return column;
211
- });
212
- return changed ? next : cols;
213
- };
346
+ const update = (cols) => cols.map((column) => {
347
+ if (column.colId === colId) {
348
+ const newVisibility = !column.isVisible;
349
+ visibilityMap.set(column.colId, newVisibility);
350
+ return {
351
+ ...column,
352
+ isVisible: newVisibility,
353
+ children: column.children ? updateChildren(column.children, newVisibility) : null
354
+ };
355
+ }
356
+ if (column.children) {
357
+ const updatedChildren = update(column.children);
358
+ const isAnyChildVisible = updatedChildren.some((child) => child.isVisible);
359
+ visibilityMap.set(column.colId, isAnyChildVisible);
360
+ return {
361
+ ...column,
362
+ isVisible: isAnyChildVisible,
363
+ children: updatedChildren
364
+ };
365
+ }
366
+ return column;
367
+ });
214
368
  return { columns: update(columns), visibilityMap };
215
369
  };
216
370
  const applyVisibilityToAll = (columns, visibility) => {
@@ -225,11 +379,269 @@ const applyVisibilityToAll = (columns, visibility) => {
225
379
  });
226
380
  return { columns: update(columns), visibilityMap };
227
381
  };
382
+ const applyVisibilityMapToGrid = (api, visibilityMap) => {
383
+ if (!api || !visibilityMap.size) return;
384
+ const showIds = [];
385
+ const hideIds = [];
386
+ visibilityMap.forEach((visible, colId) => {
387
+ if (visible) showIds.push(colId);
388
+ else hideIds.push(colId);
389
+ });
390
+ if (showIds.length) api.setColumnsVisible(showIds, true);
391
+ if (hideIds.length) api.setColumnsVisible(hideIds, false);
392
+ };
393
+ const capitalizeHeader = (name) => name ? name.charAt(0).toUpperCase() + name.slice(1) : "";
228
394
  const mouseSensorOptions = { activationConstraint: { distance: 5 } };
229
395
  const touchSensorOptions = { activationConstraint: { delay: 200, tolerance: 5 } };
230
- const ColumnsV36 = forwardRef((props, ref) => {
396
+ const ColumnRowContent = memo(function ColumnRowContent2({
397
+ column,
398
+ level,
399
+ isCollapsed,
400
+ hasChildren,
401
+ isIndeterminate,
402
+ checkboxChecked,
403
+ reserveCollapseSlot,
404
+ rowClassName,
405
+ dragIconClass,
406
+ onToggleCollapse,
407
+ onToggleVisibility,
408
+ onKeyboardReorder,
409
+ dragHandleProps,
410
+ isOverlay,
411
+ searchText
412
+ }) {
413
+ const rowStyle = useMemo(
414
+ () => ({
415
+ ["--indent-level"]: level
416
+ }),
417
+ [level]
418
+ );
419
+ const handleCollapseClick = useCallback(
420
+ (e) => {
421
+ e.stopPropagation();
422
+ onToggleCollapse == null ? void 0 : onToggleCollapse(column.colId);
423
+ },
424
+ [onToggleCollapse, column.colId]
425
+ );
426
+ const handleVisibilityChange = useCallback(() => {
427
+ onToggleVisibility == null ? void 0 : onToggleVisibility(column.colId);
428
+ }, [onToggleVisibility, column.colId]);
429
+ const handleRowKeyDown = useCallback(
430
+ (e) => {
431
+ var _a, _b, _c, _d;
432
+ if (isOverlay) return;
433
+ const current = e.currentTarget;
434
+ if (e.altKey && (e.key === "ArrowUp" || e.key === "ArrowDown")) {
435
+ e.preventDefault();
436
+ onKeyboardReorder == null ? void 0 : onKeyboardReorder(column.colId, e.key === "ArrowUp" ? -1 : 1);
437
+ return;
438
+ }
439
+ switch (e.key) {
440
+ case "ArrowDown": {
441
+ e.preventDefault();
442
+ const next = (_b = (_a = current.parentElement) == null ? void 0 : _a.nextElementSibling) == null ? void 0 : _b.querySelector('[role="treeitem"]');
443
+ next == null ? void 0 : next.focus();
444
+ break;
445
+ }
446
+ case "ArrowUp": {
447
+ e.preventDefault();
448
+ const prev = (_d = (_c = current.parentElement) == null ? void 0 : _c.previousElementSibling) == null ? void 0 : _d.querySelector('[role="treeitem"]');
449
+ prev == null ? void 0 : prev.focus();
450
+ break;
451
+ }
452
+ case "ArrowRight": {
453
+ if (hasChildren && isCollapsed) {
454
+ e.preventDefault();
455
+ onToggleCollapse == null ? void 0 : onToggleCollapse(column.colId);
456
+ }
457
+ break;
458
+ }
459
+ case "ArrowLeft": {
460
+ if (hasChildren && !isCollapsed) {
461
+ e.preventDefault();
462
+ onToggleCollapse == null ? void 0 : onToggleCollapse(column.colId);
463
+ }
464
+ break;
465
+ }
466
+ case "Enter":
467
+ case " ": {
468
+ if (column.disabled) break;
469
+ e.preventDefault();
470
+ onToggleVisibility == null ? void 0 : onToggleVisibility(column.colId);
471
+ break;
472
+ }
473
+ }
474
+ },
475
+ [
476
+ isOverlay,
477
+ level,
478
+ hasChildren,
479
+ isCollapsed,
480
+ onToggleCollapse,
481
+ onToggleVisibility,
482
+ onKeyboardReorder,
483
+ column.colId,
484
+ column.disabled
485
+ ]
486
+ );
487
+ return /* @__PURE__ */ jsxs(
488
+ "div",
489
+ {
490
+ "aria-checked": isIndeterminate ? "mixed" : checkboxChecked,
491
+ "aria-expanded": hasChildren ? !isCollapsed : void 0,
492
+ "aria-label": column.headerName,
493
+ "aria-roledescription": !isOverlay && dragHandleProps ? "sortable column" : void 0,
494
+ "aria-selected": !!checkboxChecked,
495
+ className: rowClassName,
496
+ "data-col-id": column.colId,
497
+ role: "treeitem",
498
+ style: rowStyle,
499
+ tabIndex: isOverlay ? -1 : 0,
500
+ onKeyDown: handleRowKeyDown,
501
+ children: [
502
+ /* @__PURE__ */ jsxs("div", { className: "table-setting-column-leading", children: [
503
+ reserveCollapseSlot && /* @__PURE__ */ jsx("span", { "aria-hidden": !hasChildren, className: "table-setting-column-collapse-slot", children: hasChildren ? /* @__PURE__ */ jsx(
504
+ IconButton,
505
+ {
506
+ "aria-label": isCollapsed ? "Expand column group" : "Collapse column group",
507
+ className: "table-setting-column-collapse-btn",
508
+ onClick: handleCollapseClick,
509
+ children: isCollapsed ? /* @__PURE__ */ jsx(default_1$3, {}) : /* @__PURE__ */ jsx(default_1, {})
510
+ }
511
+ ) : null }),
512
+ /* @__PURE__ */ jsx(
513
+ Checkbox,
514
+ {
515
+ checked: checkboxChecked,
516
+ disabled: column.disabled || isOverlay,
517
+ variant: isIndeterminate ? "dashed" : "default",
518
+ onChange: handleVisibilityChange
519
+ }
520
+ )
521
+ ] }),
522
+ /* @__PURE__ */ jsxs("div", { className: "table-setting-column-trailing", children: [
523
+ dragHandleProps && /* @__PURE__ */ jsx(
524
+ "span",
525
+ {
526
+ className: "table-setting-column-drag-handle",
527
+ ...dragHandleProps,
528
+ "aria-label": `Reorder ${column.headerName}`,
529
+ children: /* @__PURE__ */ jsx(DragIndicator, { className: dragIconClass })
530
+ }
531
+ ),
532
+ /* @__PURE__ */ jsx(
533
+ HighlightedText,
534
+ {
535
+ className: "table-setting-column-name",
536
+ searchText,
537
+ text: capitalizeHeader(column.headerName)
538
+ }
539
+ )
540
+ ] })
541
+ ]
542
+ }
543
+ );
544
+ });
545
+ const areSortablePropsEqual = (prev, next) => prev.column.colId === next.column.colId && prev.column.isVisible === next.column.isVisible && prev.column.headerName === next.column.headerName && prev.column.disabled === next.column.disabled && prev.isIndeterminate === next.isIndeterminate && prev.checkboxChecked === next.checkboxChecked && prev.reserveCollapseSlot === next.reserveCollapseSlot && prev.level === next.level && prev.isCollapsed === next.isCollapsed && prev.hasChildren === next.hasChildren && prev.rowClassName === next.rowClassName && prev.dragIconClass === next.dragIconClass && prev.onToggleCollapse === next.onToggleCollapse && prev.onToggleVisibility === next.onToggleVisibility && prev.onKeyboardReorder === next.onKeyboardReorder && prev.searchText === next.searchText && prev.children === next.children;
546
+ const SortableColumnItem = memo(function SortableColumnItem2({
547
+ column,
548
+ level,
549
+ isCollapsed,
550
+ hasChildren,
551
+ isIndeterminate,
552
+ checkboxChecked,
553
+ reserveCollapseSlot,
554
+ rowClassName,
555
+ dragIconClass,
556
+ onToggleCollapse,
557
+ onToggleVisibility,
558
+ onKeyboardReorder,
559
+ searchText,
560
+ children
561
+ }) {
562
+ const { attributes, listeners, setNodeRef, transform, transition, isDragging } = useSortable({
563
+ id: column.colId
564
+ });
565
+ const style = useMemo(
566
+ () => ({
567
+ transform: CSS.Transform.toString(transform),
568
+ transition,
569
+ // Placeholder stays in-flow; DragOverlay renders the floating preview
570
+ opacity: isDragging ? 0 : void 0,
571
+ zIndex: isDragging ? 0 : void 0
572
+ }),
573
+ [transform, transition, isDragging]
574
+ );
575
+ return /* @__PURE__ */ jsxs(
576
+ "div",
577
+ {
578
+ ref: setNodeRef,
579
+ className: isDragging ? "table-setting-column-sortable--dragging" : void 0,
580
+ style,
581
+ children: [
582
+ /* @__PURE__ */ jsx(
583
+ ColumnRowContent,
584
+ {
585
+ checkboxChecked,
586
+ column,
587
+ dragHandleProps: { ...attributes, ...listeners },
588
+ dragIconClass,
589
+ hasChildren,
590
+ isCollapsed,
591
+ isIndeterminate,
592
+ level,
593
+ reserveCollapseSlot,
594
+ rowClassName,
595
+ searchText,
596
+ onKeyboardReorder,
597
+ onToggleCollapse,
598
+ onToggleVisibility
599
+ }
600
+ ),
601
+ hasChildren && !isCollapsed && children
602
+ ]
603
+ }
604
+ );
605
+ }, areSortablePropsEqual);
606
+ const NestedColumnItem = memo(function NestedColumnItem2({
607
+ column,
608
+ level,
609
+ isCollapsed,
610
+ hasChildren,
611
+ isIndeterminate,
612
+ checkboxChecked,
613
+ reserveCollapseSlot,
614
+ rowClassName,
615
+ dragIconClass,
616
+ onToggleCollapse,
617
+ onToggleVisibility,
618
+ searchText,
619
+ children
620
+ }) {
621
+ return /* @__PURE__ */ jsxs("div", { children: [
622
+ /* @__PURE__ */ jsx(
623
+ ColumnRowContent,
624
+ {
625
+ checkboxChecked,
626
+ column,
627
+ dragIconClass,
628
+ hasChildren,
629
+ isCollapsed,
630
+ isIndeterminate,
631
+ level,
632
+ reserveCollapseSlot,
633
+ rowClassName,
634
+ searchText,
635
+ onToggleCollapse,
636
+ onToggleVisibility
637
+ }
638
+ ),
639
+ hasChildren && !isCollapsed && children
640
+ ] });
641
+ });
642
+ const Columns = forwardRef((props, ref) => {
231
643
  var _a, _b, _c, _d, _e, _f;
232
- const { t } = useTranslation();
644
+ const modalContainerProps = useTableV36PortalContainerProps();
233
645
  const [frozenColumn, setFrozenColumn] = useState([]);
234
646
  const [scrollableColumn, setScrollableColumn] = useState([]);
235
647
  const [searchInputValue, setSearchInputValue] = useState("");
@@ -264,24 +676,15 @@ const ColumnsV36 = forwardRef((props, ref) => {
264
676
  const isDraggingRef = useRef(false);
265
677
  const isInternalUpdateRef = useRef(false);
266
678
  const isColumnPinnedRef = useRef(false);
267
- const frozenListRef = useRef(null);
268
- const scrollableListRef = useRef(null);
269
- const collapseContainerRef = useRef(null);
270
- const autoScrollRafRef = useRef(null);
271
- const dragPointerYRef = useRef(null);
272
679
  const debouncedSetSearchText = useMemo(
273
680
  () => debounce((value) => {
274
681
  setDebouncedSearchText(value);
275
- }, 150),
682
+ }, 400),
276
683
  []
277
684
  );
278
685
  useEffect(
279
686
  () => () => {
280
687
  debouncedSetSearchText.cancel();
281
- if (autoScrollRafRef.current != null) {
282
- cancelAnimationFrame(autoScrollRafRef.current);
283
- autoScrollRafRef.current = null;
284
- }
285
688
  },
286
689
  [debouncedSetSearchText]
287
690
  );
@@ -293,6 +696,48 @@ const ColumnsV36 = forwardRef((props, ref) => {
293
696
  () => filterColumnsBySearch(scrollableColumn, debouncedSearchText),
294
697
  [scrollableColumn, debouncedSearchText]
295
698
  );
699
+ const [activeMatchIndex, setActiveMatchIndex] = useState(0);
700
+ const searchMatchIds = useMemo(() => {
701
+ if (!debouncedSearchText) return [];
702
+ return [
703
+ ...collectVisibleLeafIds(filteredFrozenColumns),
704
+ ...collectVisibleLeafIds(filteredScrollableColumns)
705
+ ];
706
+ }, [debouncedSearchText, filteredFrozenColumns, filteredScrollableColumns]);
707
+ const searchMatchCount = searchMatchIds.length;
708
+ const normalizedMatchIndex = searchMatchCount ? (activeMatchIndex % searchMatchCount + searchMatchCount) % searchMatchCount : 0;
709
+ const activeMatchColId = searchMatchCount ? searchMatchIds[normalizedMatchIndex] : null;
710
+ useEffect(() => {
711
+ setActiveMatchIndex(0);
712
+ }, [debouncedSearchText]);
713
+ useEffect(() => {
714
+ var _a2;
715
+ syncColumnSearchTextToGrid((_a2 = ref == null ? void 0 : ref.current) == null ? void 0 : _a2.api, debouncedSearchText);
716
+ }, [debouncedSearchText, ref]);
717
+ const goToSearchMatch = useCallback((direction) => {
718
+ setActiveMatchIndex((prev) => prev + direction);
719
+ }, []);
720
+ useEffect(() => {
721
+ var _a2, _b2;
722
+ if (!activeMatchColId) return;
723
+ const api = (_a2 = ref == null ? void 0 : ref.current) == null ? void 0 : _a2.api;
724
+ ensureColumnGroupsExpanded(api, activeMatchColId);
725
+ (_b2 = api == null ? void 0 : api.ensureColumnVisible) == null ? void 0 : _b2.call(api, activeMatchColId, "middle");
726
+ const escaped = CSS.escape ? CSS.escape(activeMatchColId) : activeMatchColId.replace(/"/g, '\\"');
727
+ const node = document.querySelector(
728
+ `.table-setting-column-collapse-container [data-col-id="${escaped}"]`
729
+ );
730
+ node == null ? void 0 : node.scrollIntoView({ block: "nearest" });
731
+ }, [activeMatchColId, ref]);
732
+ const handleSearchKeyDown = useCallback(
733
+ (e) => {
734
+ if (e.key !== "Enter") return;
735
+ e.preventDefault();
736
+ if (!searchMatchCount) return;
737
+ goToSearchMatch(e.shiftKey ? -1 : 1);
738
+ },
739
+ [goToSearchMatch, searchMatchCount]
740
+ );
296
741
  const frozenColumnOrder = useMemo(
297
742
  () => getTopLevelColumnIds(
298
743
  filteredFrozenColumns.filter((c) => c.headerName !== "N/A" && c.isVisible !== false)
@@ -313,54 +758,10 @@ const ColumnsV36 = forwardRef((props, ref) => {
313
758
  () => getTopLevelColumnIds(scrollableColumn.filter((c) => c.headerName !== "N/A")),
314
759
  [scrollableColumn]
315
760
  );
316
- const frozenRows = useMemo(
317
- () => flattenColumnRows(filteredFrozenColumns, collapsedFrozenColumns, "frozen"),
318
- [filteredFrozenColumns, collapsedFrozenColumns]
319
- );
320
- const scrollableRows = useMemo(
321
- () => collapsedScrollable ? [] : flattenColumnRows(filteredScrollableColumns, collapsedScrollColumns, "scrollable"),
322
- [filteredScrollableColumns, collapsedScrollColumns, collapsedScrollable]
323
- );
324
- const shouldVirtualize = frozenRows.length + scrollableRows.length > SETTINGS_VIRTUALIZE_THRESHOLD;
325
- const [listViewportHeight, setListViewportHeight] = useState(0);
326
- useLayoutEffect(() => {
327
- const el = collapseContainerRef.current;
328
- if (!el || !shouldVirtualize) return void 0;
329
- const measure = () => {
330
- setListViewportHeight(el.clientHeight);
331
- };
332
- measure();
333
- if (typeof ResizeObserver === "undefined") {
334
- window.addEventListener("resize", measure);
335
- return () => {
336
- window.removeEventListener("resize", measure);
337
- };
338
- }
339
- const observer = new ResizeObserver(measure);
340
- observer.observe(el);
341
- return () => {
342
- observer.disconnect();
343
- };
344
- }, [shouldVirtualize, collapsedColumn, props.isSaveViewEnabled]);
345
- const listHeights = useMemo(
346
- () => computeSettingsListHeights({
347
- shouldVirtualize,
348
- listViewportHeight,
349
- frozenRowCount: frozenRows.length,
350
- scrollableRowCount: scrollableRows.length
351
- }),
352
- [shouldVirtualize, listViewportHeight, frozenRows.length, scrollableRows.length]
353
- );
354
- const checkStateMap = useMemo(
355
- () => buildCheckStateMap([filteredFrozenColumns, filteredScrollableColumns]),
356
- [filteredFrozenColumns, filteredScrollableColumns]
761
+ const sortableItems = useMemo(
762
+ () => [...scrollableColumnOrder, ...frozenColumnOrder],
763
+ [scrollableColumnOrder, frozenColumnOrder]
357
764
  );
358
- const sortableItems = useMemo(() => {
359
- if (!shouldVirtualize) {
360
- return [...scrollableColumnOrder, ...frozenColumnOrder];
361
- }
362
- return [...scrollableRows, ...frozenRows].filter((row) => row.column.isVisible !== false).map((row) => row.column.colId);
363
- }, [shouldVirtualize, scrollableColumnOrder, frozenColumnOrder, scrollableRows, frozenRows]);
364
765
  const allColumnsForLookup = useMemo(
365
766
  () => [...frozenColumn, ...scrollableColumn],
366
767
  [frozenColumn, scrollableColumn]
@@ -473,10 +874,9 @@ const ColumnsV36 = forwardRef((props, ref) => {
473
874
  () => debounce(updateColumnState, 100),
474
875
  [updateColumnState]
475
876
  );
476
- const isColumnsPanelOpen = props.showTableSetting ?? props.showMenu;
477
877
  useEffect(() => {
478
878
  var _a2, _b2, _c2, _d2, _e2, _f2;
479
- if (isColumnsPanelOpen || isColumnPinnedRef.current) {
879
+ if (props.showMenu || isColumnPinnedRef.current) {
480
880
  isColumnPinnedRef.current = false;
481
881
  updateColumnState();
482
882
  const onColumnEvent = () => {
@@ -500,7 +900,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
500
900
  }
501
901
  };
502
902
  }
503
- }, [isColumnsPanelOpen, updateColumnState, debouncedUpdateColumnState, ref]);
903
+ }, [props.showMenu, updateColumnState, debouncedUpdateColumnState, ref]);
504
904
  const handleSearchChange = useCallback(
505
905
  (e) => {
506
906
  const value = e.target.value;
@@ -517,7 +917,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
517
917
  setter((prev) => {
518
918
  const { columns, visibilityMap } = applyVisibilityToggle(prev, colId);
519
919
  isInternalUpdateRef.current = true;
520
- applyVisibilityMapToGrid(api, visibilityMap, ref);
920
+ applyVisibilityMapToGrid(api, visibilityMap);
521
921
  queueMicrotask(() => {
522
922
  isInternalUpdateRef.current = false;
523
923
  });
@@ -563,7 +963,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
563
963
  result = applyVisibilityToAll(prev, nextVisible);
564
964
  }
565
965
  isInternalUpdateRef.current = true;
566
- applyVisibilityMapToGrid(api, result.visibilityMap, ref);
966
+ applyVisibilityMapToGrid(api, result.visibilityMap);
567
967
  queueMicrotask(() => {
568
968
  isInternalUpdateRef.current = false;
569
969
  });
@@ -578,7 +978,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
578
978
  const scrollResult = applyVisibilityToAll(scrollableColumn, nextVisible);
579
979
  const combinedMap = new Map([...frozenResult.visibilityMap, ...scrollResult.visibilityMap]);
580
980
  isInternalUpdateRef.current = true;
581
- applyVisibilityMapToGrid(api, combinedMap, ref);
981
+ applyVisibilityMapToGrid(api, combinedMap);
582
982
  setFrozenColumn(frozenResult.columns);
583
983
  setScrollableColumn(scrollResult.columns);
584
984
  queueMicrotask(() => {
@@ -605,14 +1005,11 @@ const ColumnsV36 = forwardRef((props, ref) => {
605
1005
  [colId]: !prev[colId]
606
1006
  }));
607
1007
  }, []);
608
- const announceReorder = useCallback(
609
- (colId, direction) => {
610
- const el = reorderLiveRegionRef.current;
611
- if (!el) return;
612
- el.textContent = direction === -1 ? t("table.columns.reorderMovedUp", { name: colId }) : t("table.columns.reorderMovedDown", { name: colId });
613
- },
614
- [t]
615
- );
1008
+ const announceReorder = useCallback((colId, direction) => {
1009
+ const el = reorderLiveRegionRef.current;
1010
+ if (!el) return;
1011
+ el.textContent = `Moved ${colId} ${direction === -1 ? "up" : "down"}`;
1012
+ }, []);
616
1013
  const commitColumnReorder = useCallback(
617
1014
  ({ frozenOrder, scrollableOrder, pinChanges, childReorder, announce }) => {
618
1015
  var _a2;
@@ -620,17 +1017,13 @@ const ColumnsV36 = forwardRef((props, ref) => {
620
1017
  if (!api) return;
621
1018
  isInternalUpdateRef.current = true;
622
1019
  isDraggingRef.current = true;
623
- applyColumnReorderToGrid(
624
- api,
625
- {
626
- allColumns: allColumnsForLookup,
627
- frozenOrder,
628
- scrollableOrder,
629
- pinChanges,
630
- childReorder
631
- },
632
- ref
633
- );
1020
+ applyColumnReorderToGrid(api, {
1021
+ allColumns: allColumnsForLookup,
1022
+ frozenOrder,
1023
+ scrollableOrder,
1024
+ pinChanges,
1025
+ childReorder
1026
+ });
634
1027
  updateColumnState();
635
1028
  if (announce) {
636
1029
  announceReorder(announce.colId, announce.direction);
@@ -642,49 +1035,17 @@ const ColumnsV36 = forwardRef((props, ref) => {
642
1035
  },
643
1036
  [ref, allColumnsForLookup, updateColumnState, announceReorder]
644
1037
  );
645
- const stopSettingsListAutoScroll = useCallback(() => {
646
- if (autoScrollRafRef.current != null) {
647
- cancelAnimationFrame(autoScrollRafRef.current);
648
- autoScrollRafRef.current = null;
649
- }
650
- dragPointerYRef.current = null;
651
- }, []);
652
- const tickSettingsListAutoScroll = useCallback(() => {
653
- autoScrollRafRef.current = null;
654
- const y = dragPointerYRef.current;
655
- if (y == null) return;
656
- const moved = scrollListTowardPointer(frozenListRef.current, y) || scrollListTowardPointer(scrollableListRef.current, y);
657
- if (moved) {
658
- autoScrollRafRef.current = requestAnimationFrame(tickSettingsListAutoScroll);
659
- }
660
- }, []);
661
1038
  const handleDragStart = useCallback((event) => {
662
1039
  isDraggingRef.current = true;
663
1040
  setActiveDragId(event.active.id);
664
1041
  }, []);
665
- const handleDragMove = useCallback(
666
- (event) => {
667
- var _a2, _b2, _c2, _d2;
668
- if (!shouldVirtualize) return;
669
- const translated = (_c2 = (_b2 = (_a2 = event.active) == null ? void 0 : _a2.rect) == null ? void 0 : _b2.current) == null ? void 0 : _c2.translated;
670
- const y = translated ? translated.top + translated.height / 2 : (_d2 = event.activatorEvent) == null ? void 0 : _d2.clientY;
671
- if (y == null) return;
672
- dragPointerYRef.current = y;
673
- if (autoScrollRafRef.current == null) {
674
- autoScrollRafRef.current = requestAnimationFrame(tickSettingsListAutoScroll);
675
- }
676
- },
677
- [shouldVirtualize, tickSettingsListAutoScroll]
678
- );
679
1042
  const handleDragCancel = useCallback(() => {
680
- stopSettingsListAutoScroll();
681
1043
  setActiveDragId(null);
682
1044
  isDraggingRef.current = false;
683
- }, [stopSettingsListAutoScroll]);
1045
+ }, []);
684
1046
  const handleDragEnd = useCallback(
685
1047
  (event) => {
686
1048
  const { active, over } = event;
687
- stopSettingsListAutoScroll();
688
1049
  setActiveDragId(null);
689
1050
  if (!over || active.id === over.id) {
690
1051
  isDraggingRef.current = false;
@@ -778,8 +1139,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
778
1139
  fullScrollableOrder,
779
1140
  frozenColumnOrder,
780
1141
  scrollableColumnOrder,
781
- commitColumnReorder,
782
- stopSettingsListAutoScroll
1142
+ commitColumnReorder
783
1143
  ]
784
1144
  );
785
1145
  const handleKeyboardReorder = useCallback(
@@ -827,16 +1187,14 @@ const ColumnsV36 = forwardRef((props, ref) => {
827
1187
  (column, level, section) => {
828
1188
  const isFrozen = section === "frozen";
829
1189
  const collapsedMap = isFrozen ? collapsedFrozenColumns : collapsedScrollColumns;
830
- const isCollapsed = !!collapsedMap[column.colId];
1190
+ const isCollapsed = debouncedSearchText ? false : !!collapsedMap[column.colId];
831
1191
  const hasChildren = Array.isArray(column.children) && column.children.length > 0;
832
1192
  const onToggleCollapse = isFrozen ? toggleFrozenColumnCollapse : toggleScrollColumnCollapse;
833
1193
  const onToggleVisibility = isFrozen ? toggleColumnVisibilityFrozen : toggleColumnVisibilityScroll;
834
- const checkState = checkStateMap.get(column.colId) || {
835
- checked: !!column.isVisible,
836
- indeterminate: false
837
- };
1194
+ const checkState = hasChildren ? getCheckState(column.children) : { checked: !!column.isVisible, indeterminate: false };
838
1195
  const reserveCollapseSlot = isFrozen ? hasChildren : true;
839
- const rowClassName = isFrozen ? "table-setting-frozen-columns-list-item" : "table-setting-scroll-inner-column";
1196
+ const isActiveSearchMatch = !!debouncedSearchText && column.colId === activeMatchColId;
1197
+ const rowClassName = `${isFrozen ? "table-setting-frozen-columns-list-item" : "table-setting-scroll-inner-column"}${isActiveSearchMatch ? " table-setting-column-search-match-active" : ""}`;
840
1198
  const dragIconClass = isFrozen ? "table-setting-frozen-columns-list-drag-icon" : "table-setting-scroll-columns-list-drag-icon";
841
1199
  const nestedSortableIds = hasChildren ? getDirectColumnIds(
842
1200
  column.children.filter((c) => c.headerName !== "N/A" && c.isVisible !== false)
@@ -855,6 +1213,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
855
1213
  level,
856
1214
  reserveCollapseSlot,
857
1215
  rowClassName,
1216
+ searchText: debouncedSearchText,
858
1217
  onKeyboardReorder: handleKeyboardReorder,
859
1218
  onToggleCollapse,
860
1219
  onToggleVisibility,
@@ -875,6 +1234,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
875
1234
  level,
876
1235
  reserveCollapseSlot,
877
1236
  rowClassName,
1237
+ searchText: debouncedSearchText,
878
1238
  onToggleCollapse,
879
1239
  onToggleVisibility,
880
1240
  children: childNodes
@@ -883,9 +1243,10 @@ const ColumnsV36 = forwardRef((props, ref) => {
883
1243
  );
884
1244
  },
885
1245
  [
886
- checkStateMap,
887
1246
  collapsedFrozenColumns,
888
1247
  collapsedScrollColumns,
1248
+ debouncedSearchText,
1249
+ activeMatchColId,
889
1250
  toggleFrozenColumnCollapse,
890
1251
  toggleScrollColumnCollapse,
891
1252
  toggleColumnVisibilityFrozen,
@@ -893,32 +1254,6 @@ const ColumnsV36 = forwardRef((props, ref) => {
893
1254
  handleKeyboardReorder
894
1255
  ]
895
1256
  );
896
- const virtualRowHandlers = useMemo(
897
- () => ({
898
- checkStateMap,
899
- onToggleFrozenCollapse: toggleFrozenColumnCollapse,
900
- onToggleScrollCollapse: toggleScrollColumnCollapse,
901
- onToggleVisibilityFrozen: toggleColumnVisibilityFrozen,
902
- onToggleVisibilityScroll: toggleColumnVisibilityScroll,
903
- onKeyboardReorder: handleKeyboardReorder
904
- }),
905
- [
906
- checkStateMap,
907
- toggleFrozenColumnCollapse,
908
- toggleScrollColumnCollapse,
909
- toggleColumnVisibilityFrozen,
910
- toggleColumnVisibilityScroll,
911
- handleKeyboardReorder
912
- ]
913
- );
914
- const frozenItemData = useMemo(
915
- () => ({ ...virtualRowHandlers, rows: frozenRows }),
916
- [virtualRowHandlers, frozenRows]
917
- );
918
- const scrollableItemData = useMemo(
919
- () => ({ ...virtualRowHandlers, rows: scrollableRows }),
920
- [virtualRowHandlers, scrollableRows]
921
- );
922
1257
  const handleSaveAndApply = () => {
923
1258
  var _a2, _b2;
924
1259
  if (isEditView) {
@@ -1043,6 +1378,18 @@ const ColumnsV36 = forwardRef((props, ref) => {
1043
1378
  nameConflictExcludeView,
1044
1379
  props.isViewNameUniqueAcrossTypes
1045
1380
  );
1381
+ const onSearchUpArrowClick = () => {
1382
+ goToSearchMatch(-1);
1383
+ };
1384
+ const onSearchDownArrowClick = () => {
1385
+ goToSearchMatch(1);
1386
+ };
1387
+ const clearSearchText = () => {
1388
+ debouncedSetSearchText.cancel();
1389
+ setSearchInputValue("");
1390
+ setDebouncedSearchText("");
1391
+ };
1392
+ const rightIconForSearchInout = searchInputValue.length > 0 ? /* @__PURE__ */ jsx("img", { alt: "Clear", src: clearIcon, onClick: clearSearchText }) : /* @__PURE__ */ jsx("img", { alt: "search", className: "table-settings-search-icon", src: searchIcon });
1046
1393
  return /* @__PURE__ */ jsxs("div", { className: "table-setting-columns-settings", children: [
1047
1394
  /* @__PURE__ */ jsx(
1048
1395
  "div",
@@ -1055,13 +1402,13 @@ const ColumnsV36 = forwardRef((props, ref) => {
1055
1402
  props.isSaveViewEnabled && /* @__PURE__ */ jsxs("div", { className: "table-setting-save-view-container", children: [
1056
1403
  savedViewsOptions.length === 0 ? /* @__PURE__ */ jsxs("div", { className: "save-view-icon-title", children: [
1057
1404
  /* @__PURE__ */ jsx("img", { alt: "save-view-icon", src: saveViewIcon }),
1058
- /* @__PURE__ */ jsx("span", { className: "save-view-title", children: t("table.views.none") })
1405
+ /* @__PURE__ */ jsx("span", { className: "save-view-title", children: "No views saved yet" })
1059
1406
  ] }) : /* @__PURE__ */ jsxs("div", { className: "save-view-container-active-view", children: [
1060
1407
  /* @__PURE__ */ jsx(
1061
1408
  Badge,
1062
1409
  {
1063
1410
  color: "success",
1064
- label: `${((_b = savedViewsOptions.find((view) => view.isActive)) == null ? void 0 : _b.viewName) || t("table.views.notApplicable")}`,
1411
+ label: `${((_b = savedViewsOptions.find((view) => view.isActive)) == null ? void 0 : _b.viewName) || "Not Applicable"}`,
1065
1412
  variant: "stroke"
1066
1413
  }
1067
1414
  ),
@@ -1086,16 +1433,16 @@ const ColumnsV36 = forwardRef((props, ref) => {
1086
1433
  onClick: () => {
1087
1434
  setOpenSaveViewModal(true);
1088
1435
  },
1089
- children: t("table.views.saveView")
1436
+ children: "Save View"
1090
1437
  }
1091
1438
  )
1092
1439
  ] }),
1093
1440
  openSaveViewMenu && /* @__PURE__ */ jsxs("div", { className: "save-view-menu", children: [
1094
1441
  /* @__PURE__ */ jsxs("div", { className: "save-view-menu-title", children: [
1095
- /* @__PURE__ */ jsx("span", { children: t("table.views.savedViews") }),
1442
+ /* @__PURE__ */ jsx("span", { children: "Saved views" }),
1096
1443
  /* @__PURE__ */ jsxs("div", { className: "save-view-menu-default-view", children: [
1097
1444
  /* @__PURE__ */ jsx("img", { alt: "default-view-icon", src: defaultViewActiveIcon }),
1098
- /* @__PURE__ */ jsx("span", { className: "save-view-menu-default-view-text", children: t("table.views.default") })
1445
+ /* @__PURE__ */ jsx("span", { className: "save-view-menu-default-view-text", children: "Default" })
1099
1446
  ] })
1100
1447
  ] }),
1101
1448
  /* @__PURE__ */ jsxs("div", { className: "save-view-menu-view-type", children: [
@@ -1103,7 +1450,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1103
1450
  Badge,
1104
1451
  {
1105
1452
  color: selectedBadge === "All" ? "info" : "default",
1106
- label: t("table.views.all"),
1453
+ label: "All",
1107
1454
  size: "small",
1108
1455
  variant: "stroke",
1109
1456
  onClick: () => {
@@ -1135,7 +1482,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1135
1482
  Input,
1136
1483
  {
1137
1484
  leftIcon: /* @__PURE__ */ jsx(default_1$2, {}),
1138
- placeholder: t("table.views.searchPlaceholder"),
1485
+ placeholder: "Search here...",
1139
1486
  value: saveViewSearchText,
1140
1487
  onChange: handleSaveViewSearchChange
1141
1488
  }
@@ -1145,7 +1492,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1145
1492
  return /* @__PURE__ */ jsxs(
1146
1493
  "div",
1147
1494
  {
1148
- "aria-label": t("table.views.savedViewAria", { name: view.viewName }),
1495
+ "aria-label": `Saved view ${view.viewName}`,
1149
1496
  className: `save-view-menu-view-list-item ${view.isActive ? "active" : ""}`,
1150
1497
  role: "button",
1151
1498
  tabIndex: idx === 0 ? 0 : -1,
@@ -1248,7 +1595,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1248
1595
  setOpenSaveViewMenu(false);
1249
1596
  setFilteredSavedViewsOptions([...savedViewsOptions]);
1250
1597
  },
1251
- children: t("common.cancel")
1598
+ children: "Cancel"
1252
1599
  }
1253
1600
  ),
1254
1601
  /* @__PURE__ */ jsx(
@@ -1263,7 +1610,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1263
1610
  updateColumnState();
1264
1611
  setOpenSaveViewMenu(false);
1265
1612
  },
1266
- children: t("common.apply")
1613
+ children: "Apply"
1267
1614
  }
1268
1615
  )
1269
1616
  ] })
@@ -1274,23 +1621,21 @@ const ColumnsV36 = forwardRef((props, ref) => {
1274
1621
  className: "save-view-modal",
1275
1622
  height: "542px",
1276
1623
  open: openSaveViewModal,
1277
- primaryButtonLabel: props.isSavingViewLoading ? t("table.views.saving") : t("common.save"),
1624
+ ...modalContainerProps,
1625
+ primaryButtonLabel: props.isSavingViewLoading ? "Saving..." : "Save",
1278
1626
  primaryButtonProps: {
1279
1627
  disabled: (isInputValueEmpty || props.maxSavedViews != null && savedViewsOptions.length >= props.maxSavedViews) && !isReplaceViewSelected || nameConflict || props.isSavingViewLoading,
1280
1628
  loading: props.isSavingViewLoading,
1281
1629
  iconPlacement: "right"
1282
1630
  },
1283
- secondaryButtonLabel: t("common.cancel"),
1284
- title: isEditView ? t("table.views.editView") : t("table.views.saveViewTitle"),
1631
+ secondaryButtonLabel: "Cancel",
1632
+ title: isEditView ? "Edit view" : "Save view",
1285
1633
  width: "422px",
1286
1634
  onClose: handleCloseSaveViewModal,
1287
1635
  onPrimaryButtonClick: handleSaveAndApply,
1288
1636
  onSecondaryButtonClick: handleCloseSaveViewModal,
1289
1637
  children: /* @__PURE__ */ jsxs("div", { className: "save-view-modal-children", children: [
1290
- props.maxSavedViews != null && /* @__PURE__ */ jsx("div", { className: "save-view-modal-children-header", children: /* @__PURE__ */ jsx("span", { className: "save-view-modal-children-header-text", children: t("table.views.remaining", {
1291
- remaining: props.maxSavedViews - savedViewsOptions.length,
1292
- max: props.maxSavedViews
1293
- }) }) }),
1638
+ props.maxSavedViews != null && /* @__PURE__ */ jsx("div", { className: "save-view-modal-children-header", children: /* @__PURE__ */ jsx("span", { className: "save-view-modal-children-header-text", children: `${props.maxSavedViews - savedViewsOptions.length}/${props.maxSavedViews} views remaining` }) }),
1294
1639
  /* @__PURE__ */ jsxs(
1295
1640
  "div",
1296
1641
  {
@@ -1299,12 +1644,12 @@ const ColumnsV36 = forwardRef((props, ref) => {
1299
1644
  /* @__PURE__ */ jsx("div", { className: "save-view-modal-children-body-input", children: /* @__PURE__ */ jsx(
1300
1645
  Input,
1301
1646
  {
1302
- helperText: nameConflict ? t("table.views.nameConflict") : "",
1647
+ helperText: nameConflict ? "A view with this name already exists" : "",
1303
1648
  isDisabled: isReplaceViewSelected,
1304
1649
  isError: nameConflict,
1305
1650
  isHelperText: nameConflict,
1306
- label: t("table.views.newViewName"),
1307
- placeholder: t("table.views.enterHere"),
1651
+ label: "New view name",
1652
+ placeholder: "Enter here",
1308
1653
  readOnly: isReplaceViewSelected,
1309
1654
  value: inputValue,
1310
1655
  onChange: (e) => {
@@ -1314,7 +1659,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1314
1659
  }
1315
1660
  ) }),
1316
1661
  !isEditView && /* @__PURE__ */ jsxs("div", { className: "save-view-modal-children-body-radio-group", children: [
1317
- /* @__PURE__ */ jsx("span", { className: "save-view-modal-children-body-radio-group-text", children: t("table.views.viewType") }),
1662
+ /* @__PURE__ */ jsx("span", { className: "save-view-modal-children-body-radio-group-text", children: "View type" }),
1318
1663
  /* @__PURE__ */ jsx(
1319
1664
  RadioButtonGroup,
1320
1665
  {
@@ -1334,14 +1679,14 @@ const ColumnsV36 = forwardRef((props, ref) => {
1334
1679
  Checkbox,
1335
1680
  {
1336
1681
  checked: isDefaultView,
1337
- disabled: isReplaceViewSelected,
1338
- label: t("table.views.makeDefault"),
1682
+ disabled: isReplaceViewSelected || isEditView,
1683
+ label: "Make it default view",
1339
1684
  onChange: () => {
1340
1685
  setIsDefaultView(!isDefaultView);
1341
1686
  }
1342
1687
  }
1343
1688
  ) }),
1344
- /* @__PURE__ */ jsx("div", { className: "save-view-modal-children-body-replace-view", children: /* @__PURE__ */ jsx("span", { children: t("table.views.orReplace") }) }),
1689
+ /* @__PURE__ */ jsx("div", { className: "save-view-modal-children-body-replace-view", children: /* @__PURE__ */ jsx("span", { children: "Or replace with saved view" }) }),
1345
1690
  /* @__PURE__ */ jsx("div", { className: "save-view-modal-children-body-replace-view-select", children: /* @__PURE__ */ jsx(
1346
1691
  Select,
1347
1692
  {
@@ -1351,7 +1696,7 @@ const ColumnsV36 = forwardRef((props, ref) => {
1351
1696
  initialOptions: currentSaveViewOptions,
1352
1697
  isDisabled: savedViewsOptions.length === 0 || !isInputValueEmpty && !isReplaceViewSelected || isEditView,
1353
1698
  isOpen,
1354
- label: t("table.views.replaceWith"),
1699
+ label: "Replace with",
1355
1700
  minWidth: "100%",
1356
1701
  selectedOptions: selectedSavedView,
1357
1702
  setCurrentOptions: setCurrentSaveViewOptions,
@@ -1373,13 +1718,13 @@ const ColumnsV36 = forwardRef((props, ref) => {
1373
1718
  setOpenDeletePrompt(false);
1374
1719
  },
1375
1720
  isOpen: openDeletePrompt,
1376
- primaryButtonLabel: t("table.views.deleteConfirm"),
1721
+ primaryButtonLabel: "Yes,Delete",
1377
1722
  primaryButtonProps: {
1378
1723
  loading: props.isDeleteViewLoading,
1379
1724
  iconPlacement: "right"
1380
1725
  },
1381
- secondaryButtonLabel: t("common.cancel"),
1382
- title: t("table.views.deleteTitle"),
1726
+ secondaryButtonLabel: "Cancel",
1727
+ title: "Delete, Are you sure?",
1383
1728
  variant: "error",
1384
1729
  onPrimaryButtonClick: (e) => {
1385
1730
  var _a2;
@@ -1397,66 +1742,81 @@ const ColumnsV36 = forwardRef((props, ref) => {
1397
1742
  /* @__PURE__ */ jsx("span", { className: "table-setting-column-collapse-slot", children: /* @__PURE__ */ jsx(
1398
1743
  IconButton,
1399
1744
  {
1400
- "aria-label": collapsedColumn ? t("table.columns.expandColumns") : t("table.columns.collapseColumns"),
1745
+ "aria-label": collapsedColumn ? "Expand columns" : "Collapse columns",
1401
1746
  className: "table-setting-column-collapse-btn",
1402
1747
  onClick: toggleColumnCollapse,
1403
1748
  children: collapsedColumn ? /* @__PURE__ */ jsx(default_1$3, {}) : /* @__PURE__ */ jsx(default_1, {})
1404
1749
  }
1405
1750
  ) }),
1406
1751
  /* @__PURE__ */ jsxs("div", { className: "table-setting-column-search-controls", children: [
1407
- /* @__PURE__ */ jsx(
1408
- Checkbox,
1409
- {
1410
- "aria-label": t("table.columns.toggleAll"),
1411
- checked: allCheckState.checked,
1412
- variant: allCheckState.indeterminate ? "dashed" : "default",
1413
- onChange: onAllColumnCheckBoxChange
1414
- }
1415
- ),
1416
- /* @__PURE__ */ jsx(
1417
- Input,
1418
- {
1419
- placeholder: t("common.search"),
1420
- rightIcon: /* @__PURE__ */ jsx(default_1$2, {}),
1421
- value: searchInputValue,
1422
- onChange: handleSearchChange
1423
- }
1424
- )
1752
+ /* @__PURE__ */ jsxs("div", { className: "table-settings-lhs", children: [
1753
+ /* @__PURE__ */ jsx(
1754
+ Checkbox,
1755
+ {
1756
+ "aria-label": "Toggle all columns",
1757
+ checked: allCheckState.checked,
1758
+ variant: allCheckState.indeterminate ? "dashed" : "default",
1759
+ onChange: onAllColumnCheckBoxChange
1760
+ }
1761
+ ),
1762
+ /* @__PURE__ */ jsx(
1763
+ Input,
1764
+ {
1765
+ "aria-label": "Search columns",
1766
+ className: "table-settings-input",
1767
+ placeholder: "Search",
1768
+ rightIcon: rightIconForSearchInout,
1769
+ value: searchInputValue,
1770
+ onChange: handleSearchChange,
1771
+ onKeyDown: handleSearchKeyDown
1772
+ }
1773
+ )
1774
+ ] }),
1775
+ /* @__PURE__ */ jsxs("div", { className: "table-setting-column-search-nav", role: "status", children: [
1776
+ /* @__PURE__ */ jsx("span", { className: "table-setting-column-search-nav-count", children: searchMatchCount ? `${normalizedMatchIndex + 1}/${searchMatchCount}` : "0/0" }),
1777
+ /* @__PURE__ */ jsx(
1778
+ IconButton,
1779
+ {
1780
+ "aria-label": "Previous match",
1781
+ className: "table-setting-column-search-nav-btn",
1782
+ disabled: !searchMatchCount,
1783
+ onClick: onSearchUpArrowClick,
1784
+ children: /* @__PURE__ */ jsx(default_1, { fontSize: "small" })
1785
+ }
1786
+ ),
1787
+ /* @__PURE__ */ jsx(
1788
+ IconButton,
1789
+ {
1790
+ "aria-label": "Next match",
1791
+ className: "table-setting-column-search-nav-btn",
1792
+ disabled: !searchMatchCount,
1793
+ onClick: onSearchDownArrowClick,
1794
+ children: /* @__PURE__ */ jsx(default_1$1, { fontSize: "small" })
1795
+ }
1796
+ )
1797
+ ] })
1425
1798
  ] })
1426
1799
  ] }),
1427
1800
  !collapsedColumn && /* @__PURE__ */ jsx(
1428
1801
  "div",
1429
1802
  {
1430
- ref: collapseContainerRef,
1431
- className: `table-setting-column-collapse-container ${props.isSaveViewEnabled ? "save-view-enabled" : ""} ${shouldVirtualize ? "is-virtualized" : ""}`,
1803
+ className: `table-setting-column-collapse-container ${props.isSaveViewEnabled ? "save-view-enabled" : ""}`,
1432
1804
  children: /* @__PURE__ */ jsxs(
1433
1805
  DndContext,
1434
1806
  {
1435
- autoScroll: !shouldVirtualize,
1436
1807
  collisionDetection: closestCenter,
1437
1808
  sensors,
1438
1809
  onDragCancel: handleDragCancel,
1439
1810
  onDragEnd: handleDragEnd,
1440
- onDragMove: handleDragMove,
1441
1811
  onDragStart: handleDragStart,
1442
1812
  children: [
1443
1813
  /* @__PURE__ */ jsxs(SortableContext, { items: sortableItems, children: [
1444
1814
  frozenColumn.length > 0 && !(frozenColumn.length === 1 && frozenColumn[0].headerName === "N/A") && /* @__PURE__ */ jsxs("div", { className: "table-setting-collapse-columns-container", children: [
1445
- /* @__PURE__ */ jsx("h3", { children: t("table.columns.frozen") }),
1446
- shouldVirtualize ? /* @__PURE__ */ jsx(
1447
- VirtualColumnList,
1448
- {
1449
- className: "table-setting-frozen-columns-list",
1450
- itemData: frozenItemData,
1451
- maxHeight: listHeights.frozen,
1452
- outerElementType: FrozenListOuter,
1453
- outerRef: frozenListRef,
1454
- rows: frozenRows
1455
- }
1456
- ) : /* @__PURE__ */ jsx(
1815
+ /* @__PURE__ */ jsx("h3", { children: "Frozen columns" }),
1816
+ /* @__PURE__ */ jsx(
1457
1817
  "div",
1458
1818
  {
1459
- "aria-label": t("table.columns.frozen"),
1819
+ "aria-label": "Frozen columns",
1460
1820
  className: "table-setting-frozen-columns-list",
1461
1821
  role: "tree",
1462
1822
  children: filteredFrozenColumns.map(
@@ -1466,14 +1826,14 @@ const ColumnsV36 = forwardRef((props, ref) => {
1466
1826
  )
1467
1827
  ] }),
1468
1828
  /* @__PURE__ */ jsxs("div", { className: "table-setting-scroll-columns-container", children: [
1469
- /* @__PURE__ */ jsx("h3", { children: t("table.columns.scrollable") }),
1829
+ /* @__PURE__ */ jsx("h3", { children: "Scrollable Columns" }),
1470
1830
  /* @__PURE__ */ jsxs("div", { className: "table-setting-scroll-main-column-list", children: [
1471
1831
  /* @__PURE__ */ jsxs("div", { className: "table-setting-scroll-main-column", children: [
1472
1832
  /* @__PURE__ */ jsxs("div", { className: "table-setting-column-leading", children: [
1473
1833
  /* @__PURE__ */ jsx("span", { className: "table-setting-column-collapse-slot", children: /* @__PURE__ */ jsx(
1474
1834
  IconButton,
1475
1835
  {
1476
- "aria-label": collapsedScrollable ? t("table.columns.expandScrollable") : t("table.columns.collapseScrollable"),
1836
+ "aria-label": collapsedScrollable ? "Expand scrollable columns" : "Collapse scrollable columns",
1477
1837
  className: "table-setting-column-collapse-btn",
1478
1838
  onClick: toggleScrollableCollapse,
1479
1839
  children: collapsedScrollable ? /* @__PURE__ */ jsx(default_1$3, {}) : /* @__PURE__ */ jsx(default_1, {})
@@ -1482,29 +1842,19 @@ const ColumnsV36 = forwardRef((props, ref) => {
1482
1842
  /* @__PURE__ */ jsx(
1483
1843
  Checkbox,
1484
1844
  {
1485
- "aria-label": t("table.columns.toggleMain"),
1845
+ "aria-label": "Toggle main columns",
1486
1846
  checked: mainCheckState.checked,
1487
1847
  variant: mainCheckState.indeterminate ? "dashed" : "default",
1488
1848
  onChange: onMainCheckboxChange
1489
1849
  }
1490
1850
  )
1491
1851
  ] }),
1492
- /* @__PURE__ */ jsx("span", { className: "table-setting-column-name", children: t("table.columns.main") })
1852
+ /* @__PURE__ */ jsx("span", { className: "table-setting-column-name", children: "Main Column" })
1493
1853
  ] }),
1494
- shouldVirtualize ? /* @__PURE__ */ jsx(
1495
- VirtualColumnList,
1496
- {
1497
- className: "table-setting-scroll-inner-column-list",
1498
- itemData: scrollableItemData,
1499
- maxHeight: listHeights.scrollable,
1500
- outerElementType: ScrollableListOuter,
1501
- outerRef: scrollableListRef,
1502
- rows: scrollableRows
1503
- }
1504
- ) : /* @__PURE__ */ jsx(
1854
+ /* @__PURE__ */ jsx(
1505
1855
  "div",
1506
1856
  {
1507
- "aria-label": t("table.columns.scrollable"),
1857
+ "aria-label": "Scrollable columns",
1508
1858
  className: "table-setting-scroll-inner-column-list",
1509
1859
  role: "tree",
1510
1860
  children: !collapsedScrollable && filteredScrollableColumns.map(
@@ -1526,6 +1876,30 @@ const ColumnsV36 = forwardRef((props, ref) => {
1526
1876
  )
1527
1877
  ] });
1528
1878
  });
1879
+ const updateFontSizeOnToolPanel = (fontSizeType) => {
1880
+ let fontSize;
1881
+ switch (fontSizeType) {
1882
+ case "small":
1883
+ fontSize = "12px";
1884
+ break;
1885
+ case "medium":
1886
+ fontSize = "14px";
1887
+ break;
1888
+ case "large":
1889
+ fontSize = "16px";
1890
+ break;
1891
+ default:
1892
+ fontSize = "14px";
1893
+ }
1894
+ return fontSize;
1895
+ };
1529
1896
  export {
1530
- ColumnsV36
1897
+ Columns,
1898
+ freezeColumn,
1899
+ getMainMenuItems,
1900
+ getTableMeta,
1901
+ onColMenuAutoAdjustClick,
1902
+ onColMenuFreezeClick,
1903
+ sortFunc,
1904
+ updateFontSizeOnToolPanel
1531
1905
  };