impact-ui 4.0.1-alpha.20 → 4.0.1-alpha.21

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 (82) hide show
  1. package/dist/_virtual/index13.js +2 -2
  2. package/dist/_virtual/index14.js +2 -2
  3. package/dist/_virtual/index15.js +2 -2
  4. package/dist/_virtual/index16.js +2 -2
  5. package/dist/components/DateRangePicker/index.d.ts.map +1 -1
  6. package/dist/components/DateRangePicker/index.js +4 -0
  7. package/dist/components/Modal/Modal.types.d.ts +1 -1
  8. package/dist/components/Modal/Modal.types.d.ts.map +1 -1
  9. package/dist/components/Modal/index.js +1 -1
  10. package/dist/components/Notification/NotificationBody/NotificationList/NotificationListItem.d.ts.map +1 -1
  11. package/dist/components/Notification/NotificationBody/NotificationList/NotificationListItem.js +4 -1
  12. package/dist/components/Table/index.js +1 -1
  13. package/dist/components/TableChat/components/TableChatRightSection/ChatEditedMessageType /ChatEditedMessageType.d.ts.map +1 -0
  14. package/dist/components/TableChat/components/TableChatRightSection/ChatMessages/ChatMessage.js +1 -1
  15. package/dist/components/TableOld/index.js +1 -1
  16. package/dist/components/index.d.ts +0 -1
  17. package/dist/components/index.d.ts.map +1 -1
  18. package/dist/components/index.js +0 -2
  19. package/dist/mcp-component-registry.json +1 -1
  20. package/dist/node_modules/call-bind/index.js +1 -1
  21. package/dist/node_modules/hoist-non-react-statics/node_modules/react-is/index.js +1 -1
  22. package/dist/node_modules/is-symbol/index.js +1 -1
  23. package/dist/node_modules/react-with-styles-interface-css/dist/index.js +1 -1
  24. package/package.json +5 -5
  25. package/dist/components/TableChat/components/TableChatRightSection/ChatEditedMessageType/ChatEditedMessageType.d.ts.map +0 -1
  26. package/dist/components/TableV36/AdvanceSearchModalItem.d.ts +0 -27
  27. package/dist/components/TableV36/AdvanceSearchModalItem.d.ts.map +0 -1
  28. package/dist/components/TableV36/AdvanceSortModal.d.ts +0 -8
  29. package/dist/components/TableV36/AdvanceSortModal.d.ts.map +0 -1
  30. package/dist/components/TableV36/AdvanceSortModal.js +0 -297
  31. package/dist/components/TableV36/AgGridHeader.d.ts +0 -13
  32. package/dist/components/TableV36/AgGridHeader.d.ts.map +0 -1
  33. package/dist/components/TableV36/AgGridHeader.js +0 -781
  34. package/dist/components/TableV36/CommentsPortal.d.ts +0 -31
  35. package/dist/components/TableV36/CommentsPortal.d.ts.map +0 -1
  36. package/dist/components/TableV36/CommentsPortal.js +0 -362
  37. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModal.d.ts +0 -13
  38. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModal.d.ts.map +0 -1
  39. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModal.js +0 -282
  40. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModalItem.d.ts +0 -16
  41. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModalItem.d.ts.map +0 -1
  42. package/dist/components/TableV36/NewAdvanceSearchModal/NewAdvanceSearchModalItem.js +0 -302
  43. package/dist/components/TableV36/NoComments.d.ts +0 -16
  44. package/dist/components/TableV36/NoComments.d.ts.map +0 -1
  45. package/dist/components/TableV36/NoComments.js +0 -237
  46. package/dist/components/TableV36/Table.types.d.ts +0 -45
  47. package/dist/components/TableV36/Table.types.d.ts.map +0 -1
  48. package/dist/components/TableV36/actionBar.d.ts +0 -7
  49. package/dist/components/TableV36/actionBar.d.ts.map +0 -1
  50. package/dist/components/TableV36/actionBar.js +0 -31
  51. package/dist/components/TableV36/advanceSearchModal.d.ts +0 -20
  52. package/dist/components/TableV36/advanceSearchModal.d.ts.map +0 -1
  53. package/dist/components/TableV36/filterUtils.d.ts +0 -133
  54. package/dist/components/TableV36/filterUtils.d.ts.map +0 -1
  55. package/dist/components/TableV36/filterUtils.js +0 -478
  56. package/dist/components/TableV36/index.d.ts +0 -3
  57. package/dist/components/TableV36/index.d.ts.map +0 -1
  58. package/dist/components/TableV36/index.js +0 -1430
  59. package/dist/components/TableV36/mockData.d.ts +0 -39
  60. package/dist/components/TableV36/mockData.d.ts.map +0 -1
  61. package/dist/components/TableV36/tableFunctions.d.ts +0 -63
  62. package/dist/components/TableV36/tableFunctions.d.ts.map +0 -1
  63. package/dist/components/TableV36/tableFunctions.js +0 -1384
  64. package/dist/components/TableV36/tableHeader.d.ts +0 -80
  65. package/dist/components/TableV36/tableHeader.d.ts.map +0 -1
  66. package/dist/components/TableV36/tableHeader.js +0 -396
  67. package/dist/components/TableV36/tableIcons.d.ts +0 -3
  68. package/dist/components/TableV36/tableIcons.d.ts.map +0 -1
  69. package/dist/components/TableV36/tableMoreOptions.d.ts +0 -52
  70. package/dist/components/TableV36/tableMoreOptions.d.ts.map +0 -1
  71. package/dist/components/TableV36/tableMoreOptions.js +0 -324
  72. package/dist/components/TableV36/tablePagination.d.ts +0 -7
  73. package/dist/components/TableV36/tablePagination.d.ts.map +0 -1
  74. package/dist/components/TableV36/tablePagination.js +0 -67
  75. package/dist/components/TableV36/tableSettings.d.ts +0 -41
  76. package/dist/components/TableV36/tableSettings.d.ts.map +0 -1
  77. package/dist/components/TableV36/tableSettings.js +0 -278
  78. package/dist/components/TableV36/withCommentIcon.d.ts +0 -2
  79. package/dist/components/TableV36/withCommentIcon.d.ts.map +0 -1
  80. package/dist/components/TableV36/withCommentIcon.js +0 -83
  81. /package/dist/components/TableChat/components/TableChatRightSection/{ChatEditedMessageType → ChatEditedMessageType }/ChatEditedMessageType.d.ts +0 -0
  82. /package/dist/components/TableChat/components/TableChatRightSection/{ChatEditedMessageType → ChatEditedMessageType }/ChatEditedMessageType.js +0 -0
