@carbon/ibm-products 2.0.0-rc.1 → 2.0.0-rc.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (241) hide show
  1. package/css/index-full-carbon.css +952 -143
  2. package/css/index-full-carbon.css.map +1 -1
  3. package/css/index-full-carbon.min.css +4 -2
  4. package/css/index-full-carbon.min.css.map +1 -1
  5. package/css/index-without-carbon-released-only.css +783 -19
  6. package/css/index-without-carbon-released-only.css.map +1 -1
  7. package/css/index-without-carbon-released-only.min.css +4 -2
  8. package/css/index-without-carbon-released-only.min.css.map +1 -1
  9. package/css/index-without-carbon.css +678 -77
  10. package/css/index-without-carbon.css.map +1 -1
  11. package/css/index-without-carbon.min.css +4 -2
  12. package/css/index-without-carbon.min.css.map +1 -1
  13. package/css/index.css +757 -92
  14. package/css/index.css.map +1 -1
  15. package/css/index.min.css +4 -2
  16. package/css/index.min.css.map +1 -1
  17. package/es/components/APIKeyModal/APIKeyModal.js +1 -1
  18. package/es/components/AddSelect/AddSelect.js +0 -3
  19. package/es/components/AddSelect/AddSelectBody.js +20 -3
  20. package/es/components/AddSelect/AddSelectBreadcrumbs.js +11 -3
  21. package/es/components/AddSelect/AddSelectColumn.js +5 -5
  22. package/es/components/AddSelect/AddSelectFilter.js +5 -4
  23. package/es/components/AddSelect/AddSelectList.js +61 -27
  24. package/es/components/AddSelect/AddSelectMetaPanel.js +1 -1
  25. package/es/components/AddSelect/AddSelectSort.js +1 -1
  26. package/es/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +4 -6
  27. package/es/components/Card/Card.js +16 -6
  28. package/es/components/Card/CardFooter.js +3 -1
  29. package/es/components/Card/CardHeader.js +20 -1
  30. package/es/components/ComboButton/ComboButton.js +1 -1
  31. package/es/components/DataSpreadsheet/DataSpreadsheet.js +63 -11
  32. package/es/components/DataSpreadsheet/DataSpreadsheetBody.js +2 -1
  33. package/es/components/DataSpreadsheet/DataSpreadsheetHeader.js +7 -0
  34. package/es/components/DataSpreadsheet/hooks/useMultipleKeyTracking.js +6 -5
  35. package/es/components/DataSpreadsheet/utils/handleCellDeletion.js +31 -0
  36. package/es/components/DataSpreadsheet/utils/handleMultipleKeys.js +1 -1
  37. package/es/components/Datagrid/Datagrid/Datagrid.js +10 -38
  38. package/es/components/Datagrid/Datagrid/DatagridContent.js +149 -0
  39. package/es/components/Datagrid/Datagrid/DatagridExpandedRow.js +9 -1
  40. package/es/components/Datagrid/Datagrid/DatagridRow.js +10 -2
  41. package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +10 -3
  42. package/es/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +13 -4
  43. package/es/components/Datagrid/Datagrid/DatagridToolbar.js +5 -4
  44. package/es/components/Datagrid/Datagrid/DraggableElement.js +6 -2
  45. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.js +5 -45
  46. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +1 -1
  47. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +35 -10
  48. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsModal.js +61 -24
  49. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/ModalWrapper.js +3 -2
  50. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +60 -0
  51. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/index.js +1 -0
  52. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +534 -0
  53. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/index.js +1 -0
  54. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js +112 -0
  55. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/getCellIdAsObject.js +27 -0
  56. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/index.js +1 -0
  57. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/returnUpdatedActiveCell.js +39 -0
  58. package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleGridFocus.js +19 -0
  59. package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +263 -0
  60. package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleMultipleKeys.js +87 -0
  61. package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +17 -14
  62. package/es/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +13 -36
  63. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/CustomizeColumnStory.js +0 -0
  64. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/LeftPanelStory.js +0 -0
  65. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/RowSizeDropdownStory.js +0 -0
  66. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/SelectAllWithToggleStory.js +0 -0
  67. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/StickyActionsColumnStory.js +0 -0
  68. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/common.js +0 -0
  69. package/es/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/index.js +0 -0
  70. package/es/components/Datagrid/index.js +3 -1
  71. package/es/components/Datagrid/useActionsColumn.js +28 -12
  72. package/es/components/Datagrid/useColumnOrder.js +8 -0
  73. package/es/components/Datagrid/useCustomizeColumns.js +5 -0
  74. package/es/components/Datagrid/useDefaultStringRenderer.js +4 -1
  75. package/es/components/Datagrid/useDisableSelectRows.js +6 -2
  76. package/es/components/Datagrid/useExpandedRow.js +0 -1
  77. package/es/components/Datagrid/useInlineEdit.js +71 -0
  78. package/es/components/Datagrid/useNestedRowExpander.js +42 -0
  79. package/es/components/Datagrid/useNestedRows.js +2 -2
  80. package/es/components/Datagrid/useRowExpander.js +1 -1
  81. package/es/components/Datagrid/useRowSize.js +17 -6
  82. package/es/components/Datagrid/useSelectAllToggle.js +17 -4
  83. package/es/components/Datagrid/useSelectRows.js +12 -2
  84. package/es/components/Datagrid/useSortableColumns.js +1 -1
  85. package/es/components/Datagrid/useStickyColumn.js +11 -0
  86. package/es/components/Datagrid/utils/DatagridActions.js +152 -0
  87. package/es/components/Datagrid/utils/DatagridPagination.js +33 -0
  88. package/es/components/Datagrid/utils/Wrapper.js +21 -0
  89. package/es/components/Datagrid/utils/getArgTypes.js +85 -0
  90. package/es/components/Datagrid/utils/getInlineEditColumns.js +153 -0
  91. package/es/components/Datagrid/utils/makeData.js +47 -2
  92. package/es/components/ExportModal/ExportModal.js +1 -1
  93. package/es/components/ImportModal/ImportModal.js +3 -3
  94. package/es/components/InlineEdit/InlineEdit.js +11 -9
  95. package/es/components/ModifiedTabs/ModifiedTabLabelNew.js +1 -1
  96. package/es/components/ModifiedTabs/ModifiedTabLabelWithClose.js +1 -1
  97. package/es/components/NotificationsPanel/NotificationsPanel.js +1 -1
  98. package/es/components/OptionsTile/OptionsTile.js +1 -1
  99. package/es/components/PageHeader/PageHeader.js +1 -1
  100. package/es/components/ProductiveCard/ProductiveCard.js +5 -0
  101. package/es/components/Saving/Saving.js +1 -1
  102. package/es/components/SidePanel/SidePanel.js +1 -1
  103. package/es/components/StatusIcon/StatusIcon.js +1 -1
  104. package/es/components/UserProfileImage/UserProfileImage.js +1 -1
  105. package/es/components/WebTerminal/WebTerminal.js +2 -2
  106. package/es/components/WebTerminal/WebTerminalContentWrapper.js +1 -1
  107. package/es/components/WebTerminal/hooks/index.js +6 -0
  108. package/es/components/WebTerminal/index.js +6 -0
  109. package/es/components/WebTerminal/preview-components/Navigation.js +7 -1
  110. package/es/components/WebTerminal/preview-components/documentationLinks.js +6 -0
  111. package/es/components/WebTerminal/preview-components/index.js +7 -0
  112. package/es/components/index.js +1 -1
  113. package/es/global/js/hooks/useClickOutside.js +1 -1
  114. package/es/global/js/package-settings.js +3 -3
  115. package/es/global/js/utils/rangeWithCallback.js +13 -0
  116. package/es/global/js/utils/story-helper.js +5 -1
  117. package/es/global/js/utils/uuidv4.spec.js +4 -0
  118. package/lib/components/APIKeyModal/APIKeyModal.js +4 -4
  119. package/lib/components/AddSelect/AddSelect.js +0 -4
  120. package/lib/components/AddSelect/AddSelectBody.js +20 -3
  121. package/lib/components/AddSelect/AddSelectBreadcrumbs.js +14 -3
  122. package/lib/components/AddSelect/AddSelectColumn.js +5 -5
  123. package/lib/components/AddSelect/AddSelectFilter.js +5 -4
  124. package/lib/components/AddSelect/AddSelectList.js +62 -28
  125. package/lib/components/AddSelect/AddSelectMetaPanel.js +2 -2
  126. package/lib/components/AddSelect/AddSelectSort.js +4 -4
  127. package/lib/components/BreadcrumbWithOverflow/BreadcrumbWithOverflow.js +6 -6
  128. package/lib/components/Card/Card.js +16 -6
  129. package/lib/components/Card/CardFooter.js +3 -1
  130. package/lib/components/Card/CardHeader.js +21 -1
  131. package/lib/components/ComboButton/ComboButton.js +3 -3
  132. package/lib/components/DataSpreadsheet/DataSpreadsheet.js +63 -10
  133. package/lib/components/DataSpreadsheet/DataSpreadsheetBody.js +2 -1
  134. package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.js +7 -0
  135. package/lib/components/DataSpreadsheet/hooks/useMultipleKeyTracking.js +6 -5
  136. package/lib/components/DataSpreadsheet/utils/handleCellDeletion.js +42 -0
  137. package/lib/components/DataSpreadsheet/utils/handleMultipleKeys.js +1 -1
  138. package/lib/components/Datagrid/Datagrid/Datagrid.js +12 -45
  139. package/lib/components/Datagrid/Datagrid/DatagridContent.js +183 -0
  140. package/lib/components/Datagrid/Datagrid/DatagridExpandedRow.js +9 -1
  141. package/lib/components/Datagrid/Datagrid/DatagridRow.js +19 -2
  142. package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +12 -3
  143. package/lib/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +16 -5
  144. package/lib/components/Datagrid/Datagrid/DatagridToolbar.js +6 -5
  145. package/lib/components/Datagrid/Datagrid/DraggableElement.js +7 -3
  146. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Actions.js +12 -47
  147. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ButtonWrapper.js +2 -2
  148. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/Columns.js +47 -25
  149. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsModal.js +59 -23
  150. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/ModalWrapper.js +3 -2
  151. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +76 -0
  152. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/index.js +13 -0
  153. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +558 -0
  154. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/index.js +13 -0
  155. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/InlineEditContext.js +129 -0
  156. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/getCellIdAsObject.js +36 -0
  157. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/index.js +19 -0
  158. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditContext/returnUpdatedActiveCell.js +45 -0
  159. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridFocus.js +28 -0
  160. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +272 -0
  161. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleMultipleKeys.js +100 -0
  162. package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeDropdown.js +17 -13
  163. package/lib/components/Datagrid/Datagrid/addons/RowSize/RowSizeRadioGroup.js +13 -35
  164. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/CustomizeColumnStory.js +0 -0
  165. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/LeftPanelStory.js +0 -0
  166. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/RowSizeDropdownStory.js +0 -0
  167. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/SelectAllWithToggleStory.js +0 -0
  168. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/StickyActionsColumnStory.js +0 -0
  169. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/common.js +0 -0
  170. package/lib/components/Datagrid/{Datagrid.stories-helpers → Datagrid.stories}/index.js +0 -0
  171. package/lib/components/Datagrid/index.js +17 -1
  172. package/lib/components/Datagrid/useActionsColumn.js +28 -13
  173. package/lib/components/Datagrid/useColumnOrder.js +17 -0
  174. package/lib/components/Datagrid/useCustomizeColumns.js +5 -0
  175. package/lib/components/Datagrid/useDefaultStringRenderer.js +5 -1
  176. package/lib/components/Datagrid/useDisableSelectRows.js +6 -2
  177. package/lib/components/Datagrid/useExpandedRow.js +0 -1
  178. package/lib/components/Datagrid/useInlineEdit.js +85 -0
  179. package/lib/components/Datagrid/useNestedRowExpander.js +57 -0
  180. package/lib/components/Datagrid/useNestedRows.js +3 -3
  181. package/lib/components/Datagrid/useRowExpander.js +3 -3
  182. package/lib/components/Datagrid/useRowSize.js +18 -13
  183. package/lib/components/Datagrid/useSelectAllToggle.js +18 -4
  184. package/lib/components/Datagrid/useSelectRows.js +12 -2
  185. package/lib/components/Datagrid/useSortableColumns.js +5 -5
  186. package/lib/components/Datagrid/useStickyColumn.js +11 -0
  187. package/lib/components/Datagrid/utils/DatagridActions.js +170 -0
  188. package/lib/components/Datagrid/utils/DatagridPagination.js +46 -0
  189. package/lib/components/Datagrid/utils/Wrapper.js +33 -0
  190. package/lib/components/Datagrid/utils/getArgTypes.js +93 -0
  191. package/lib/components/Datagrid/utils/getInlineEditColumns.js +168 -0
  192. package/lib/components/Datagrid/utils/makeData.js +48 -2
  193. package/lib/components/ExportModal/ExportModal.js +3 -3
  194. package/lib/components/ImportModal/ImportModal.js +4 -4
  195. package/lib/components/InlineEdit/InlineEdit.js +16 -14
  196. package/lib/components/ModifiedTabs/ModifiedTabLabelNew.js +2 -2
  197. package/lib/components/ModifiedTabs/ModifiedTabLabelWithClose.js +3 -3
  198. package/lib/components/NotificationsPanel/NotificationsPanel.js +8 -8
  199. package/lib/components/OptionsTile/OptionsTile.js +6 -6
  200. package/lib/components/PageHeader/PageHeader.js +2 -2
  201. package/lib/components/ProductiveCard/ProductiveCard.js +5 -0
  202. package/lib/components/Saving/Saving.js +5 -5
  203. package/lib/components/SidePanel/SidePanel.js +3 -3
  204. package/lib/components/StatusIcon/StatusIcon.js +45 -45
  205. package/lib/components/UserProfileImage/UserProfileImage.js +7 -7
  206. package/lib/components/WebTerminal/WebTerminal.js +3 -3
  207. package/lib/components/WebTerminal/hooks/index.js +6 -0
  208. package/lib/components/WebTerminal/preview-components/Navigation.js +10 -4
  209. package/lib/components/WebTerminal/preview-components/documentationLinks.js +6 -0
  210. package/lib/components/index.js +12 -0
  211. package/lib/global/js/hooks/useClickOutside.js +1 -1
  212. package/lib/global/js/package-settings.js +3 -3
  213. package/lib/global/js/utils/rangeWithCallback.js +22 -0
  214. package/lib/global/js/utils/story-helper.js +5 -1
  215. package/lib/global/js/utils/uuidv4.spec.js +4 -0
  216. package/package.json +15 -15
  217. package/scss/components/AddSelect/_add-select.scss +127 -28
  218. package/scss/components/Card/_card.scss +1 -0
  219. package/scss/components/Cascade/_cascade.scss +1 -1
  220. package/scss/components/CreateTearsheet/_create-tearsheet.scss +2 -0
  221. package/scss/components/Datagrid/_datagrid.scss +7 -0
  222. package/scss/components/Datagrid/_storybook-styles.scss +8 -5
  223. package/scss/components/Datagrid/styles/_datagrid.scss +38 -14
  224. package/scss/components/Datagrid/styles/_draggableElement.scss +26 -9
  225. package/scss/components/Datagrid/styles/_index.scss +1 -0
  226. package/scss/components/Datagrid/styles/_useActionsColumn.scss +14 -0
  227. package/scss/components/Datagrid/styles/_useExpandedRow.scss +37 -9
  228. package/scss/components/Datagrid/styles/_useInlineEdit.scss +404 -0
  229. package/scss/components/Datagrid/styles/_useNestedRows.scss +16 -1
  230. package/scss/components/Datagrid/styles/_useStickyColumn.scss +31 -2
  231. package/scss/components/Datagrid/styles/addons/_CustomizeColumnsModal.scss +45 -6
  232. package/scss/components/Datagrid/styles/addons/_RowSizeDropdown.scss +9 -1
  233. package/scss/components/InlineEdit/_inline-edit.scss +4 -2
  234. package/scss/components/NotificationsPanel/_notifications-panel.scss +3 -6
  235. package/scss/components/RemoveModal/_remove-modal.scss +0 -4
  236. package/scss/components/SidePanel/_side-panel.scss +3 -6
  237. package/scss/components/Tearsheet/_tearsheet.scss +2 -2
  238. package/scss/components/WebTerminal/_carbon-imports.scss +6 -0
  239. package/scss/components/WebTerminal/_index.scss +7 -0
  240. package/scss/components/WebTerminal/_storybook-styles.scss +7 -0
  241. package/scss/components/_index-released-only.scss +1 -0
