@carbon/ibm-products 2.43.2-canary.1 → 2.43.2-canary.101

Sign up to get free protection for your applications and to get access to all the features.
Files changed (362) hide show
  1. package/css/index-full-carbon.css +429 -143
  2. package/css/index-full-carbon.css.map +1 -1
  3. package/css/index-full-carbon.min.css +1 -1
  4. package/css/index-full-carbon.min.css.map +1 -1
  5. package/css/index-without-carbon-released-only.css +219 -9
  6. package/css/index-without-carbon-released-only.css.map +1 -1
  7. package/css/index-without-carbon-released-only.min.css +1 -1
  8. package/css/index-without-carbon-released-only.min.css.map +1 -1
  9. package/css/index-without-carbon.css +249 -105
  10. package/css/index-without-carbon.css.map +1 -1
  11. package/css/index-without-carbon.min.css +1 -1
  12. package/css/index-without-carbon.min.css.map +1 -1
  13. package/css/index.css +350 -129
  14. package/css/index.css.map +1 -1
  15. package/css/index.min.css +1 -1
  16. package/css/index.min.css.map +1 -1
  17. package/es/components/ActionBar/ActionBarItem.js +1 -1
  18. package/es/components/Coachmark/Coachmark.d.ts +6 -1
  19. package/es/components/Coachmark/Coachmark.js +47 -11
  20. package/es/components/Coachmark/CoachmarkOverlay.js +2 -4
  21. package/es/components/CoachmarkBeacon/CoachmarkBeacon.js +1 -7
  22. package/es/components/CoachmarkFixed/CoachmarkFixed.js +13 -11
  23. package/es/components/CoachmarkStack/CoachmarkStack.js +7 -3
  24. package/es/components/CoachmarkStack/CoachmarkStackHome.js +8 -4
  25. package/es/components/ConditionBuilder/ConditionBlock/ConditionBlock.js +76 -55
  26. package/es/components/ConditionBuilder/ConditionBuilder.js +82 -25
  27. package/es/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.d.ts +15 -0
  28. package/es/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.js +154 -0
  29. package/es/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.d.ts +3 -1
  30. package/es/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.js +29 -13
  31. package/es/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.d.ts +8 -1
  32. package/es/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.js +30 -8
  33. package/es/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.js +14 -9
  34. package/es/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.js +19 -11
  35. package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.d.ts +9 -13
  36. package/es/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +75 -62
  37. package/es/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.d.ts +13 -7
  38. package/es/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.js +31 -8
  39. package/es/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.d.ts +8 -2
  40. package/es/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.js +35 -24
  41. package/es/components/ConditionBuilder/ConditionBuilderContext/translationObject.d.ts +40 -36
  42. package/es/components/ConditionBuilder/ConditionBuilderContext/translationObject.js +40 -36
  43. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.d.ts +6 -2
  44. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.js +98 -40
  45. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.d.ts +3 -1
  46. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.js +24 -9
  47. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.js +27 -9
  48. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.d.ts +13 -0
  49. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +114 -0
  50. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.d.ts → ItemOptionForValueField.d.ts} +2 -2
  51. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.js → ItemOptionForValueField.js} +71 -38
  52. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.d.ts +5 -1
  53. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.js +22 -9
  54. package/es/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.js +1 -1
  55. package/es/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.d.ts +1 -3
  56. package/es/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.js +121 -40
  57. package/es/components/ConditionBuilder/ConditionPreview/ConditionPreview.d.ts +3 -1
  58. package/es/components/ConditionBuilder/ConditionPreview/ConditionPreview.js +45 -19
  59. package/es/components/ConditionBuilder/utils/handleKeyboardEvents.d.ts +2 -1
  60. package/es/components/ConditionBuilder/utils/handleKeyboardEvents.js +137 -40
  61. package/es/components/ConditionBuilder/utils/useTranslations.d.ts +1 -0
  62. package/es/components/ConditionBuilder/utils/useTranslations.js +26 -0
  63. package/es/components/ConditionBuilder/utils/util.d.ts +6 -4
  64. package/es/components/ConditionBuilder/utils/util.js +42 -17
  65. package/es/components/CreateFullPage/CreateFullPage.js +2 -2
  66. package/es/components/DataSpreadsheet/DataSpreadsheet.d.ts +26 -0
  67. package/es/components/DataSpreadsheet/DataSpreadsheet.js +140 -54
  68. package/es/components/DataSpreadsheet/DataSpreadsheetBody.d.ts +25 -1
  69. package/es/components/DataSpreadsheet/DataSpreadsheetBody.js +50 -9
  70. package/es/components/DataSpreadsheet/DataSpreadsheetHeader.d.ts +16 -0
  71. package/es/components/DataSpreadsheet/DataSpreadsheetHeader.js +32 -8
  72. package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseMove.js +4 -1
  73. package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.d.ts +3 -1
  74. package/es/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.js +15 -3
  75. package/es/components/DataSpreadsheet/types/index.d.ts +2 -1
  76. package/es/components/DataSpreadsheet/utils/moveColumnIndicatorLine.js +34 -2
  77. package/es/components/Datagrid/Datagrid/Datagrid.d.ts +0 -4
  78. package/es/components/Datagrid/Datagrid/Datagrid.js +4 -9
  79. package/es/components/Datagrid/Datagrid/DatagridContent.js +1 -1
  80. package/es/components/Datagrid/Datagrid/DatagridHeaderRow.js +23 -8
  81. package/es/components/Datagrid/Datagrid/DatagridRow.js +21 -8
  82. package/es/components/Datagrid/Datagrid/DatagridSelectAll.js +6 -6
  83. package/es/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +3 -2
  84. package/es/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +34 -10
  85. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +6 -1
  86. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +6 -1
  87. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.d.ts +3 -1
  88. package/es/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +7 -4
  89. package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.d.ts +1 -1
  90. package/es/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +54 -17
  91. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +2 -3
  92. package/es/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +75 -12
  93. package/es/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +10 -2
  94. package/es/components/Datagrid/types/index.d.ts +61 -9
  95. package/es/components/Datagrid/useActionsColumn.d.ts +8 -1
  96. package/es/components/Datagrid/useActionsColumn.js +7 -6
  97. package/es/components/Datagrid/useColumnCenterAlign.d.ts +8 -1
  98. package/es/components/Datagrid/useColumnCenterAlign.js +1 -1
  99. package/es/components/Datagrid/useColumnRightAlign.d.ts +8 -1
  100. package/es/components/Datagrid/useColumnRightAlign.js +4 -3
  101. package/es/components/Datagrid/useCustomizeColumns.d.ts +8 -1
  102. package/es/components/Datagrid/useCustomizeColumns.js +4 -3
  103. package/es/components/Datagrid/useDefaultStringRenderer.js +0 -1
  104. package/es/components/Datagrid/useDisableSelectRows.d.ts +2 -1
  105. package/es/components/Datagrid/useDisableSelectRows.js +27 -22
  106. package/es/components/Datagrid/useInlineEdit.d.ts +8 -1
  107. package/es/components/Datagrid/useInlineEdit.js +13 -3
  108. package/es/components/Datagrid/useNestedRowExpander.js +1 -3
  109. package/es/components/Datagrid/useNestedRows.js +32 -13
  110. package/es/components/Datagrid/useRowExpander.js +1 -3
  111. package/es/components/Datagrid/useSelectRows.js +2 -1
  112. package/es/components/Datagrid/useStickyColumn.d.ts +8 -1
  113. package/es/components/Datagrid/useStickyColumn.js +12 -9
  114. package/es/components/Decorator/Decorator.js +2 -1
  115. package/es/components/DecoratorBase/DecoratorBase.js +3 -5
  116. package/es/components/DecoratorDualButton/DecoratorDualButton.js +2 -1
  117. package/es/components/DecoratorLink/DecoratorLink.js +2 -1
  118. package/es/components/DecoratorSingleButton/DecoratorSingleButton.js +2 -1
  119. package/es/components/EditInPlace/EditInPlace.d.ts +4 -0
  120. package/es/components/EditInPlace/EditInPlace.js +21 -10
  121. package/es/components/EditTearsheet/EditTearsheet.d.ts +7 -2
  122. package/es/components/EditTearsheet/EditTearsheet.js +44 -10
  123. package/es/components/EditTearsheet/EditTearsheetForm.d.ts +45 -2
  124. package/es/components/EditTearsheet/EditTearsheetForm.js +3 -0
  125. package/es/components/EmptyStates/EmptyStateV2.d.ts +63 -2
  126. package/es/components/EmptyStates/EmptyStateV2.js +2 -1
  127. package/es/components/FullPageError/FullPageError.d.ts +36 -2
  128. package/es/components/FullPageError/FullPageError.js +0 -3
  129. package/es/components/GetStartedCard/GetStartedCard.d.ts +61 -2
  130. package/es/components/GetStartedCard/GetStartedCard.js +9 -8
  131. package/es/components/HTTPErrors/HTTPError403/HTTPError403.js +6 -0
  132. package/es/components/HTTPErrors/HTTPError404/HTTPError404.js +6 -0
  133. package/es/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +6 -0
  134. package/es/components/HTTPErrors/assets/HTTPErrorSvg403.js +204 -200
  135. package/es/components/HTTPErrors/assets/HTTPErrorSvg404.js +116 -112
  136. package/es/components/HTTPErrors/assets/HTTPErrorSvgOther.js +110 -106
  137. package/es/components/Nav/NavItem.js +12 -3
  138. package/es/components/OptionsTile/OptionsTile.js +11 -6
  139. package/es/components/PageHeader/PageHeader.js +1 -0
  140. package/es/components/RemoveModal/RemoveModal.d.ts +4 -0
  141. package/es/components/RemoveModal/RemoveModal.js +7 -1
  142. package/es/components/SearchBar/SearchBar.d.ts +1 -1
  143. package/es/components/SearchBar/SearchBar.js +2 -2
  144. package/es/components/SidePanel/SidePanel.js +17 -21
  145. package/es/components/SidePanel/motion/variants.d.ts +4 -6
  146. package/es/components/SidePanel/motion/variants.js +10 -11
  147. package/es/components/StatusIndicator/StatusIndicatorStep.js +87 -0
  148. package/es/components/StringFormatter/StringFormatter.js +14 -3
  149. package/es/components/StringFormatter/utils/enums.d.ts +20 -1
  150. package/es/components/StringFormatter/utils/enums.js +22 -2
  151. package/es/components/TagOverflow/TagOverflow.d.ts +35 -4
  152. package/es/components/TagOverflow/TagOverflow.js +47 -64
  153. package/es/components/TagOverflow/TagOverflowModal.js +4 -6
  154. package/es/components/TagOverflow/TagOverflowPopover.d.ts +13 -1
  155. package/es/components/TagOverflow/TagOverflowPopover.js +38 -41
  156. package/es/components/Tearsheet/Tearsheet.d.ts +8 -1
  157. package/es/components/Tearsheet/Tearsheet.js +9 -1
  158. package/es/components/Tearsheet/TearsheetNarrow.d.ts +11 -0
  159. package/es/components/Tearsheet/TearsheetNarrow.js +12 -0
  160. package/es/components/Tearsheet/TearsheetShell.d.ts +11 -1
  161. package/es/components/Tearsheet/TearsheetShell.js +28 -7
  162. package/es/components/Toolbar/ToolbarButton.js +1 -1
  163. package/es/components/WebTerminal/WebTerminal.js +10 -12
  164. package/es/components/index.d.ts +1 -1
  165. package/es/global/js/hooks/useFocus.d.ts +1 -0
  166. package/es/global/js/hooks/useFocus.js +5 -2
  167. package/es/global/js/hooks/usePrefersReducedMotion.js +14 -8
  168. package/es/global/js/package-settings.d.ts +1 -1
  169. package/es/global/js/package-settings.js +1 -1
  170. package/es/index.js +1 -0
  171. package/es/node_modules/@carbon/icon-helpers/es/index.js +49 -62
  172. package/es/node_modules/@carbon/icons-react/es/generated/bucket-2.js +1020 -1058
  173. package/es/node_modules/@carbon/icons-react/es/generated/bucket-9.js +881 -758
  174. package/es/settings.d.ts +1 -1
  175. package/lib/components/ActionBar/ActionBarItem.js +1 -1
  176. package/lib/components/Coachmark/Coachmark.d.ts +6 -1
  177. package/lib/components/Coachmark/Coachmark.js +46 -10
  178. package/lib/components/Coachmark/CoachmarkOverlay.js +2 -4
  179. package/lib/components/CoachmarkBeacon/CoachmarkBeacon.js +1 -7
  180. package/lib/components/CoachmarkFixed/CoachmarkFixed.js +13 -11
  181. package/lib/components/CoachmarkStack/CoachmarkStack.js +7 -3
  182. package/lib/components/CoachmarkStack/CoachmarkStackHome.js +8 -4
  183. package/lib/components/ConditionBuilder/ConditionBlock/ConditionBlock.js +74 -53
  184. package/lib/components/ConditionBuilder/ConditionBuilder.js +82 -25
  185. package/lib/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.d.ts +15 -0
  186. package/lib/components/ConditionBuilder/ConditionBuilderActions/ConditionBuilderActions.js +163 -0
  187. package/lib/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.d.ts +3 -1
  188. package/lib/components/ConditionBuilder/ConditionBuilderAdd/ConditionBuilderAdd.js +28 -11
  189. package/lib/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.d.ts +8 -1
  190. package/lib/components/ConditionBuilder/ConditionBuilderButton/ConditionBuilderButton.js +29 -7
  191. package/lib/components/ConditionBuilder/ConditionBuilderConnector/ConditionConnector.js +12 -7
  192. package/lib/components/ConditionBuilder/ConditionBuilderConnector/GroupConnector.js +18 -10
  193. package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.d.ts +9 -13
  194. package/lib/components/ConditionBuilder/ConditionBuilderContent/ConditionBuilderContent.js +73 -60
  195. package/lib/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.d.ts +13 -7
  196. package/lib/components/ConditionBuilder/ConditionBuilderContext/ConditionBuilderProvider.js +31 -8
  197. package/lib/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.d.ts +8 -2
  198. package/lib/components/ConditionBuilder/ConditionBuilderContext/DataConfigs.js +34 -24
  199. package/lib/components/ConditionBuilder/ConditionBuilderContext/translationObject.d.ts +40 -36
  200. package/lib/components/ConditionBuilder/ConditionBuilderContext/translationObject.js +40 -36
  201. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.d.ts +6 -2
  202. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItem.js +96 -38
  203. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.d.ts +3 -1
  204. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemDate/ConditionBuilderItemDate.js +24 -9
  205. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemNumber/ConditionBuilderItemNumber.js +28 -10
  206. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.d.ts +13 -0
  207. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/ItemOption.js +122 -0
  208. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.d.ts → ItemOptionForValueField.d.ts} +2 -2
  209. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemOption/{ConditionBuilderItemOption.js → ItemOptionForValueField.js} +68 -35
  210. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.d.ts +5 -1
  211. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemText/ConditionBuilderItemText.js +21 -8
  212. package/lib/components/ConditionBuilder/ConditionBuilderItem/ConditionBuilderItemTime/ConditionBuilderItemTime.js +1 -1
  213. package/lib/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.d.ts +1 -3
  214. package/lib/components/ConditionBuilder/ConditionGroupBuilder/ConditionGroupBuilder.js +118 -37
  215. package/lib/components/ConditionBuilder/ConditionPreview/ConditionPreview.d.ts +3 -1
  216. package/lib/components/ConditionBuilder/ConditionPreview/ConditionPreview.js +44 -17
  217. package/lib/components/ConditionBuilder/utils/handleKeyboardEvents.d.ts +2 -1
  218. package/lib/components/ConditionBuilder/utils/handleKeyboardEvents.js +137 -39
  219. package/lib/components/ConditionBuilder/utils/useTranslations.d.ts +1 -0
  220. package/lib/components/ConditionBuilder/utils/useTranslations.js +30 -0
  221. package/lib/components/ConditionBuilder/utils/util.d.ts +6 -4
  222. package/lib/components/ConditionBuilder/utils/util.js +44 -16
  223. package/lib/components/CreateFullPage/CreateFullPage.js +2 -2
  224. package/lib/components/DataSpreadsheet/DataSpreadsheet.d.ts +26 -0
  225. package/lib/components/DataSpreadsheet/DataSpreadsheet.js +140 -54
  226. package/lib/components/DataSpreadsheet/DataSpreadsheetBody.d.ts +25 -1
  227. package/lib/components/DataSpreadsheet/DataSpreadsheetBody.js +50 -9
  228. package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.d.ts +16 -0
  229. package/lib/components/DataSpreadsheet/DataSpreadsheetHeader.js +32 -8
  230. package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseMove.js +4 -1
  231. package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.d.ts +3 -1
  232. package/lib/components/DataSpreadsheet/hooks/useSpreadsheetMouseUp.js +15 -3
  233. package/lib/components/DataSpreadsheet/types/index.d.ts +2 -1
  234. package/lib/components/DataSpreadsheet/utils/moveColumnIndicatorLine.js +34 -2
  235. package/lib/components/Datagrid/Datagrid/Datagrid.d.ts +0 -4
  236. package/lib/components/Datagrid/Datagrid/Datagrid.js +4 -9
  237. package/lib/components/Datagrid/Datagrid/DatagridContent.js +1 -1
  238. package/lib/components/Datagrid/Datagrid/DatagridHeaderRow.js +23 -8
  239. package/lib/components/Datagrid/Datagrid/DatagridRow.js +21 -8
  240. package/lib/components/Datagrid/Datagrid/DatagridSelectAll.js +6 -6
  241. package/lib/components/Datagrid/Datagrid/DatagridSelectAllWithToggle.js +3 -2
  242. package/lib/components/Datagrid/Datagrid/addons/CustomizeColumns/CustomizeColumnsTearsheet.js +34 -10
  243. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterFlyout.js +6 -1
  244. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterPanel.js +6 -1
  245. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.d.ts +3 -1
  246. package/lib/components/Datagrid/Datagrid/addons/Filtering/FilterProvider.js +7 -4
  247. package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.d.ts +1 -1
  248. package/lib/components/Datagrid/Datagrid/addons/Filtering/hooks/useFilters.js +53 -16
  249. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditButton/InlineEditButton.js +2 -3
  250. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/InlineEditCell/InlineEditCell.js +74 -11
  251. package/lib/components/Datagrid/Datagrid/addons/InlineEdit/handleGridKeyPress.js +10 -2
  252. package/lib/components/Datagrid/types/index.d.ts +61 -9
  253. package/lib/components/Datagrid/useActionsColumn.d.ts +8 -1
  254. package/lib/components/Datagrid/useActionsColumn.js +7 -6
  255. package/lib/components/Datagrid/useColumnCenterAlign.d.ts +8 -1
  256. package/lib/components/Datagrid/useColumnCenterAlign.js +1 -1
  257. package/lib/components/Datagrid/useColumnRightAlign.d.ts +8 -1
  258. package/lib/components/Datagrid/useColumnRightAlign.js +4 -3
  259. package/lib/components/Datagrid/useCustomizeColumns.d.ts +8 -1
  260. package/lib/components/Datagrid/useCustomizeColumns.js +4 -3
  261. package/lib/components/Datagrid/useDefaultStringRenderer.js +0 -1
  262. package/lib/components/Datagrid/useDisableSelectRows.d.ts +2 -1
  263. package/lib/components/Datagrid/useDisableSelectRows.js +27 -22
  264. package/lib/components/Datagrid/useInlineEdit.d.ts +8 -1
  265. package/lib/components/Datagrid/useInlineEdit.js +13 -3
  266. package/lib/components/Datagrid/useNestedRowExpander.js +1 -3
  267. package/lib/components/Datagrid/useNestedRows.js +32 -13
  268. package/lib/components/Datagrid/useRowExpander.js +1 -3
  269. package/lib/components/Datagrid/useSelectRows.js +2 -1
  270. package/lib/components/Datagrid/useStickyColumn.d.ts +8 -1
  271. package/lib/components/Datagrid/useStickyColumn.js +12 -9
  272. package/lib/components/Decorator/Decorator.js +2 -1
  273. package/lib/components/DecoratorBase/DecoratorBase.js +3 -5
  274. package/lib/components/DecoratorDualButton/DecoratorDualButton.js +2 -1
  275. package/lib/components/DecoratorLink/DecoratorLink.js +2 -1
  276. package/lib/components/DecoratorSingleButton/DecoratorSingleButton.js +2 -1
  277. package/lib/components/EditInPlace/EditInPlace.d.ts +4 -0
  278. package/lib/components/EditInPlace/EditInPlace.js +21 -10
  279. package/lib/components/EditTearsheet/EditTearsheet.d.ts +7 -2
  280. package/lib/components/EditTearsheet/EditTearsheet.js +43 -9
  281. package/lib/components/EditTearsheet/EditTearsheetForm.d.ts +45 -2
  282. package/lib/components/EditTearsheet/EditTearsheetForm.js +3 -0
  283. package/lib/components/EmptyStates/EmptyStateV2.d.ts +63 -2
  284. package/lib/components/EmptyStates/EmptyStateV2.js +2 -1
  285. package/lib/components/FullPageError/FullPageError.d.ts +36 -2
  286. package/lib/components/FullPageError/FullPageError.js +0 -3
  287. package/lib/components/GetStartedCard/GetStartedCard.d.ts +61 -2
  288. package/lib/components/GetStartedCard/GetStartedCard.js +8 -7
  289. package/lib/components/HTTPErrors/HTTPError403/HTTPError403.js +6 -0
  290. package/lib/components/HTTPErrors/HTTPError404/HTTPError404.js +6 -0
  291. package/lib/components/HTTPErrors/HTTPErrorOther/HTTPErrorOther.js +6 -0
  292. package/lib/components/HTTPErrors/assets/HTTPErrorSvg403.js +204 -200
  293. package/lib/components/HTTPErrors/assets/HTTPErrorSvg404.js +116 -112
  294. package/lib/components/HTTPErrors/assets/HTTPErrorSvgOther.js +110 -106
  295. package/lib/components/Nav/NavItem.js +10 -1
  296. package/lib/components/OptionsTile/OptionsTile.js +11 -6
  297. package/lib/components/PageHeader/PageHeader.js +1 -0
  298. package/lib/components/RemoveModal/RemoveModal.d.ts +4 -0
  299. package/lib/components/RemoveModal/RemoveModal.js +7 -1
  300. package/lib/components/SearchBar/SearchBar.d.ts +1 -1
  301. package/lib/components/SearchBar/SearchBar.js +2 -2
  302. package/lib/components/SidePanel/SidePanel.js +16 -20
  303. package/lib/components/SidePanel/motion/variants.d.ts +4 -6
  304. package/lib/components/SidePanel/motion/variants.js +10 -11
  305. package/lib/components/StatusIndicator/StatusIndicatorStep.js +94 -0
  306. package/lib/components/StringFormatter/StringFormatter.js +13 -2
  307. package/lib/components/StringFormatter/utils/enums.d.ts +20 -1
  308. package/lib/components/StringFormatter/utils/enums.js +23 -1
  309. package/lib/components/TagOverflow/TagOverflow.d.ts +35 -4
  310. package/lib/components/TagOverflow/TagOverflow.js +46 -63
  311. package/lib/components/TagOverflow/TagOverflowModal.js +4 -6
  312. package/lib/components/TagOverflow/TagOverflowPopover.d.ts +13 -1
  313. package/lib/components/TagOverflow/TagOverflowPopover.js +37 -40
  314. package/lib/components/Tearsheet/Tearsheet.d.ts +8 -1
  315. package/lib/components/Tearsheet/Tearsheet.js +9 -1
  316. package/lib/components/Tearsheet/TearsheetNarrow.d.ts +11 -0
  317. package/lib/components/Tearsheet/TearsheetNarrow.js +12 -0
  318. package/lib/components/Tearsheet/TearsheetShell.d.ts +11 -1
  319. package/lib/components/Tearsheet/TearsheetShell.js +26 -5
  320. package/lib/components/Toolbar/ToolbarButton.js +1 -1
  321. package/lib/components/WebTerminal/WebTerminal.js +10 -12
  322. package/lib/components/index.d.ts +1 -1
  323. package/lib/global/js/hooks/useFocus.d.ts +1 -0
  324. package/lib/global/js/hooks/useFocus.js +5 -1
  325. package/lib/global/js/hooks/usePrefersReducedMotion.js +13 -7
  326. package/lib/global/js/package-settings.d.ts +1 -1
  327. package/lib/global/js/package-settings.js +1 -1
  328. package/lib/index.js +5 -0
  329. package/lib/node_modules/@carbon/icon-helpers/es/index.js +49 -62
  330. package/lib/node_modules/@carbon/icons-react/es/generated/bucket-2.js +1036 -1074
  331. package/lib/node_modules/@carbon/icons-react/es/generated/bucket-9.js +946 -823
  332. package/lib/settings.d.ts +1 -1
  333. package/package.json +9 -8
  334. package/scss/components/Coachmark/_coachmark-overlay.scss +6 -70
  335. package/scss/components/Coachmark/_coachmark.scss +5 -4
  336. package/scss/components/CoachmarkBeacon/_coachmark-beacon.scss +1 -3
  337. package/scss/components/ConditionBuilder/_condition-builder.scss +5 -1
  338. package/scss/components/ConditionBuilder/styles/_conditionBuilderCondition.scss +20 -3
  339. package/scss/components/ConditionBuilder/styles/_conditionBuilderItem.scss +32 -3
  340. package/scss/components/CreateModal/_create-modal.scss +0 -4
  341. package/scss/components/DataSpreadsheet/_data-spreadsheet.scss +17 -2
  342. package/scss/components/Datagrid/_datagrid.scss +0 -4
  343. package/scss/components/Datagrid/styles/_datagrid.scss +1 -0
  344. package/scss/components/Datagrid/styles/_useInlineEdit.scss +13 -0
  345. package/scss/components/Datagrid/styles/addons/_CustomizeColumnsTearsheet.scss +7 -5
  346. package/scss/components/Datagrid/styles/addons/_FilterFlyout.scss +5 -4
  347. package/scss/components/HTTPErrors/_http-errors.scss +77 -0
  348. package/scss/components/OptionsTile/_options-tile.scss +6 -6
  349. package/scss/components/SidePanel/_side-panel.scss +1 -1
  350. package/scss/components/StatusIcon/_status-icon.scss +4 -4
  351. package/scss/components/StringFormatter/_string-formatter.scss +2 -2
  352. package/scss/components/UserProfileImage/_user-profile-image.scss +6 -2
  353. package/scss/components/_index-released-only.scss +1 -0
  354. package/telemetry.yml +32 -19
  355. package/es/components/ConditionBuilder/utils/checkForHoldingKey.d.ts +0 -1
  356. package/es/components/ConditionBuilder/utils/checkForHoldingKey.js +0 -16
  357. package/es/global/js/utils/window.d.ts +0 -2
  358. package/es/global/js/utils/window.js +0 -12
  359. package/lib/components/ConditionBuilder/utils/checkForHoldingKey.d.ts +0 -1
  360. package/lib/components/ConditionBuilder/utils/checkForHoldingKey.js +0 -20
  361. package/lib/global/js/utils/window.d.ts +0 -2
  362. package/lib/global/js/utils/window.js +0 -16