@@ -1,278 +0,0 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
2
- import { useState, useEffect } from "react";
3
- import default_1$2 from "../../node_modules/@mui/icons-material/AutoFixHigh.js";
4
- import default_1$1 from "../../node_modules/@mui/icons-material/FormatColorTextOutlined.js";
5
- import default_1 from "../../node_modules/@mui/icons-material/ViewColumnOutlined.js";
6
- import { RadioButtonGroup } from "../RadioButtonGroup/index.js";
7
- import { Tabs } from "../Tabs/index.js";
8
- function TableSettings({
9
- showMenu,
10
- Columns,
11
- actualRef,
12
- tableFontSize,
13
- setTableFontSize,
14
- handleMenuClick,
15
- onNumberFormatChange,
16
- colDefs,
17
- setShowMenu,
18
- showTableSetting,
19
- setShowTableSetting,
20
- setTableSettingOpen,
21
- tableActions,
22
- onTableActionsTabClick,
23
- showFilterStrip,
24
- hideTableFormat,
25
- hideTableActions,
26
- savedViewsOptions,
27
- handleSaveAndApply,
28
- maxSavedViews,
29
- handleSavedViewClick,
30
- handleEditSaveView,
31
- isSaveViewEnabled,
32
- isSavingViewLoading,
33
- handleDeleteViewClick,
34
- isDeleteViewLoading,
35
- handleSetDefaultView,
36
- hideNumericFormat,
37
- hideFontSize,
38
- customTabInTableSettings,
39
- saveViewCustomFilter,
40
- customRenderSaveViewContent,
41
- onTableSettingClick,
42
- deleteViewPromptText,
43
- isViewNameUniqueAcrossTypes,
44
- tableSettingsTitle = "Table Settings",
45
- registerTableSettingToggle,
46
- numericFormatDefault
47
- }) {
48
- const [selectedMenuTab, setSelectedMenuTab] = useState("Columns");
49
- const [numericFormat, setNumericFormat] = useState(numericFormatDefault || "full_no");
50
- const onFontSizeChange = (val) => {
51
- setTableFontSize(val);
52
- };
53
- const onNumericFormatChange = (val) => {
54
- setNumericFormat(val);
55
- onNumberFormatChange(val);
56
- };
57
- useEffect(() => {
58
- setNumericFormat(numericFormatDefault);
59
- }, [numericFormatDefault]);
60
- const tabPanels = [
61
- /* @__PURE__ */ jsx(
62
- Columns,
63
- {
64
- ref: actualRef,
65
- column: colDefs,
66
- customRenderSaveViewContent,
67
- deleteViewPromptText,
68
- handleDeleteViewClick,
69
- handleEditSaveView,
70
- handleSaveAndApply,
71
- handleSavedViewClick,
72
- handleSetDefaultView,
73
- isDeleteViewLoading,
74
- isSaveViewEnabled,
75
- isSavingViewLoading,
76
- isViewNameUniqueAcrossTypes,
77
- maxSavedViews,
78
- savedViewsOptions,
79
- saveViewCustomFilter,
80
- showMenu
81
- }
82
- ),
83
- !hideTableFormat && /* @__PURE__ */ jsx(
84
- TableFormat,
85
- {
86
- hideFontSize,
87
- hideNumericFormat,
88
- numericFormat,
89
- tableFontSize,
90
- onFontSizeChange,
91
- onNumericFormatChange
92
- }
93
- ),
94
- !hideTableActions && /* @__PURE__ */ jsx(TableActions, { tableActions }),
95
- ...Array.isArray(customTabInTableSettings) ? customTabInTableSettings.map((tab) => tab == null ? void 0 : tab.tabPanels) : []
96
- ].filter(Boolean);
97
- const tabNames = [
98
- {
99
- label: selectedMenuTab === "Columns" ? "Columns" : "",
100
- value: "Columns",
101
- icon: /* @__PURE__ */ jsx(default_1, { fontSize: "small" })
102
- },
103
- !hideTableFormat && {
104
- label: selectedMenuTab === "Format" ? "Format" : "",
105
- value: "Format",
106
- icon: /* @__PURE__ */ jsx(default_1$1, { fontSize: "small" })
107
- },
108
- !hideTableActions && {
109
- label: selectedMenuTab === "Actions" ? "Actions" : "",
110
- value: "Actions",
111
- icon: /* @__PURE__ */ jsx(default_1$2, {})
112
- },
113
- ...Array.isArray(customTabInTableSettings) ? customTabInTableSettings.map((tab) => {
114
- var _a, _b;
115
- return {
116
- ...tab.tabNames,
117
- label: selectedMenuTab === ((_a = tab == null ? void 0 : tab.tabNames) == null ? void 0 : _a.value) ? (_b = tab == null ? void 0 : tab.tabNames) == null ? void 0 : _b.label : ""
118
- };
119
- }) : []
120
- ].filter(Boolean);
121
- const onCloseTableSetting = (e) => {
122
- setSelectedMenuTab("Columns");
123
- setShowMenu(false);
124
- setShowTableSetting(false);
125
- setTableSettingOpen(false);
126
- onTableSettingClick(false);
127
- };
128
- useEffect(() => {
129
- if (typeof registerTableSettingToggle === "function") {
130
- const toggle = (open, tabName, options = {}) => {
131
- const shouldOpen = typeof open === "undefined" ? !showTableSetting : Boolean(open);
132
- if (shouldOpen) {
133
- if (options.menuOnly) {
134
- setShowMenu(true);
135
- } else {
136
- setShowMenu(true);
137
- setShowTableSetting(true);
138
- setTableSettingOpen(true);
139
- if (tabName) {
140
- setSelectedMenuTab(tabName);
141
- }
142
- onTableSettingClick(true);
143
- }
144
- } else {
145
- if (options.menuOnly) {
146
- setShowMenu(false);
147
- } else {
148
- onCloseTableSetting();
149
- }
150
- }
151
- };
152
- registerTableSettingToggle(toggle);
153
- }
154
- }, [
155
- registerTableSettingToggle,
156
- showTableSetting,
157
- setShowMenu,
158
- setShowTableSetting,
159
- setTableSettingOpen,
160
- onTableSettingClick
161
- ]);
162
- return /* @__PURE__ */ jsxs(
163
- "div",
164
- {
165
- className: `table-setting-main-container ${showTableSetting ? "display-table-setting" : ""} ${showFilterStrip ? "filters-strip-visible" : ""}`,
166
- children: [
167
- /* @__PURE__ */ jsxs("div", { className: "table-setting-header", children: [
168
- /* @__PURE__ */ jsx("h2", { children: tableSettingsTitle }),
169
- /* @__PURE__ */ jsx(
170
- "span",
171
- {
172
- className: "close_icon",
173
- role: "button",
174
- tabIndex: 0,
175
- onClick: onCloseTableSetting,
176
- onKeyDown: (e) => {
177
- if (e.key === "Enter" || e.key === " ") {
178
- e.preventDefault();
179
- onCloseTableSetting();
180
- }
181
- }
182
- }
183
- )
184
- ] }),
185
- /* @__PURE__ */ jsx(
186
- Tabs,
187
- {
188
- remountOnTabChange: false,
189
- tabNames,
190
- tabPanels,
191
- value: selectedMenuTab,
192
- onChange: (_event, val) => {
193
- setSelectedMenuTab(val);
194
- if (val === "Actions") {
195
- onTableActionsTabClick();
196
- }
197
- }
198
- }
199
- )
200
- ]
201
- }
202
- );
203
- }
204
- const TableFormat = ({
205
- tableFontSize,
206
- onFontSizeChange,
207
- numericFormat,
208
- onNumericFormatChange,
209
- hideNumericFormat,
210
- hideFontSize
211
- }) => {
212
- return /* @__PURE__ */ jsxs("div", { className: "table-setting-format-settings", children: [
213
- !hideFontSize && /* @__PURE__ */ jsxs("div", { className: "table-setting-font-size-setting-container", children: [
214
- /* @__PURE__ */ jsx("h3", { className: "custom-menu-sub-header", children: "Font size" }),
215
- /* @__PURE__ */ jsx(
216
- RadioButtonGroup,
217
- {
218
- options: [
219
- {
220
- label: "Small",
221
- value: "small"
222
- },
223
- {
224
- label: "Medium (default)",
225
- value: "medium"
226
- },
227
- {
228
- label: "Large",
229
- value: "large"
230
- }
231
- ],
232
- selectedOption: "medium",
233
- value: tableFontSize,
234
- onChange: (_e, val) => {
235
- onFontSizeChange(val);
236
- }
237
- }
238
- )
239
- ] }),
240
- !hideNumericFormat && /* @__PURE__ */ jsxs("div", { className: "table-setting-number-format-setting-container", children: [
241
- /* @__PURE__ */ jsx("h3", { className: "custom-menu-sub-header", children: "Numeric Values" }),
242
- /* @__PURE__ */ jsx(
243
- RadioButtonGroup,
244
- {
245
- options: [
246
- {
247
- label: "Full Number",
248
- value: "full_no"
249
- },
250
- {
251
- label: "In K (Thousands)",
252
- value: "thou"
253
- },
254
- {
255
- label: "In M (Millions)",
256
- value: "mil"
257
- },
258
- {
259
- label: "In B (Billions)",
260
- value: "bil"
261
- }
262
- ],
263
- selectedOption: "full_no",
264
- value: numericFormat,
265
- onChange: (_e, val) => {
266
- onNumericFormatChange(val);
267
- }
268
- }
269
- )
270
- ] })
271
- ] });
272
- };
273
- const TableActions = ({ tableActions }) => {
274
- return /* @__PURE__ */ jsx("div", { className: "table-setting-action-settings", children: /* @__PURE__ */ jsx("div", { className: "table-setting-action-container", children: tableActions }) });
275
- };
276
- export {
277
- TableSettings as default
278
- };
@@ -1,2 +0,0 @@
1
- export declare const withCommentIcon: (Renderer: any) => (props: any) => import("react/jsx-runtime").JSX.Element;
2
- //# sourceMappingURL=withCommentIcon.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"withCommentIcon.d.ts","sourceRoot":"","sources":["../../../src/components/TableV36/withCommentIcon.tsx"],"names":[],"mappings":"AAOA,eAAO,MAAM,eAAe,GAAI,aAAQ,MAC9B,UAAK,4CAgGd,CAAC"}
@@ -1,83 +0,0 @@
1
- import { jsx, Fragment, jsxs } from "react/jsx-runtime";
2
- import { useRef } from "react";
3
- import { getAssetUrl } from "../../utils/assetBase.js";
4
- const CommentIndicator = (props) => /* @__PURE__ */ jsx("img", { alt: "", src: getAssetUrl("icons/comment-indicator.svg"), ...props });
5
- const withCommentIcon = (Renderer) => {
6
- return (props) => {
7
- var _a, _b;
8
- const iconRef = useRef(null);
9
- const {
10
- handleCommentIconHover,
11
- handleMouseEnter,
12
- handleMouseLeave,
13
- popup,
14
- resolvedComments,
15
- getLatestUnresolvedThreadId,
16
- configuration,
17
- colIdentifierKey
18
- } = props.context;
19
- const rowIdentifier = colIdentifierKey ? ((_a = props.data) == null ? void 0 : _a[colIdentifierKey]) || props.node.id : props.node.id;
20
- const baseCellId = `${rowIdentifier}__${props.column.getColId()}`;
21
- let effectiveCellId = baseCellId;
22
- if ((popup == null ? void 0 : popup.cellId) != baseCellId && !(configuration == null ? void 0 : configuration.disableMultiCommentThread)) {
23
- const baseResolved = Array.isArray(resolvedComments) ? resolvedComments.includes(baseCellId) : false;
24
- if (baseResolved) {
25
- const latestUnresolved = getLatestUnresolvedThreadId(baseCellId);
26
- if (latestUnresolved) {
27
- effectiveCellId = latestUnresolved;
28
- } else {
29
- effectiveCellId = baseCellId;
30
- }
31
- }
32
- }
33
- const commentsArray = (_b = props.context.comments) == null ? void 0 : _b[effectiveCellId];
34
- const hasComment = commentsArray && Array.isArray(commentsArray) && commentsArray.length > 0;
35
- const isPortalOpen = (popup == null ? void 0 : popup.cellId) === effectiveCellId;
36
- const displayValue = props.valueFormatted !== void 0 && props.valueFormatted !== null ? props.valueFormatted : props.value;
37
- const safeValue = displayValue !== null && typeof displayValue === "object" ? JSON.stringify(displayValue) : displayValue ?? "";
38
- const Content = Renderer ? /* @__PURE__ */ jsx(Renderer, { ...props }) : /* @__PURE__ */ jsx(Fragment, { children: safeValue });
39
- const isResolved = Array.isArray(resolvedComments) && resolvedComments.find((comment) => comment === effectiveCellId);
40
- return /* @__PURE__ */ jsxs(Fragment, { children: [
41
- /* @__PURE__ */ jsx(
42
- "div",
43
- {
44
- style: {
45
- position: "absolute",
46
- top: 0,
47
- left: 0,
48
- right: 0,
49
- bottom: 0,
50
- border: hasComment && isPortalOpen ? "1px solid #4259ee" : "none",
51
- boxSizing: "border-box",
52
- pointerEvents: "none",
53
- zIndex: 1
54
- }
55
- }
56
- ),
57
- Content,
58
- hasComment && !isResolved && /* @__PURE__ */ jsx(
59
- "div",
60
- {
61
- ref: iconRef,
62
- style: {
63
- position: "absolute",
64
- top: -15,
65
- right: 0,
66
- cursor: "pointer",
67
- zIndex: 2
68
- },
69
- title: `${commentsArray.length} comment${commentsArray.length > 1 ? "s" : ""}`,
70
- onMouseLeave: handleMouseLeave,
71
- onMouseOver: () => {
72
- handleMouseEnter();
73
- handleCommentIconHover(props);
74
- },
75
- children: /* @__PURE__ */ jsx(CommentIndicator, {})
76
- }
77
- )
78
- ] });
79
- };
80
- };
81
- export {
82
- withCommentIcon
83
- };