@@ -0,0 +1,152 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
2
+
3
+ /**
4
+ * Copyright IBM Corp. 2020, 2022
5
+ *
6
+ * This source code is licensed under the Apache-2.0 license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
+ import React from 'react';
10
+ import { DataTable, Button } from '@carbon/react';
11
+ import { Download, Filter, Add, Restart } from '@carbon/react/icons';
12
+ import { action } from '@storybook/addon-actions';
13
+ import { pkg } from '../../../settings';
14
+ import { ButtonMenu, ButtonMenuItem } from '../../ButtonMenu';
15
+ var blockClass = "".concat(pkg.prefix, "--datagrid");
16
+ export var DatagridActions = function DatagridActions(datagridState) {
17
+ var selectedFlatRows = datagridState.selectedFlatRows,
18
+ setGlobalFilter = datagridState.setGlobalFilter,
19
+ CustomizeColumnsButton = datagridState.CustomizeColumnsButton,
20
+ RowSizeDropdown = datagridState.RowSizeDropdown,
21
+ rowSizeDropdownProps = datagridState.rowSizeDropdownProps,
22
+ useDenseHeader = datagridState.useDenseHeader;
23
+
24
+ var downloadCsv = function downloadCsv() {
25
+ alert('Downloading...');
26
+ };
27
+
28
+ var TableToolbarContent = DataTable.TableToolbarContent,
29
+ TableToolbarSearch = DataTable.TableToolbarSearch;
30
+
31
+ var refreshColumns = function refreshColumns() {
32
+ alert('refreshing...');
33
+ };
34
+
35
+ var leftPanelClick = function leftPanelClick() {
36
+ alert('open/close left panel...');
37
+ };
38
+
39
+ var searchForAColumn = 'Search';
40
+ var isNothingSelected = selectedFlatRows.length === 0;
41
+ var style = {
42
+ 'button:nth-child(1) > span:nth-child(1)': {
43
+ bottom: '-37px'
44
+ }
45
+ };
46
+ return isNothingSelected && (useDenseHeader && useDenseHeader ? /*#__PURE__*/React.createElement(TableToolbarContent, {
47
+ size: "sm"
48
+ }, /*#__PURE__*/React.createElement("div", {
49
+ style: style
50
+ }, /*#__PURE__*/React.createElement(Button, {
51
+ kind: "ghost",
52
+ hasIconOnly: true,
53
+ tooltipPosition: "bottom",
54
+ renderIcon: function renderIcon(props) {
55
+ return /*#__PURE__*/React.createElement(Download, _extends({
56
+ size: 16
57
+ }, props));
58
+ },
59
+ iconDescription: 'Download CSV',
60
+ onClick: downloadCsv
61
+ })), /*#__PURE__*/React.createElement("div", {
62
+ style: style
63
+ }, /*#__PURE__*/React.createElement(Button, {
64
+ kind: "ghost",
65
+ hasIconOnly: true,
66
+ tooltipPosition: "bottom",
67
+ renderIcon: function renderIcon(props) {
68
+ return /*#__PURE__*/React.createElement(Filter, _extends({
69
+ size: 16
70
+ }, props));
71
+ },
72
+ iconDescription: 'Left panel',
73
+ onClick: leftPanelClick
74
+ })), /*#__PURE__*/React.createElement(RowSizeDropdown, rowSizeDropdownProps), /*#__PURE__*/React.createElement("div", {
75
+ style: style,
76
+ className: "".concat(blockClass, "__toolbar-divider")
77
+ }, /*#__PURE__*/React.createElement(Button, {
78
+ kind: "ghost",
79
+ renderIcon: function renderIcon(props) {
80
+ return /*#__PURE__*/React.createElement(Add, _extends({
81
+ size: 16
82
+ }, props));
83
+ },
84
+ iconDescription: 'Action'
85
+ }, "Ghost button")), CustomizeColumnsButton && /*#__PURE__*/React.createElement("div", {
86
+ style: style
87
+ }, /*#__PURE__*/React.createElement(CustomizeColumnsButton, null))) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Button, {
88
+ kind: "ghost",
89
+ hasIconOnly: true,
90
+ tooltipPosition: "bottom",
91
+ renderIcon: function renderIcon(props) {
92
+ return /*#__PURE__*/React.createElement(Filter, _extends({
93
+ size: 16
94
+ }, props));
95
+ },
96
+ iconDescription: 'Left panel',
97
+ onClick: leftPanelClick
98
+ }), /*#__PURE__*/React.createElement(TableToolbarContent, null, /*#__PURE__*/React.createElement(TableToolbarSearch, {
99
+ size: "lg",
100
+ id: "columnSearch",
101
+ persistent: true,
102
+ placeholder: searchForAColumn,
103
+ onChange: function onChange(e) {
104
+ return setGlobalFilter(e.target.value);
105
+ }
106
+ }), /*#__PURE__*/React.createElement(RowSizeDropdown, rowSizeDropdownProps), /*#__PURE__*/React.createElement("div", {
107
+ style: style
108
+ }, /*#__PURE__*/React.createElement(Button, {
109
+ kind: "ghost",
110
+ hasIconOnly: true,
111
+ tooltipPosition: "bottom",
112
+ renderIcon: function renderIcon(props) {
113
+ return /*#__PURE__*/React.createElement(Restart, _extends({
114
+ size: 16
115
+ }, props));
116
+ },
117
+ iconDescription: 'Refresh',
118
+ onClick: refreshColumns
119
+ })), /*#__PURE__*/React.createElement("div", {
120
+ style: style
121
+ }, /*#__PURE__*/React.createElement(Button, {
122
+ kind: "ghost",
123
+ hasIconOnly: true,
124
+ tooltipPosition: "bottom",
125
+ renderIcon: function renderIcon(props) {
126
+ return /*#__PURE__*/React.createElement(Download, _extends({
127
+ size: 16
128
+ }, props));
129
+ },
130
+ iconDescription: 'Download CSV',
131
+ onClick: downloadCsv
132
+ })), CustomizeColumnsButton && /*#__PURE__*/React.createElement("div", {
133
+ style: style
134
+ }, /*#__PURE__*/React.createElement(CustomizeColumnsButton, null)), /*#__PURE__*/React.createElement(ButtonMenu, {
135
+ menuAriaLabel: "Primary action button menu",
136
+ label: "Primary button",
137
+ renderIcon: function renderIcon(props) {
138
+ return /*#__PURE__*/React.createElement(Add, _extends({
139
+ size: 16
140
+ }, props));
141
+ }
142
+ }, /*#__PURE__*/React.createElement(ButtonMenuItem, {
143
+ itemText: "Option 1",
144
+ onClick: action("Click on ButtonMenu Option 1")
145
+ }), /*#__PURE__*/React.createElement(ButtonMenuItem, {
146
+ itemText: "Option 2",
147
+ onClick: action("Click on ButtonMenu Option 2")
148
+ }), /*#__PURE__*/React.createElement(ButtonMenuItem, {
149
+ itemText: "Option 3",
150
+ onClick: action("Click on ButtonMenu Option 3")
151
+ })))));
152
+ };
@@ -0,0 +1,33 @@
1
+ /* eslint-disable react/prop-types */
2
+
3
+ /**
4
+ * Copyright IBM Corp. 2022, 2022
5
+ *
6
+ * This source code is licensed under the Apache-2.0 license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
+ import React from 'react';
10
+ import { Pagination } from '@carbon/react';
11
+ export var DatagridPagination = function DatagridPagination(_ref) {
12
+ var state = _ref.state,
13
+ setPageSize = _ref.setPageSize,
14
+ gotoPage = _ref.gotoPage,
15
+ rows = _ref.rows;
16
+
17
+ var updatePagination = function updatePagination(_ref2) {
18
+ var page = _ref2.page,
19
+ pageSize = _ref2.pageSize;
20
+ console.log(state);
21
+ setPageSize(pageSize);
22
+ gotoPage(page - 1); // Carbon is non-zero-based
23
+ };
24
+
25
+ return /*#__PURE__*/React.createElement(Pagination, {
26
+ page: state.pageIndex + 1 // react-table is zero-based
27
+ ,
28
+ pageSize: state.pageSize,
29
+ pageSizes: state.pageSizes || [10, 20, 30, 40, 50],
30
+ totalItems: rows.length,
31
+ onChange: updatePagination
32
+ });
33
+ };
@@ -0,0 +1,21 @@
1
+ /* eslint-disable react/prop-types */
2
+
3
+ /**
4
+ * Copyright IBM Corp. 2020, 2022
5
+ *
6
+ * This source code is licensed under the Apache-2.0 license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
+ import React from 'react';
10
+ export var Wrapper = function Wrapper(_ref) {
11
+ var children = _ref.children;
12
+ return /*#__PURE__*/React.createElement("div", {
13
+ style: {
14
+ height: '100vh',
15
+ width: '100%',
16
+ padding: '1rem',
17
+ margin: '0',
18
+ zIndex: '0'
19
+ }
20
+ }, children);
21
+ };
@@ -0,0 +1,85 @@
1
+ /**
2
+ * Copyright IBM Corp. 2022, 2022
3
+ *
4
+ * This source code is licensed under the Apache-2.0 license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export var ARG_TYPES = {
8
+ gridTitle: {
9
+ name: 'gridTitle',
10
+ control: 'text',
11
+ description: 'This sets the title text for the Datagrid component. _This value is set/passed inside of the `datagridState` object._',
12
+ type: {
13
+ name: 'string',
14
+ required: false
15
+ }
16
+ },
17
+ gridDescription: {
18
+ name: 'gridDescription',
19
+ control: 'text',
20
+ description: 'This sets the description text for the Datagrid component. _This value is set/passed inside of the `datagridState` object._',
21
+ type: {
22
+ name: 'string',
23
+ required: false
24
+ }
25
+ },
26
+ emptyStateTitle: {
27
+ name: 'emptyStateTitle',
28
+ control: 'text',
29
+ description: 'This sets the empty state title text for the Datagrid component. _This value is set/passed inside of the `datagridState` object._',
30
+ type: {
31
+ name: 'string',
32
+ required: false
33
+ }
34
+ },
35
+ emptyStateDescription: {
36
+ name: 'emptyStateDescription',
37
+ control: 'text',
38
+ description: 'This sets the empty state description text for the Datagrid component. _This value is set/passed inside of the `datagridState` object._',
39
+ type: {
40
+ name: 'string',
41
+ required: false
42
+ }
43
+ },
44
+ emptyStateSize: {
45
+ control: 'select',
46
+ options: ['sm', 'lg']
47
+ },
48
+ useDenseHeader: {
49
+ control: {
50
+ type: 'radio'
51
+ },
52
+ options: [true, false],
53
+ description: 'This sets the dense header option for the Datagrid component. _This value is set/passed inside of the `datagridState` object._'
54
+ },
55
+ rowSize: {
56
+ control: 'select',
57
+ options: ['xs', 'sm', 'md', 'lg', 'xl'],
58
+ description: 'This sets the height for each row of the Datagrid component. _This value is set/passed inside of the `datagridState` object._'
59
+ },
60
+ rowSizes: {
61
+ control: 'object',
62
+ description: 'This array of objects specifies the different row size options that will render from the settings icon in the table actions. _This value is set/passed inside of the `datagridState` object._'
63
+ },
64
+ onRowSizeChange: {
65
+ description: 'Callback function that is called on row size changes. _This value is set/passed inside of the `datagridState` object._'
66
+ },
67
+ rowActions: {
68
+ control: 'object',
69
+ description: 'This array of objects renders the action buttons for each row in the Datagrid. _This value is set/passed inside of the `datagridState` object._',
70
+ action: 'Row action onClick'
71
+ },
72
+ batchActions: {
73
+ control: {
74
+ type: 'radio'
75
+ },
76
+ options: [true, false],
77
+ description: 'This will allow the Datagrid component to use batch actions. _This value is set/passed inside of the `datagridState` object._'
78
+ },
79
+ expandedContentHeight: {
80
+ control: {
81
+ type: 'number'
82
+ },
83
+ description: 'This value controls the height of the expanded content area. _This value is set/passed inside of the `datagridState` object._'
84
+ }
85
+ };
@@ -0,0 +1,153 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
2
+
3
+ /**
4
+ * Copyright IBM Corp. 2022, 2022
5
+ *
6
+ * This source code is licensed under the Apache-2.0 license found in the
7
+ * LICENSE file in the root directory of this source tree.
8
+ */
9
+ import React from 'react';
10
+ import { ChartBubble, ChartColumnFloating, ChartVennDiagram } from '@carbon/react/icons';
11
+ export var inlineEditSelectItems = [{
12
+ id: 'option-0',
13
+ icon: function icon(props) {
14
+ return /*#__PURE__*/React.createElement(ChartColumnFloating, _extends({
15
+ size: 16
16
+ }, props));
17
+ },
18
+ text: 'Column Chart'
19
+ }, {
20
+ id: 'option-1',
21
+ icon: function icon(props) {
22
+ return /*#__PURE__*/React.createElement(ChartBubble, _extends({
23
+ size: 16
24
+ }, props));
25
+ },
26
+ text: 'Bubble Chart'
27
+ }, {
28
+ id: 'option-2',
29
+ icon: function icon(props) {
30
+ return /*#__PURE__*/React.createElement(ChartVennDiagram, _extends({
31
+ size: 16
32
+ }, props));
33
+ },
34
+ text: 'Venn Diagram'
35
+ }];
36
+ export var getInlineEditColumns = function getInlineEditColumns() {
37
+ return [{
38
+ Header: 'Row Index',
39
+ accessor: function accessor(row, i) {
40
+ return i;
41
+ },
42
+ id: 'rowIndex' // id is required when accessor is a function.
43
+
44
+ }, {
45
+ Header: 'First Name',
46
+ accessor: 'firstName',
47
+ inlineEdit: {
48
+ type: 'text',
49
+ // required for including validation, this is used to set the invalid prop internally
50
+ validator: function validator(n) {
51
+ return n.length > 40;
52
+ },
53
+ // These props are passed to the Carbon component used for inline editing
54
+ inputProps: {
55
+ invalidText: 'Invalid text, character count must be less than 40'
56
+ }
57
+ }
58
+ }, {
59
+ Header: 'Last Name',
60
+ accessor: 'lastName',
61
+ inlineEdit: {
62
+ type: 'text',
63
+ // required for including validation, this is used to set the invalid prop internally
64
+ validator: function validator(n) {
65
+ return n.length > 40;
66
+ },
67
+ // These props are passed to the Carbon component used for inline editing
68
+ inputProps: {
69
+ invalidText: 'Invalid text, character count must be less than 40'
70
+ }
71
+ }
72
+ }, {
73
+ Header: 'Age',
74
+ accessor: 'age',
75
+ width: 120,
76
+ inlineEdit: {
77
+ // required for including validation, this is used to set the invalid prop internally
78
+ validator: function validator(n) {
79
+ return n && n < 18;
80
+ },
81
+ type: 'number',
82
+ // These props are passed to the Carbon component used for inline editing
83
+ inputProps: {
84
+ invalidText: 'Invalid number, must be 18 or greater'
85
+ }
86
+ }
87
+ }, {
88
+ Header: 'Visits',
89
+ accessor: 'visits',
90
+ width: 120,
91
+ inlineEdit: {
92
+ type: 'number',
93
+ inputProps: {} // These props are passed to the Carbon component used for inline editing
94
+
95
+ }
96
+ }, {
97
+ Header: 'Active since',
98
+ accessor: 'activeSince',
99
+ inlineEdit: {
100
+ type: 'date',
101
+ inputProps: {
102
+ // optionally pass props here to be passed through to Carbon's DatePicker component
103
+ onChange: function onChange(newDateObj, cell) {
104
+ console.log(newDateObj, cell);
105
+ },
106
+ // optionally pass props here to be passed through to Carbon's DatePickerInput component
107
+ datePickerInputProps: {
108
+ labelText: 'Change active since date'
109
+ }
110
+ }
111
+ }
112
+ }, {
113
+ Header: 'Chart type',
114
+ accessor: 'chartType',
115
+ inlineEdit: {
116
+ type: 'selection',
117
+ inputProps: {
118
+ // These props are passed to the Carbon component used for inline editing
119
+ items: inlineEditSelectItems,
120
+ onChange: function onChange(item) {
121
+ return console.log(item);
122
+ }
123
+ }
124
+ }
125
+ }, {
126
+ Header: 'Someone 2',
127
+ accessor: 'someone2'
128
+ }, {
129
+ Header: 'Someone 3',
130
+ accessor: 'someone3'
131
+ }, {
132
+ Header: 'Someone 4',
133
+ accessor: 'someone4'
134
+ }, {
135
+ Header: 'Someone 5',
136
+ accessor: 'someone5'
137
+ }, {
138
+ Header: 'Someone 6',
139
+ accessor: 'someone6'
140
+ }, {
141
+ Header: 'Someone 7',
142
+ accessor: 'someone7'
143
+ }, {
144
+ Header: 'Someone 8',
145
+ accessor: 'someone8'
146
+ }, {
147
+ Header: 'Someone 9',
148
+ accessor: 'someone9'
149
+ }, {
150
+ Header: 'Someone 10',
151
+ accessor: 'someone10'
152
+ }];
153
+ };
@@ -12,6 +12,22 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
12
12
  */