@@ -0,0 +1,114 @@
1
+ /**
2
+ * Copyright IBM Corp. 2020, 2024
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
+
8
+ import { slicedToArray as _slicedToArray } from '../../../../_virtual/_rollupPluginBabelHelpers.js';
9
+ import React__default, { useContext, useRef, useState, useEffect } from 'react';
10
+ import { Search } from '@carbon/react';
11
+ import { Checkmark } from '@carbon/react/icons';
12
+ import PropTypes from '../../../../node_modules/prop-types/index.js';
13
+ import { ConditionBuilderContext } from '../../ConditionBuilderContext/ConditionBuilderProvider.js';
14
+ import { blockClass } from '../../ConditionBuilderContext/DataConfigs.js';
15
+ import { useTranslations } from '../../utils/useTranslations.js';
16
+
17
+ var ItemOption = function ItemOption(_ref) {
18
+ var _ref$conditionState = _ref.conditionState,
19
+ conditionState = _ref$conditionState === void 0 ? {} : _ref$conditionState,
20
+ _ref$config = _ref.config,
21
+ config = _ref$config === void 0 ? {} : _ref$config,
22
+ onChange = _ref.onChange;
23
+ var _useContext = useContext(ConditionBuilderContext),
24
+ popOverSearchThreshold = _useContext.popOverSearchThreshold;
25
+ var contentRef = useRef();
26
+ var _useTranslations = useTranslations(['propertyText', 'clearSearchText']),
27
+ _useTranslations2 = _slicedToArray(_useTranslations, 2),
28
+ propertyText = _useTranslations2[0],
29
+ clearSearchText = _useTranslations2[1];
30
+ var allOptions = config.options;
31
+ var _useState = useState(''),
32
+ _useState2 = _slicedToArray(_useState, 2),
33
+ searchValue = _useState2[0],
34
+ setSearchValue = _useState2[1];
35
+ var selection = conditionState.value;
36
+ var filteredItems = allOptions === null || allOptions === void 0 ? void 0 : allOptions.filter(function (opt) {
37
+ return opt.label.toLowerCase().includes(searchValue.toLowerCase());
38
+ });
39
+ useEffect(function () {
40
+ //this will focus the first input field in the popover
41
+
42
+ if (contentRef.current) {
43
+ var firstFocusableElement = contentRef.current.querySelector('input, button,li');
44
+ if (firstFocusableElement) {
45
+ firstFocusableElement.focus();
46
+ }
47
+ }
48
+ }, [allOptions]);
49
+ var onClickHandler = function onClickHandler(evt, option) {
50
+ onChange(option.id, evt);
51
+ };
52
+ var onSearchChangeHandler = function onSearchChangeHandler(evt) {
53
+ var value = evt.target.value;
54
+ setSearchValue(value);
55
+ };
56
+ var getAriaLabel = function getAriaLabel() {
57
+ return conditionState.label ? conditionState.label : conditionState.property ? conditionState.property : propertyText;
58
+ };
59
+ if (!allOptions) {
60
+ return;
61
+ }
62
+ return /*#__PURE__*/React__default.createElement("div", {
63
+ className: "".concat(blockClass, "__item-option"),
64
+ ref: contentRef
65
+ }, allOptions.length > popOverSearchThreshold && /*#__PURE__*/React__default.createElement("div", {
66
+ className: "".concat(blockClass, "__item-option__search")
67
+ }, /*#__PURE__*/React__default.createElement(Search, {
68
+ size: "sm",
69
+ labelText: clearSearchText,
70
+ closeButtonLabelText: clearSearchText,
71
+ onChange: onSearchChangeHandler
72
+ })), /*#__PURE__*/React__default.createElement("ul", {
73
+ "aria-label": getAriaLabel(),
74
+ role: "listbox"
75
+ }, filteredItems === null || filteredItems === void 0 ? void 0 : filteredItems.map(function (option) {
76
+ var isSelected = selection === option.id;
77
+ var Icon = option.icon;
78
+ return /*#__PURE__*/React__default.createElement("li", {
79
+ tabIndex: 0,
80
+ key: option.id,
81
+ role: "option",
82
+ "aria-selected": isSelected,
83
+ className: "".concat(blockClass, "__item-option__option"),
84
+ onKeyUp: function onKeyUp() {
85
+ return false;
86
+ },
87
+ onClick: function onClick(evt) {
88
+ return onClickHandler(evt, option);
89
+ }
90
+ }, /*#__PURE__*/React__default.createElement("div", {
91
+ className: "".concat(blockClass, "__item-option__option-content")
92
+ }, /*#__PURE__*/React__default.createElement("span", {
93
+ className: "".concat(blockClass, "__item-option__option-label")
94
+ }, Icon && /*#__PURE__*/React__default.createElement(Icon, null), option.label), isSelected && /*#__PURE__*/React__default.createElement(Checkmark, {
95
+ className: "".concat(blockClass, "__checkmark")
96
+ })));
97
+ })));
98
+ };
99
+ ItemOption.propTypes = {
100
+ /**
101
+ * current condition object
102
+ */
103
+ conditionState: PropTypes.object,
104
+ /**
105
+ * current config object that this property is part of
106
+ */
107
+ config: PropTypes.object,
108
+ /**
109
+ * callback to update state oin date change
110
+ */
111
+ onChange: PropTypes.func
112
+ };
113
+
114
+ export { ItemOption };
@@ -1,9 +1,9 @@
1
- export function ConditionBuilderItemOption({ conditionState, config, onChange, }: {
1
+ export function ItemOptionForValueField({ conditionState, config, onChange, }: {
2
2
  conditionState?: {} | undefined;
3
3
  config?: {} | undefined;
4
4
  onChange: any;
5
5
  }): import("react/jsx-runtime").JSX.Element;
6
- export namespace ConditionBuilderItemOption {
6
+ export namespace ItemOptionForValueField {
7
7
  namespace propTypes {
8
8
  let conditionState: PropTypes.Requireable<object>;
9
9
  let config: PropTypes.Requireable<object>;
@@ -6,35 +6,63 @@
6
6
  */
7
7
 
8
8
  import { slicedToArray as _slicedToArray, toConsumableArray as _toConsumableArray, asyncToGenerator as _asyncToGenerator, regeneratorRuntime as _regeneratorRuntime } from '../../../../_virtual/_rollupPluginBabelHelpers.js';
9
- import React__default, { useContext, useState, useRef, useEffect } from 'react';
10
- import { Search, Button, SelectSkeleton } from '@carbon/react';
9
+ import React__default, { useContext, useRef, useState, useEffect } from 'react';
10
+ import { SelectSkeleton, Search, Button } from '@carbon/react';
11
11
  import { CheckboxCheckedFilled, Checkbox, Checkmark } from '@carbon/react/icons';
12
12
  import PropTypes from '../../../../node_modules/prop-types/index.js';
13
13
  import { ConditionBuilderContext } from '../../ConditionBuilderContext/ConditionBuilderProvider.js';
14
- import { blockClass, translateWithId } from '../../ConditionBuilderContext/DataConfigs.js';
14
+ import { blockClass } from '../../ConditionBuilderContext/DataConfigs.js';
15
+ import { useTranslations } from '../../utils/useTranslations.js';
15
16
 
16
- var _CheckboxCheckedFille, _Checkbox, _SelectSkeleton;
17
- var ConditionBuilderItemOption = function ConditionBuilderItemOption(_ref) {
17
+ var _SelectSkeleton, _CheckboxCheckedFille, _Checkbox;
18
+ var ItemOptionForValueField = function ItemOptionForValueField(_ref) {
18
19
  var _ref$conditionState = _ref.conditionState,
19
20
  conditionState = _ref$conditionState === void 0 ? {} : _ref$conditionState,
20
21
  _ref$config = _ref.config,
21
22
  config = _ref$config === void 0 ? {} : _ref$config,
22
23
  onChange = _ref.onChange;
23
- var multiSelectable = conditionState.operator === 'one-of';
24
+ var multiSelectable = conditionState.operator === 'oneOf';
24
25
  var _useContext = useContext(ConditionBuilderContext),
25
26
  popOverSearchThreshold = _useContext.popOverSearchThreshold,
26
- getOptions = _useContext.getOptions;
27
+ getOptions = _useContext.getOptions,
28
+ rootState = _useContext.rootState;
29
+ var _useTranslations = useTranslations(['propertyText', 'clearSearchText']),
30
+ _useTranslations2 = _slicedToArray(_useTranslations, 2),
31
+ propertyText = _useTranslations2[0],
32
+ clearSearchText = _useTranslations2[1];
33
+ var contentRef = useRef();
27
34
  var _useState = useState(config.options),
28
35
  _useState2 = _slicedToArray(_useState, 2),
29
36
  allOptions = _useState2[0],
30
37
  setAllOptions = _useState2[1];
31
- var _useState3 = useState(config.options),
38
+ var _useState3 = useState(''),
32
39
  _useState4 = _slicedToArray(_useState3, 2),
33
- filteredItems = _useState4[0],
34
- setFilteredItems = _useState4[1];
40
+ searchValue = _useState4[0],
41
+ setSearchValue = _useState4[1];
42
+ var filteredItems = allOptions === null || allOptions === void 0 ? void 0 : allOptions.filter(function (opt) {
43
+ return opt.label.toLowerCase().includes(searchValue.toLowerCase());
44
+ });
35
45
  var selection = Array.isArray(conditionState.value) ? conditionState.value : conditionState.value !== undefined ? [conditionState.value] : [];
36
- var contentRef = useRef();
37
46
  useEffect(function () {
47
+ // if(rest['data-name'] == 'valueField'){
48
+ // const fetchData = async () => {
49
+ // const response = await config.options(conditionState);
50
+ // if (
51
+ // response?.length > 0 &&
52
+ // Object.keys(response[0]).includes('label') &&
53
+ // Object.keys(response[0]).includes('id')
54
+ // ) {
55
+ // setAllOptions(response);
56
+ // setFilteredItems(response);
57
+ // }
58
+ // };
59
+
60
+ // fetchData(); // Call the async method
61
+ // }else{
62
+ // setAllOptions(config.options);
63
+ // setFilteredItems(config.options);
64
+ // }
65
+
38
66
  if (!allOptions && getOptions) {
39
67
  var fetchData = /*#__PURE__*/function () {
40
68
  var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
@@ -43,12 +71,11 @@ var ConditionBuilderItemOption = function ConditionBuilderItemOption(_ref) {
43
71
  while (1) switch (_context.prev = _context.next) {
44
72
  case 0:
45
73
  _context.next = 2;
46
- return getOptions(conditionState);
74
+ return getOptions(rootState, conditionState);
47
75
  case 2:
48
76
  response = _context.sent;
49
77
  if ((response === null || response === void 0 ? void 0 : response.length) > 0 && Object.keys(response[0]).includes('label') && Object.keys(response[0]).includes('id')) {
50
78
  setAllOptions(response);
51
- setFilteredItems(response);
52
79
  }
53
80
  case 4:
54
81
  case "end":
@@ -68,51 +95,55 @@ var ConditionBuilderItemOption = function ConditionBuilderItemOption(_ref) {
68
95
  //this will focus the first input field in the popover
69
96
 
70
97
  if (contentRef.current) {
71
- var _contentRef$current;
72
- var firstFocusableElement = (_contentRef$current = contentRef.current) === null || _contentRef$current === void 0 ? void 0 : _contentRef$current.querySelector('input, button,li');
73
- firstFocusableElement === null || firstFocusableElement === void 0 || firstFocusableElement.focus();
98
+ var firstFocusableElement = contentRef.current.querySelector('input, button,li');
99
+ if (firstFocusableElement) {
100
+ firstFocusableElement.focus();
101
+ }
74
102
  }
75
- // eslint-disable-next-line react-hooks/exhaustive-deps
76
103
  }, [allOptions]);
77
104
  var handleSelectAll = function handleSelectAll(evt) {
78
105
  if (evt.currentTarget.dataset.selectedAll == 'false') {
79
106
  onChange(undefined);
80
107
  } else {
81
- onChange(allOptions.map(function (op) {
82
- return op.id;
83
- }));
108
+ onChange(allOptions);
84
109
  }
85
110
  };
86
111
  var onSearchChangeHandler = function onSearchChangeHandler(evt) {
87
112
  var value = evt.target.value;
88
- var _filteredItems = allOptions.filter(function (opt) {
89
- return opt.label.toLowerCase().includes(value.toLowerCase());
90
- });
91
- setFilteredItems(_filteredItems);
113
+ setSearchValue(value);
92
114
  };
93
115
  var onClickHandler = function onClickHandler(evt, option, isSelected) {
116
+ var updatedSelections = selection.filter(function (item) {
117
+ return item !== 'INVALID';
118
+ });
94
119
  if (multiSelectable) {
95
120
  if (isSelected) {
96
- var items = selection.filter(function (v) {
97
- return v !== option.id;
121
+ var items = updatedSelections.filter(function (v) {
122
+ return v.id !== option.id;
98
123
  });
99
- onChange(items.length > 0 ? items : undefined, evt);
124
+ onChange(items.length > 0 ? items : undefined);
100
125
  } else {
101
- onChange([].concat(_toConsumableArray(selection), [option.id]), evt);
126
+ onChange([].concat(_toConsumableArray(updatedSelections), [option]));
102
127
  }
103
128
  } else {
104
- onChange(option.id, evt);
129
+ onChange(option, evt);
105
130
  }
106
131
  };
107
- return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, allOptions && /*#__PURE__*/React__default.createElement("div", {
132
+ var getAriaLabel = function getAriaLabel() {
133
+ return conditionState.label ? conditionState.label : conditionState.property ? conditionState.property : propertyText;
134
+ };
135
+ if (!allOptions) {
136
+ return _SelectSkeleton || (_SelectSkeleton = /*#__PURE__*/React__default.createElement(SelectSkeleton, null));
137
+ }
138
+ return /*#__PURE__*/React__default.createElement("div", {
108
139
  className: "".concat(blockClass, "__item-option"),
109
140
  ref: contentRef
110
- }, (config.includeSearch || allOptions.length > popOverSearchThreshold) && /*#__PURE__*/React__default.createElement("div", {
141
+ }, allOptions.length > popOverSearchThreshold && /*#__PURE__*/React__default.createElement("div", {
111
142
  className: "".concat(blockClass, "__item-option__search")
112
143
  }, /*#__PURE__*/React__default.createElement(Search, {
113
144
  size: "sm",
114
- labelText: translateWithId('clear_search'),
115
- closeButtonLabelText: translateWithId('clear_search'),
145
+ labelText: clearSearchText,
146
+ closeButtonLabelText: clearSearchText,
116
147
  onChange: onSearchChangeHandler
117
148
  })), multiSelectable && /*#__PURE__*/React__default.createElement("div", {
118
149
  className: "".concat(blockClass, "__multiselectSelectionStatusContainer")
@@ -123,11 +154,13 @@ var ConditionBuilderItemOption = function ConditionBuilderItemOption(_ref) {
123
154
  onClick: handleSelectAll,
124
155
  className: "".concat(blockClass, "__selectAll-button")
125
156
  }, selection.length == 0 ? 'Select all' : 'Deselect all')), /*#__PURE__*/React__default.createElement("ul", {
126
- "aria-label": conditionState.label ? conditionState.label : conditionState.property ? conditionState.property : translateWithId('property'),
157
+ "aria-label": getAriaLabel(),
127
158
  role: "listbox",
128
159
  "data-multi-select": multiSelectable
129
160
  }, filteredItems === null || filteredItems === void 0 ? void 0 : filteredItems.map(function (option) {
130
- var isSelected = selection.includes(option.id);
161
+ var isSelected = selection.map(function (option) {
162
+ return option.id;
163
+ }).includes(option.id);
131
164
  var Icon = option.icon;
132
165
  return /*#__PURE__*/React__default.createElement("li", {
133
166
  tabIndex: 0,
@@ -154,9 +187,9 @@ var ConditionBuilderItemOption = function ConditionBuilderItemOption(_ref) {
154
187
  }, Icon && /*#__PURE__*/React__default.createElement(Icon, null), option.label), isSelected && /*#__PURE__*/React__default.createElement(Checkmark, {
155
188
  className: "".concat(blockClass, "__checkmark")
156
189
  }))));
157
- }))), !allOptions && (_SelectSkeleton || (_SelectSkeleton = /*#__PURE__*/React__default.createElement(SelectSkeleton, null))));
190
+ })));
158
191
  };
159
- ConditionBuilderItemOption.propTypes = {
192
+ ItemOptionForValueField.propTypes = {
160
193
  /**
161
194
  * current condition object
162
195
  */
@@ -171,4 +204,4 @@ ConditionBuilderItemOption.propTypes = {
171
204
  onChange: PropTypes.func
172
205
  };
173
206
 
174
- export { ConditionBuilderItemOption };
207
+ export { ItemOptionForValueField };
@@ -1,11 +1,15 @@
1
- export function ConditionBuilderItemText({ conditionState, onChange }: {
1
+ export function ConditionBuilderItemText({ conditionState, onChange, config, type, }: {
2
2
  conditionState: any;
3
3
  onChange: any;
4
+ config: any;
5
+ type: any;
4
6
  }): import("react/jsx-runtime").JSX.Element;
5
7
  export namespace ConditionBuilderItemText {
6
8
  namespace propTypes {
7
9
  let conditionState: PropTypes.Requireable<object>;
10
+ let config: PropTypes.Requireable<object>;
8
11
  let onChange: PropTypes.Requireable<(...args: any[]) => any>;
12
+ let type: PropTypes.Requireable<string>;
9
13
  }
10
14
  }
11
15
  import PropTypes from 'prop-types';
@@ -5,36 +5,49 @@
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  */
7
7
 
8
+ import { objectSpread2 as _objectSpread2 } from '../../../../_virtual/_rollupPluginBabelHelpers.js';
8
9
  import React__default from 'react';
9
- import { TextInput } from '@carbon/react';
10
+ import { TextArea, TextInput } from '@carbon/react';
10
11
  import PropTypes from '../../../../node_modules/prop-types/index.js';
11
12
  import { blockClass } from '../../ConditionBuilderContext/DataConfigs.js';
13
+ import { checkIsValid } from '../../utils/util.js';
12
14
 
13
15
  var ConditionBuilderItemText = function ConditionBuilderItemText(_ref) {
14
- var _conditionState$value, _conditionState$prope;
16
+ var _conditionState$prope;
15
17
  var conditionState = _ref.conditionState,
16
- _onChange = _ref.onChange;
17
- return /*#__PURE__*/React__default.createElement("div", {
18
- className: "".concat(blockClass, "__item-text")
19
- }, /*#__PURE__*/React__default.createElement(TextInput, {
18
+ _onChange = _ref.onChange,
19
+ config = _ref.config,
20
+ type = _ref.type;
21
+ var inputProps = _objectSpread2({
20
22
  labelText: conditionState.property,
21
23
  hideLabel: true,
22
- value: (_conditionState$value = conditionState.value) !== null && _conditionState$value !== void 0 ? _conditionState$value : '',
24
+ value: checkIsValid(conditionState.value) ? conditionState.value : '',
23
25
  id: (_conditionState$prope = conditionState.property) === null || _conditionState$prope === void 0 ? void 0 : _conditionState$prope.replace(/\s/g, ''),
24
26
  onChange: function onChange(evt) {
25
27
  _onChange(evt.target.value);
26
28
  }
27
- }));
29
+ }, config);
30
+ return /*#__PURE__*/React__default.createElement("div", {
31
+ className: "".concat(blockClass, "__item-text")
32
+ }, type == 'textarea' ? /*#__PURE__*/React__default.createElement(TextArea, inputProps) : /*#__PURE__*/React__default.createElement(TextInput, inputProps));
28
33
  };
29
34
  ConditionBuilderItemText.propTypes = {
30
35
  /**
31
36
  * current condition object
32
37
  */
33
38
  conditionState: PropTypes.object,
39
+ /**
40
+ * config of the current property
41
+ */
42
+ config: PropTypes.object,
34
43
  /**
35
44
  * callback to update state oin date change
36
45
  */
37
- onChange: PropTypes.func
46
+ onChange: PropTypes.func,
47
+ /**
48
+ * current input type
49
+ */
50
+ type: PropTypes.string
38
51
  };
39
52
 
40
53
  export { ConditionBuilderItemText };
@@ -58,7 +58,7 @@ var ConditionBuilderItemTime = function ConditionBuilderItemTime(_ref) {
58
58
  value: "PM",
59
59
  text: "PM"
60
60
  }))), /*#__PURE__*/React__default.createElement(TimePickerSelect, {
61
- id: "time-picker-select-2",
61
+ id: "time-picker-time-zone",
62
62
  onChange: setTimeZone
63
63
  }, config === null || config === void 0 || (_config$timeZones2 = config.timeZones) === null || _config$timeZones2 === void 0 ? void 0 : _config$timeZones2.map(function (timeZone, index) {
64
64
  return /*#__PURE__*/React__default.createElement(SelectItem, {
@@ -5,19 +5,17 @@ export default ConditionGroupBuilder;
5
5
  * All the inner components of group are called from here.
6
6
  * @returns
7
7
  */
8
- declare function ConditionGroupBuilder({ group, aria, onRemove, onChange, conditionBuilderRef, className, }: {
8
+ declare function ConditionGroupBuilder({ group, aria, onRemove, onChange, className, }: {
9
9
  group: any;
10
10
  aria: any;
11
11
  onRemove: any;
12
12
  onChange: any;
13
- conditionBuilderRef: any;
14
13
  className: any;
15
14
  }): import("react/jsx-runtime").JSX.Element;
16
15
  declare namespace ConditionGroupBuilder {
17
16
  namespace propTypes {
18
17
  let aria: PropTypes.Requireable<object>;
19
18
  let className: PropTypes.Requireable<string>;
20
- let conditionBuilderRef: PropTypes.Requireable<object>;
21
19
  let group: PropTypes.Requireable<object>;
22
20
  let onChange: PropTypes.Requireable<(...args: any[]) => any>;
23
21
  let onRemove: PropTypes.Requireable<(...args: any[]) => any>;