13
13
  import React from 'react';
14
14
  import namor from 'namor';
15
+ import { StatusIcon } from '../../StatusIcon';
16
+ import { inlineEditSelectItems } from './getInlineEditColumns';
17
+
18
+ var getRandomInteger = function getRandomInteger(min, max, decimalPlaces) {
19
+ var roundedMin = Math.ceil(min);
20
+ var roundedMax = Math.floor(max);
21
+ var randomNumber = Math.random() * (max - min) + min;
22
+
23
+ if (!decimalPlaces) {
24
+ return Math.floor(Math.random() * (roundedMax - roundedMin + 1)) + roundedMin;
25
+ }
26
+
27
+ var power = Math.pow(10, decimalPlaces);
28
+ return Math.floor(randomNumber * power) / power;
29
+ };
30
+
15
31
  export var makeData = function makeData() {
16
32
  for (var _len = arguments.length, lens = new Array(_len), _key = 0; _key < _len; _key++) {
17
33
  lens[_key] = arguments[_key];
@@ -39,8 +55,32 @@ export var range = function range(len) {
39
55
  return arr;
40
56
  };
41
57
 
58
+ var renderStatusIcon = function renderStatusIcon(statusChance) {
59
+ var iconProps = {
60
+ size: 'sm',
61
+ theme: 'light',
62
+ kind: statusChance > 0.66 ? 'critical' : statusChance > 0.33 ? 'minor-warning' : 'normal',
63
+ iconDescription: statusChance > 0.66 ? 'Critical' : statusChance > 0.33 ? 'Minor warning' : 'Normal'
64
+ };
65
+ return /*#__PURE__*/React.createElement(StatusIcon, iconProps);
66
+ };
67
+
68
+ var renderDocLink = function renderDocLink(statusChance) {
69
+ var docLinkObj = {
70
+ href: statusChance > 0.66 ? 'http://carbondesignsystem.com/' : statusChance > 0.33 ? 'https://pages.github.ibm.com/cdai-design/pal/' : 'http://carbon-for-ibm-products.netlify.app/',
71
+ text: statusChance > 0.66 ? 'Carbon Design System' : statusChance > 0.33 ? 'Carbon for IBM Products PAL' : 'Carbon for IBM Products storybook'
72
+ };
73
+ return docLinkObj;
74
+ };
75
+
42
76
  var newPerson = function newPerson() {
43
77
  var statusChance = Math.random();
78
+ var initialChartTypeIndex = getRandomInteger(0, 2);
79
+ var activeSinceDate = new Date();
80
+ var yesterdayDate = new Date();
81
+ yesterdayDate.setDate(yesterdayDate.getDate() - 1);
82
+ var twoDaysAgoDate = new Date();
83
+ twoDaysAgoDate.setDate(twoDaysAgoDate.getDate() - 2);
44
84
  return {
45
85
  firstName: namor.generate({
46
86
  words: 1,
@@ -94,7 +134,7 @@ var newPerson = function newPerson() {
94
134
  numbers: 0
95
135
  }),
96
136
  someone11: namor.generate({
97
- words: 1,
137
+ words: 4,
98
138
  numbers: 0
99
139
  }),
100
140
  someone12: namor.generate({
@@ -133,7 +173,12 @@ var newPerson = function newPerson() {
133
173
  words: 1,
134
174
  numbers: 0
135
175
  }),
136
- status: statusChance > 0.66 ? 'relationship' : statusChance > 0.33 ? 'complicated' : 'single'
176
+ status: statusChance > 0.66 ? 'relationship' : statusChance > 0.33 ? 'complicated' : 'single',
177
+ chartType: initialChartTypeIndex === 0 ? inlineEditSelectItems[0] : initialChartTypeIndex === 1 ? inlineEditSelectItems[1] : inlineEditSelectItems[2],
178
+ activeSince: statusChance > 0.66 ? activeSinceDate : statusChance > 0.33 ? yesterdayDate : twoDaysAgoDate,
179
+ bonus: "$\r".concat(getRandomInteger(100, 500, 2)),
180
+ status_icon: renderStatusIcon(statusChance),
181
+ doc_link: renderDocLink(statusChance)
137
182
  };
138
183
  };
139
184
 
@@ -17,7 +17,7 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
17
17
  import React, { useState, useRef, forwardRef, useEffect } from 'react';
18
18
  import { Button, ComposedModal, ModalHeader, ModalFooter, ModalBody, TextInput, RadioButton, RadioButtonGroup, FormGroup, Loading, PasswordInput } from '@carbon/react';
19
19
  import cx from 'classnames';
20
- import { ErrorFilled, CheckmarkFilled } from '@carbon/icons-react';
20
+ import { ErrorFilled, CheckmarkFilled } from '@carbon/react/icons';
21
21
  import PropTypes from 'prop-types';
22
22
  import { getDevtoolsProps } from '../../global/js/utils/devtools';
23
23
  import uuidv4 from '../../global/js/utils/uuidv4';
@@ -18,7 +18,7 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
18
18
  // LICENSE file in the root directory of this source tree.
19
19
  //
20
20
  import React, { useState, forwardRef } from 'react';
21
- import { Add } from '@carbon/icons-react';
21
+ import { Add } from '@carbon/react/icons';
22
22
  import { ComposedModal, ModalHeader, ModalFooter, ModalBody, FileUploaderDropContainer, FileUploaderItem, TextInput, Button, usePrefix } from '@carbon/react';
23
23
  import cx from 'classnames';
24
24
  import PropTypes from 'prop-types';
@@ -77,9 +77,9 @@ export var ImportModal = /*#__PURE__*/forwardRef(function (_ref, ref) {
77
77
  var acceptSet = new Set(accept);
78
78
  var name = file.name;
79
79
  var mimeType = file.type;
80
- var extension = name.split('.').pop();
80
+ var extension = ".".concat(name.split('.').pop());
81
81
 
82
- if (acceptSet.has(mimeType) || acceptSet.has(extension)) {
82
+ if (acceptSet.has(mimeType) || acceptSet.has(extension) || accept.length === 0) {
83
83
  return false;
84
84
  }
85
85
 
@@ -22,7 +22,7 @@ import { pkg } from '../../settings'; // Carbon and package components we use.
22
22
  /* TODO: @use(s) of carbon components and other package components. */
23
23
 
24
24
  import { Button, IconButton, usePrefix } from '@carbon/react';
25
- import { Close, Edit, EditOff, Checkmark, WarningFilled } from '@carbon/icons-react'; // The block part of our conventional BEM class names (blockClass__E--M).
25
+ import { Close, Edit, EditOff, Checkmark, WarningFilled } from '@carbon/react/icons'; // The block part of our conventional BEM class names (blockClass__E--M).
26
26
 
27
27
  var blockClass = "".concat(pkg.prefix, "--inline-edit");
28
28
  var componentName = 'InlineEdit'; // NOTE: the component SCSS is not imported here: it is rolled up separately.
@@ -40,7 +40,7 @@ var buttons = ['cancel', 'edit', 'save'];
40
40
  */
41
41
 
42
42
  export var InlineEdit = /*#__PURE__*/React.forwardRef(function (_ref, refIn) {
43
- var _cx, _refInput$current, _refInput$current$inn, _cx3;
43
+ var _cx, _refInput$current, _refInput$current$tex, _cx3;
44
44
 
45
45
  var buttonTooltipAlignment = _ref.buttonTooltipAlignment,
46
46
  buttonTooltipPosition = _ref.buttonTooltipPosition,
@@ -66,7 +66,9 @@ export var InlineEdit = /*#__PURE__*/React.forwardRef(function (_ref, refIn) {
66
66
  rest = _objectWithoutProperties(_ref, _excluded);
67
67
 
68
68
  var carbonPrefix = usePrefix();
69
- var refInput = useRef(null);
69
+ var refInput = useRef({
70
+ textContent: value
71
+ });
70
72
  var localRef = useRef(null);
71
73
  var ref = refIn || localRef;
72
74
 
@@ -149,15 +151,15 @@ export var InlineEdit = /*#__PURE__*/React.forwardRef(function (_ref, refIn) {
149
151
  document.getSelection().removeAllRanges();
150
152
 
151
153
  if (onSave) {
152
- onSave(refInput.current.innerText);
154
+ onSave(refInput.current.textContent);
153
155
  }
154
156
  };
155
157
 
156
158
  var handleInput = function handleInput() {
157
- setInternalValue(refInput.current.innerText);
159
+ setInternalValue(refInput.current.textContent);
158
160
 
159
161
  if (onChange) {
160
- onChange(refInput.current.innerText);
162
+ onChange(refInput.current.textContent);
161
163
  }
162
164
  }; // pasting into contentEditable not supported by userEvent
163
165
 
@@ -192,7 +194,7 @@ export var InlineEdit = /*#__PURE__*/React.forwardRef(function (_ref, refIn) {
192
194
  };
193
195
 
194
196
  var handleCancel = function handleCancel() {
195
- refInput.current.innerText = value;
197
+ refInput.current.textContent = value;
196
198
  handleInput(value);
197
199
  doSetEditing(false);
198
200
  document.getSelection().removeAllRanges();
@@ -260,7 +262,7 @@ export var InlineEdit = /*#__PURE__*/React.forwardRef(function (_ref, refIn) {
260
262
  }, /*#__PURE__*/React.createElement("div", _extends({}, rest, getDevtoolsProps(componentName), {
261
263
  id: id,
262
264
  size: size,
263
- className: cx("".concat(blockClass, "__input"), _defineProperty({}, "".concat(blockClass, "__input--empty"), ((_refInput$current = refInput.current) === null || _refInput$current === void 0 ? void 0 : (_refInput$current$inn = _refInput$current.innerText) === null || _refInput$current$inn === void 0 ? void 0 : _refInput$current$inn.length) === 0)),
265
+ className: cx("".concat(blockClass, "__input"), _defineProperty({}, "".concat(blockClass, "__input--empty"), ((_refInput$current = refInput.current) === null || _refInput$current === void 0 ? void 0 : (_refInput$current$tex = _refInput$current.textContent) === null || _refInput$current$tex === void 0 ? void 0 : _refInput$current$tex.length) === 0)),
264
266
  contentEditable: true,
265
267
  "aria-label": labelText,
266
268
  role: "textbox",
@@ -271,7 +273,7 @@ export var InlineEdit = /*#__PURE__*/React.forwardRef(function (_ref, refIn) {
271
273
  onPaste: handlePaste,
272
274
  suppressContentEditableWarning: true,
273
275
  ref: refInput,
274
- "data-placeholder": placeholder !== null && placeholder !== void 0 ? placeholder : labelText
276
+ "data-placeholder": placeholder
275
277
  }), value), /*#__PURE__*/React.createElement("div", {
276
278
  className: cx("".concat(blockClass, "__after-input-elements")) // tabindex -1 fixes blur target test when clicking on after-input-elements background
277
279
  ,
@@ -6,7 +6,7 @@
6
6
  //
7
7
  import React from 'react';
8
8
  import PropTypes from 'prop-types';
9
- import { Add } from '@carbon/icons-react';
9
+ import { Add } from '@carbon/react/icons';
10
10
  import { pkg } from '../../settings';
11
11
  var blockClass = "".concat(pkg.prefix, "--modified-tabs");
12
12
  export var ModifiedTabLabelNew = function ModifiedTabLabelNew(_ref) {
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
- import { Close, CloseFilled } from '@carbon/icons-react';
3
+ import { Close, CloseFilled } from '@carbon/react/icons';
4
4
  import { pkg } from '../../settings';
5
5
  var blockClass = "".concat(pkg.prefix, "--modified-tabs");
6
6
  export var ModifiedTabLabelWithClose = function ModifiedTabLabelWithClose(_ref) {
@@ -22,7 +22,7 @@ import { timeAgo } from './utils';
22
22
  import { NotificationsEmptyState } from '../EmptyStates/NotificationsEmptyState'; // Carbon and package components we use.
23
23
 
24
24
  import { Button, Link, Toggle, IconButton } from '@carbon/react';
25
- import { ErrorFilled, WarningAltFilled, CheckmarkFilled, InformationSquareFilled, ChevronDown, Close, Settings } from '@carbon/icons-react';
25
+ import { ErrorFilled, WarningAltFilled, CheckmarkFilled, InformationSquareFilled, ChevronDown, Close, Settings } from '@carbon/react/icons';
26
26
  import { usePreviousValue } from '../../global/js/hooks'; // The block part of our conventional BEM class names (blockClass__E--M).
27
27
 
28
28
  var componentName = 'NotificationsPanel';
@@ -20,7 +20,7 @@ import uuidv4 from '../../global/js/utils/uuidv4';
20
20
  import { pkg } from '../../settings'; // Carbon and package components we use.
21
21
 
22
22
  import { Toggle } from '@carbon/react';
23
- import { ChevronDown, Locked, WarningAltFilled, WarningFilled } from '@carbon/icons-react';
23
+ import { ChevronDown, Locked, WarningAltFilled, WarningFilled } from '@carbon/react/icons';
24
24
  import * as carbonMotion from '@carbon/motion'; // The block part of our conventional BEM class names (blockClass__E--M).
25
25
 
26
26
  var blockClass = "".concat(pkg.prefix, "--options-tile");