@itwin/grouping-mapping-widget 0.26.0 → 0.26.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (579) hide show
  1. package/LICENSE.md +9 -9
  2. package/README.md +115 -115
  3. package/lib/cjs/WidgetShell/GroupingMapping.js +2 -4
  4. package/lib/cjs/WidgetShell/GroupingMapping.js.map +1 -1
  5. package/lib/cjs/WidgetShell/GroupingMappingContent.js +4 -4
  6. package/lib/cjs/WidgetShell/GroupingMappingContent.js.map +1 -1
  7. package/lib/cjs/WidgetShell/GroupingMappingHeader.d.ts +1 -1
  8. package/lib/cjs/WidgetShell/GroupingMappingHeader.js +5 -5
  9. package/lib/cjs/WidgetShell/GroupingMappingHeader.js.map +1 -1
  10. package/lib/cjs/WidgetShell/GroupingMappingWidget.js +1 -3
  11. package/lib/cjs/WidgetShell/GroupingMappingWidget.js.map +1 -1
  12. package/lib/cjs/WidgetShell/Router/GroupingMappingRouter.js +28 -8
  13. package/lib/cjs/WidgetShell/Router/GroupingMappingRouter.js.map +1 -1
  14. package/lib/cjs/WidgetShell/WidgetHeader/WidgetHeader.d.ts +1 -1
  15. package/lib/cjs/WidgetShell/WidgetHeader/WidgetHeader.js +7 -7
  16. package/lib/cjs/WidgetShell/WidgetHeader/WidgetHeader.js.map +1 -1
  17. package/lib/cjs/common/hooks/useIsMounted.js +3 -3
  18. package/lib/cjs/common/hooks/useIsMounted.js.map +1 -1
  19. package/lib/cjs/common/hooks/useMemoizedCollectionPick.js +3 -3
  20. package/lib/cjs/common/hooks/useMemoizedCollectionPick.js.map +1 -1
  21. package/lib/cjs/common/utils.js +3 -3
  22. package/lib/cjs/common/utils.js.map +1 -1
  23. package/lib/cjs/common/viewerUtils.js +2 -2
  24. package/lib/cjs/common/viewerUtils.js.map +1 -1
  25. package/lib/cjs/components/Constants.js +4 -4
  26. package/lib/cjs/components/Constants.js.map +1 -1
  27. package/lib/cjs/components/GroupingMappingContext.js +13 -4
  28. package/lib/cjs/components/GroupingMappingContext.js.map +1 -1
  29. package/lib/cjs/components/Groups/Editing/GroupAction.js +7 -9
  30. package/lib/cjs/components/Groups/Editing/GroupAction.js.map +1 -1
  31. package/lib/cjs/components/Groups/Editing/GroupDetails.d.ts +1 -1
  32. package/lib/cjs/components/Groups/Editing/GroupDetails.js +5 -7
  33. package/lib/cjs/components/Groups/Editing/GroupDetails.js.map +1 -1
  34. package/lib/cjs/components/Groups/Editing/GroupDetailsActionPanel.d.ts +1 -1
  35. package/lib/cjs/components/Groups/Editing/GroupDetailsActionPanel.js +4 -4
  36. package/lib/cjs/components/Groups/Editing/GroupDetailsActionPanel.js.map +1 -1
  37. package/lib/cjs/components/Groups/Editing/GroupDetailsStep.js +4 -4
  38. package/lib/cjs/components/Groups/Editing/GroupDetailsStep.js.map +1 -1
  39. package/lib/cjs/components/Groups/GroupColorLegend.js +3 -3
  40. package/lib/cjs/components/Groups/GroupColorLegend.js.map +1 -1
  41. package/lib/cjs/components/Groups/GroupListItem.js +3 -4
  42. package/lib/cjs/components/Groups/GroupListItem.js.map +1 -1
  43. package/lib/cjs/components/Groups/GroupListItem.scss +2 -2
  44. package/lib/cjs/components/Groups/GroupMenuActions.js +17 -6
  45. package/lib/cjs/components/Groups/GroupMenuActions.js.map +1 -1
  46. package/lib/cjs/components/Groups/GroupOverlapProgressBar.js.map +1 -1
  47. package/lib/cjs/components/Groups/Groups.js +3 -3
  48. package/lib/cjs/components/Groups/Groups.js.map +1 -1
  49. package/lib/cjs/components/Groups/GroupsAddButton.d.ts +1 -1
  50. package/lib/cjs/components/Groups/GroupsAddButton.js +4 -4
  51. package/lib/cjs/components/Groups/GroupsAddButton.js.map +1 -1
  52. package/lib/cjs/components/Groups/GroupsAddButton.scss +1 -1
  53. package/lib/cjs/components/Groups/GroupsShowHideButtons.d.ts +1 -1
  54. package/lib/cjs/components/Groups/GroupsShowHideButtons.js +2 -2
  55. package/lib/cjs/components/Groups/GroupsShowHideButtons.js.map +1 -1
  56. package/lib/cjs/components/Groups/GroupsView.js +8 -10
  57. package/lib/cjs/components/Groups/GroupsView.js.map +1 -1
  58. package/lib/cjs/components/Groups/GroupsView.scss +1 -1
  59. package/lib/cjs/components/Groups/GroupsVisualization.js +19 -20
  60. package/lib/cjs/components/Groups/GroupsVisualization.js.map +1 -1
  61. package/lib/cjs/components/Groups/GroupsVisualizationActions.js +4 -4
  62. package/lib/cjs/components/Groups/GroupsVisualizationActions.js.map +1 -1
  63. package/lib/cjs/components/Groups/OverlappedElementsInformationPanel.d.ts +1 -1
  64. package/lib/cjs/components/Groups/OverlappedElementsInformationPanel.js +4 -4
  65. package/lib/cjs/components/Groups/OverlappedElementsInformationPanel.js.map +1 -1
  66. package/lib/cjs/components/Groups/OverlappedElementsInformationPanel.scss +7 -7
  67. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilder.js +13 -35
  68. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilder.js.map +1 -1
  69. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderActionPanel.js +4 -4
  70. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderActionPanel.js.map +1 -1
  71. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderCustomUI.d.ts +1 -1
  72. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderCustomUI.js +4 -4
  73. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderCustomUI.js.map +1 -1
  74. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderStep.js +4 -4
  75. package/lib/cjs/components/Groups/QueryBuilder/QueryBuilderStep.js.map +1 -1
  76. package/lib/cjs/components/Groups/ToggleGroupVisibility.js +3 -3
  77. package/lib/cjs/components/Groups/ToggleGroupVisibility.js.map +1 -1
  78. package/lib/cjs/components/Groups/groupsHelpers.js +8 -4
  79. package/lib/cjs/components/Groups/groupsHelpers.js.map +1 -1
  80. package/lib/cjs/components/Groups/hooks/useFetchGroups.js.map +1 -1
  81. package/lib/cjs/components/Groups/hooks/useGroupsOperations.d.ts +1 -1
  82. package/lib/cjs/components/Groups/hooks/useGroupsOperations.js +5 -5
  83. package/lib/cjs/components/Groups/hooks/useGroupsOperations.js.map +1 -1
  84. package/lib/cjs/components/Groups/hooks/useKeySetHiliteQueries.js.map +1 -1
  85. package/lib/cjs/components/Groups/hooks/useVisualization.js +2 -4
  86. package/lib/cjs/components/Groups/hooks/useVisualization.js.map +1 -1
  87. package/lib/cjs/components/Mappings/BlockingOverlay.js +3 -3
  88. package/lib/cjs/components/Mappings/BlockingOverlay.js.map +1 -1
  89. package/lib/cjs/components/Mappings/Editing/MappingAction.js +11 -15
  90. package/lib/cjs/components/Mappings/Editing/MappingAction.js.map +1 -1
  91. package/lib/cjs/components/Mappings/Extraction/ExtractionLogCustomFilter.d.ts +1 -1
  92. package/lib/cjs/components/Mappings/Extraction/ExtractionLogCustomFilter.js +1 -1
  93. package/lib/cjs/components/Mappings/Extraction/ExtractionLogCustomFilter.js.map +1 -1
  94. package/lib/cjs/components/Mappings/Extraction/ExtractionMessageModal.js +9 -6
  95. package/lib/cjs/components/Mappings/Extraction/ExtractionMessageModal.js.map +1 -1
  96. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/QueuedExtractionState.js +3 -3
  97. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/QueuedExtractionState.js.map +1 -1
  98. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/RunningExtractionState.js +3 -3
  99. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/RunningExtractionState.js.map +1 -1
  100. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/StartingExtractionState.js +3 -3
  101. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/StartingExtractionState.js.map +1 -1
  102. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/TerminalExtractionState.js +3 -3
  103. package/lib/cjs/components/Mappings/Extraction/ExtractionStates/TerminalExtractionState.js.map +1 -1
  104. package/lib/cjs/components/Mappings/Extraction/ExtractionStatus.d.ts +1 -1
  105. package/lib/cjs/components/Mappings/Extraction/ExtractionStatus.js +9 -9
  106. package/lib/cjs/components/Mappings/Extraction/ExtractionStatus.js.map +1 -1
  107. package/lib/cjs/components/Mappings/Extraction/ExtractionStatusIcon.js +4 -4
  108. package/lib/cjs/components/Mappings/Extraction/ExtractionStatusIcon.js.map +1 -1
  109. package/lib/cjs/components/Mappings/Import/ConfirmMappingsImport.js +26 -30
  110. package/lib/cjs/components/Mappings/Import/ConfirmMappingsImport.js.map +1 -1
  111. package/lib/cjs/components/Mappings/Import/MappingImportWizardModal.d.ts +1 -1
  112. package/lib/cjs/components/Mappings/Import/MappingImportWizardModal.js +3 -3
  113. package/lib/cjs/components/Mappings/Import/MappingImportWizardModal.js.map +1 -1
  114. package/lib/cjs/components/Mappings/Import/SelectIModel.d.ts +1 -1
  115. package/lib/cjs/components/Mappings/Import/SelectIModel.js +5 -5
  116. package/lib/cjs/components/Mappings/Import/SelectIModel.js.map +1 -1
  117. package/lib/cjs/components/Mappings/Import/SelectITwin.js +2 -2
  118. package/lib/cjs/components/Mappings/Import/SelectITwin.js.map +1 -1
  119. package/lib/cjs/components/Mappings/Import/SelectITwin.scss +1 -1
  120. package/lib/cjs/components/Mappings/Import/SelectMappings.d.ts +1 -1
  121. package/lib/cjs/components/Mappings/Import/SelectMappings.js +7 -7
  122. package/lib/cjs/components/Mappings/Import/SelectMappings.js.map +1 -1
  123. package/lib/cjs/components/Mappings/MappingListItem.js.map +1 -1
  124. package/lib/cjs/components/Mappings/MappingViewActionGroup.d.ts +1 -1
  125. package/lib/cjs/components/Mappings/MappingViewActionGroup.js +6 -6
  126. package/lib/cjs/components/Mappings/MappingViewActionGroup.js.map +1 -1
  127. package/lib/cjs/components/Mappings/Mappings.js +3 -3
  128. package/lib/cjs/components/Mappings/Mappings.js.map +1 -1
  129. package/lib/cjs/components/Mappings/MappingsView.js +13 -15
  130. package/lib/cjs/components/Mappings/MappingsView.js.map +1 -1
  131. package/lib/cjs/components/Mappings/hooks/useFetchExtractionStatus.js +3 -1
  132. package/lib/cjs/components/Mappings/hooks/useFetchExtractionStatus.js.map +1 -1
  133. package/lib/cjs/components/Mappings/hooks/useFetchMappingExtractionStatus.d.ts +1 -1
  134. package/lib/cjs/components/Mappings/hooks/useFetchMappingExtractionStatus.js +3 -3
  135. package/lib/cjs/components/Mappings/hooks/useFetchMappingExtractionStatus.js.map +1 -1
  136. package/lib/cjs/components/Mappings/hooks/useFetchMappings.js +1 -1
  137. package/lib/cjs/components/Mappings/hooks/useFetchMappings.js.map +1 -1
  138. package/lib/cjs/components/Mappings/hooks/useMappingsOperations.js +36 -18
  139. package/lib/cjs/components/Mappings/hooks/useMappingsOperations.js.map +1 -1
  140. package/lib/cjs/components/Mappings/hooks/useRunExtraction.d.ts +1 -1
  141. package/lib/cjs/components/Mappings/hooks/useRunExtraction.js +8 -6
  142. package/lib/cjs/components/Mappings/hooks/useRunExtraction.js.map +1 -1
  143. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyAction.d.ts +1 -1
  144. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyAction.js +8 -8
  145. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyAction.js.map +1 -1
  146. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyActionWithVisuals.js +11 -13
  147. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyActionWithVisuals.js.map +1 -1
  148. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyTable.js +1 -1
  149. package/lib/cjs/components/Properties/CalculatedProperties/CalculatedPropertyTable.js.map +1 -1
  150. package/lib/cjs/components/Properties/CalculatedProperties/SharedCalculatedPropertyForms.js +4 -6
  151. package/lib/cjs/components/Properties/CalculatedProperties/SharedCalculatedPropertyForms.js.map +1 -1
  152. package/lib/cjs/components/Properties/CustomCalculations/CustomCalculationAction.d.ts +1 -1
  153. package/lib/cjs/components/Properties/CustomCalculations/CustomCalculationAction.js +27 -21
  154. package/lib/cjs/components/Properties/CustomCalculations/CustomCalculationAction.js.map +1 -1
  155. package/lib/cjs/components/Properties/CustomCalculations/CustomCalculationAction.scss +1 -1
  156. package/lib/cjs/components/Properties/CustomCalculations/CustomCalculationTable.js +15 -11
  157. package/lib/cjs/components/Properties/CustomCalculations/CustomCalculationTable.js.map +1 -1
  158. package/lib/cjs/components/Properties/GroupColorToggle.js +4 -4
  159. package/lib/cjs/components/Properties/GroupColorToggle.js.map +1 -1
  160. package/lib/cjs/components/Properties/GroupInformationPanel.js +3 -3
  161. package/lib/cjs/components/Properties/GroupInformationPanel.js.map +1 -1
  162. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyAction.d.ts +1 -1
  163. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyAction.js +20 -27
  164. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyAction.js.map +1 -1
  165. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyListItem.d.ts +1 -1
  166. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyListItem.js +5 -5
  167. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyListItem.js.map +1 -1
  168. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyTable.d.ts +1 -1
  169. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyTable.js +14 -12
  170. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyTable.js.map +1 -1
  171. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyUtils.js +20 -39
  172. package/lib/cjs/components/Properties/GroupProperties/GroupPropertyUtils.js.map +1 -1
  173. package/lib/cjs/components/Properties/GroupProperties/GroupsPropertiesSelectionModal.js +20 -29
  174. package/lib/cjs/components/Properties/GroupProperties/GroupsPropertiesSelectionModal.js.map +1 -1
  175. package/lib/cjs/components/Properties/GroupProperties/SaveModal.d.ts +1 -1
  176. package/lib/cjs/components/Properties/GroupProperties/SaveModal.js +7 -7
  177. package/lib/cjs/components/Properties/GroupProperties/SaveModal.js.map +1 -1
  178. package/lib/cjs/components/Properties/GroupProperties/SortableHorizontalTile.js +4 -4
  179. package/lib/cjs/components/Properties/GroupProperties/SortableHorizontalTile.js.map +1 -1
  180. package/lib/cjs/components/Properties/PropertyAction.js +9 -21
  181. package/lib/cjs/components/Properties/PropertyAction.js.map +1 -1
  182. package/lib/cjs/components/Properties/PropertyMenu.js +4 -4
  183. package/lib/cjs/components/Properties/PropertyMenu.js.map +1 -1
  184. package/lib/cjs/components/Properties/PropertyMenuWithVisualization.js +5 -5
  185. package/lib/cjs/components/Properties/PropertyMenuWithVisualization.js.map +1 -1
  186. package/lib/cjs/components/Properties/PropertyNameCell.d.ts +1 -1
  187. package/lib/cjs/components/Properties/PropertyNameCell.js +4 -4
  188. package/lib/cjs/components/Properties/PropertyNameCell.js.map +1 -1
  189. package/lib/cjs/components/Properties/PropertyTable.js +5 -6
  190. package/lib/cjs/components/Properties/PropertyTable.js.map +1 -1
  191. package/lib/cjs/components/Properties/PropertyTableToolbar.d.ts +1 -1
  192. package/lib/cjs/components/Properties/PropertyTableToolbar.js +4 -4
  193. package/lib/cjs/components/Properties/PropertyTableToolbar.js.map +1 -1
  194. package/lib/cjs/components/Properties/hooks/useFormulaValidation.js +3 -3
  195. package/lib/cjs/components/Properties/hooks/useFormulaValidation.js.map +1 -1
  196. package/lib/cjs/components/Properties/hooks/usePropertiesQuery.js.map +1 -1
  197. package/lib/cjs/components/Properties/hooks/useValidator.js +4 -4
  198. package/lib/cjs/components/Properties/hooks/useValidator.js.map +1 -1
  199. package/lib/cjs/components/SharedComponents/ActionPanel.d.ts +1 -1
  200. package/lib/cjs/components/SharedComponents/ActionPanel.js +9 -10
  201. package/lib/cjs/components/SharedComponents/ActionPanel.js.map +1 -1
  202. package/lib/cjs/components/SharedComponents/DeleteModal.d.ts +1 -1
  203. package/lib/cjs/components/SharedComponents/DeleteModal.js +9 -10
  204. package/lib/cjs/components/SharedComponents/DeleteModal.js.map +1 -1
  205. package/lib/cjs/components/SharedComponents/EmptyMessage.js +4 -4
  206. package/lib/cjs/components/SharedComponents/EmptyMessage.js.map +1 -1
  207. package/lib/cjs/components/SharedComponents/LoadingOverlay.js +4 -4
  208. package/lib/cjs/components/SharedComponents/LoadingOverlay.js.map +1 -1
  209. package/lib/cjs/components/SharedComponents/LoadingSpinner.js +3 -3
  210. package/lib/cjs/components/SharedComponents/LoadingSpinner.js.map +1 -1
  211. package/lib/cjs/components/SharedComponents/StatusIcon.js +3 -3
  212. package/lib/cjs/components/SharedComponents/StatusIcon.js.map +1 -1
  213. package/lib/cjs/components/context/ExtractionClientContext.js.map +1 -1
  214. package/lib/cjs/components/context/ExtractionStateJobContext.js +3 -3
  215. package/lib/cjs/components/context/ExtractionStateJobContext.js.map +1 -1
  216. package/lib/cjs/components/context/GroupHilitedElementsContext.js +3 -3
  217. package/lib/cjs/components/context/GroupHilitedElementsContext.js.map +1 -1
  218. package/lib/cjs/components/context/GroupingApiConfigContext.js.map +1 -1
  219. package/lib/cjs/components/context/GroupingMappingCustomUIContext.js +3 -3
  220. package/lib/cjs/components/context/GroupingMappingCustomUIContext.js.map +1 -1
  221. package/lib/cjs/components/context/GroupsClientContext.js.map +1 -1
  222. package/lib/cjs/components/context/IModelsClientContext.js.map +1 -1
  223. package/lib/cjs/components/context/ITwinsClientContext.js +3 -3
  224. package/lib/cjs/components/context/ITwinsClientContext.js.map +1 -1
  225. package/lib/cjs/components/context/MappingClientContext.js.map +1 -1
  226. package/lib/cjs/components/context/PropertiesClientContext.js.map +1 -1
  227. package/lib/cjs/components/context/PropertiesGroupColorContext.js +3 -3
  228. package/lib/cjs/components/context/PropertiesGroupColorContext.js.map +1 -1
  229. package/lib/cjs/components/context/PropertyGridWrapperContext.js +3 -3
  230. package/lib/cjs/components/context/PropertyGridWrapperContext.js.map +1 -1
  231. package/lib/cjs/components/customUI/DefaultGroupingUI.js +3 -3
  232. package/lib/cjs/components/customUI/DefaultGroupingUI.js.map +1 -1
  233. package/lib/cjs/components/customUI/GroupQueryBuilderCustomUI.d.ts +1 -1
  234. package/lib/cjs/components/customUI/GroupQueryBuilderCustomUI.js +13 -18
  235. package/lib/cjs/components/customUI/GroupQueryBuilderCustomUI.js.map +1 -1
  236. package/lib/cjs/components/customUI/GroupingMappingCustomUI.js.map +1 -1
  237. package/lib/cjs/components/customUI/ManualGroupingCustomUI.d.ts +1 -1
  238. package/lib/cjs/components/customUI/ManualGroupingCustomUI.js +8 -8
  239. package/lib/cjs/components/customUI/ManualGroupingCustomUI.js.map +1 -1
  240. package/lib/cjs/components/customUI/SearchGroupingCustomUI.d.ts +1 -1
  241. package/lib/cjs/components/customUI/SearchGroupingCustomUI.js +16 -45
  242. package/lib/cjs/components/customUI/SearchGroupingCustomUI.js.map +1 -1
  243. package/lib/cjs/decorators/BboxDimensionsDecorator.js +3 -10
  244. package/lib/cjs/decorators/BboxDimensionsDecorator.js.map +1 -1
  245. package/lib/cjs/formula/FormulaDataTypeResolver.js +3 -3
  246. package/lib/cjs/formula/FormulaDataTypeResolver.js.map +1 -1
  247. package/lib/cjs/formula/FormulaFunctionProvider.js +146 -65
  248. package/lib/cjs/formula/FormulaFunctionProvider.js.map +1 -1
  249. package/lib/cjs/formula/FormulaOperatorsProvider.js +138 -44
  250. package/lib/cjs/formula/FormulaOperatorsProvider.js.map +1 -1
  251. package/lib/cjs/formula/FormulaSplitter.js +63 -13
  252. package/lib/cjs/formula/FormulaSplitter.js.map +1 -1
  253. package/lib/cjs/formula/FormulaTokensDataTypeResolver.js +7 -14
  254. package/lib/cjs/formula/FormulaTokensDataTypeResolver.js.map +1 -1
  255. package/lib/cjs/formula/IResult.js.map +1 -1
  256. package/lib/cjs/formula/InfixToPostfixConverter.js +4 -4
  257. package/lib/cjs/formula/InfixToPostfixConverter.js.map +1 -1
  258. package/lib/cjs/formula/InputStream.js +3 -3
  259. package/lib/cjs/formula/InputStream.js.map +1 -1
  260. package/lib/cjs/formula/ParenthesisValidator.js +3 -3
  261. package/lib/cjs/formula/ParenthesisValidator.js.map +1 -1
  262. package/lib/cjs/formula/Queue.js +3 -3
  263. package/lib/cjs/formula/Queue.js.map +1 -1
  264. package/lib/cjs/formula/Stack.js +3 -3
  265. package/lib/cjs/formula/Stack.js.map +1 -1
  266. package/lib/cjs/formula/StringBuilder.js +3 -3
  267. package/lib/cjs/formula/StringBuilder.js.map +1 -1
  268. package/lib/cjs/formula/Types.js.map +1 -1
  269. package/lib/cjs/formula/Utils.js +4 -4
  270. package/lib/cjs/formula/Utils.js.map +1 -1
  271. package/lib/cjs/grouping-mapping-widget.d.ts +4 -4
  272. package/lib/cjs/grouping-mapping-widget.js +3 -3
  273. package/lib/cjs/grouping-mapping-widget.js.map +1 -1
  274. package/lib/cjs/test/GroupPropertyUtils.test.js +27 -26
  275. package/lib/cjs/test/GroupPropertyUtils.test.js.map +1 -1
  276. package/lib/cjs/test/GroupingMappingCustomUI.test.js +4 -6
  277. package/lib/cjs/test/GroupingMappingCustomUI.test.js.map +1 -1
  278. package/lib/cjs/test/MockFactory.js +3 -3
  279. package/lib/cjs/test/MockFactory.js.map +1 -1
  280. package/lib/cjs/test/PropertyFieldsHelpers.js +3 -3
  281. package/lib/cjs/test/PropertyFieldsHelpers.js.map +1 -1
  282. package/lib/cjs/test/QueryBuilder.test.js +3 -3
  283. package/lib/cjs/test/QueryBuilder.test.js.map +1 -1
  284. package/lib/cjs/test/QueryBuilder.testdata.js +3 -3
  285. package/lib/cjs/test/QueryBuilder.testdata.js.map +1 -1
  286. package/lib/cjs/test/QueryBuilderTestData.js.map +1 -1
  287. package/lib/cjs/test/WidgetHeader.test.js +3 -3
  288. package/lib/cjs/test/WidgetHeader.test.js.map +1 -1
  289. package/lib/cjs/test/test-utils.js +4 -4
  290. package/lib/cjs/test/test-utils.js.map +1 -1
  291. package/lib/esm/WidgetShell/GroupingMapping.js +3 -5
  292. package/lib/esm/WidgetShell/GroupingMapping.js.map +1 -1
  293. package/lib/esm/WidgetShell/GroupingMappingContent.js +4 -4
  294. package/lib/esm/WidgetShell/GroupingMappingContent.js.map +1 -1
  295. package/lib/esm/WidgetShell/GroupingMappingHeader.d.ts +1 -1
  296. package/lib/esm/WidgetShell/GroupingMappingHeader.js +5 -5
  297. package/lib/esm/WidgetShell/GroupingMappingHeader.js.map +1 -1
  298. package/lib/esm/WidgetShell/GroupingMappingWidget.js +2 -4
  299. package/lib/esm/WidgetShell/GroupingMappingWidget.js.map +1 -1
  300. package/lib/esm/WidgetShell/Router/GroupingMappingRouter.js +28 -8
  301. package/lib/esm/WidgetShell/Router/GroupingMappingRouter.js.map +1 -1
  302. package/lib/esm/WidgetShell/WidgetHeader/WidgetHeader.d.ts +1 -1
  303. package/lib/esm/WidgetShell/WidgetHeader/WidgetHeader.js +7 -7
  304. package/lib/esm/WidgetShell/WidgetHeader/WidgetHeader.js.map +1 -1
  305. package/lib/esm/common/hooks/useIsMounted.js +3 -3
  306. package/lib/esm/common/hooks/useIsMounted.js.map +1 -1
  307. package/lib/esm/common/hooks/useMemoizedCollectionPick.js +3 -3
  308. package/lib/esm/common/hooks/useMemoizedCollectionPick.js.map +1 -1
  309. package/lib/esm/common/utils.js +3 -3
  310. package/lib/esm/common/utils.js.map +1 -1
  311. package/lib/esm/common/viewerUtils.js +2 -2
  312. package/lib/esm/common/viewerUtils.js.map +1 -1
  313. package/lib/esm/components/Constants.js +4 -4
  314. package/lib/esm/components/Constants.js.map +1 -1
  315. package/lib/esm/components/GroupingMappingContext.js +14 -5
  316. package/lib/esm/components/GroupingMappingContext.js.map +1 -1
  317. package/lib/esm/components/Groups/Editing/GroupAction.js +8 -10
  318. package/lib/esm/components/Groups/Editing/GroupAction.js.map +1 -1
  319. package/lib/esm/components/Groups/Editing/GroupDetails.d.ts +1 -1
  320. package/lib/esm/components/Groups/Editing/GroupDetails.js +5 -7
  321. package/lib/esm/components/Groups/Editing/GroupDetails.js.map +1 -1
  322. package/lib/esm/components/Groups/Editing/GroupDetailsActionPanel.d.ts +1 -1
  323. package/lib/esm/components/Groups/Editing/GroupDetailsActionPanel.js +4 -4
  324. package/lib/esm/components/Groups/Editing/GroupDetailsActionPanel.js.map +1 -1
  325. package/lib/esm/components/Groups/Editing/GroupDetailsStep.js +4 -4
  326. package/lib/esm/components/Groups/Editing/GroupDetailsStep.js.map +1 -1
  327. package/lib/esm/components/Groups/GroupColorLegend.js +3 -3
  328. package/lib/esm/components/Groups/GroupColorLegend.js.map +1 -1
  329. package/lib/esm/components/Groups/GroupListItem.js +3 -4
  330. package/lib/esm/components/Groups/GroupListItem.js.map +1 -1
  331. package/lib/esm/components/Groups/GroupListItem.scss +2 -2
  332. package/lib/esm/components/Groups/GroupMenuActions.js +17 -6
  333. package/lib/esm/components/Groups/GroupMenuActions.js.map +1 -1
  334. package/lib/esm/components/Groups/GroupOverlapProgressBar.js.map +1 -1
  335. package/lib/esm/components/Groups/Groups.js +3 -3
  336. package/lib/esm/components/Groups/Groups.js.map +1 -1
  337. package/lib/esm/components/Groups/GroupsAddButton.d.ts +1 -1
  338. package/lib/esm/components/Groups/GroupsAddButton.js +4 -4
  339. package/lib/esm/components/Groups/GroupsAddButton.js.map +1 -1
  340. package/lib/esm/components/Groups/GroupsAddButton.scss +1 -1
  341. package/lib/esm/components/Groups/GroupsShowHideButtons.d.ts +1 -1
  342. package/lib/esm/components/Groups/GroupsShowHideButtons.js +2 -2
  343. package/lib/esm/components/Groups/GroupsShowHideButtons.js.map +1 -1
  344. package/lib/esm/components/Groups/GroupsView.js +10 -12
  345. package/lib/esm/components/Groups/GroupsView.js.map +1 -1
  346. package/lib/esm/components/Groups/GroupsView.scss +1 -1
  347. package/lib/esm/components/Groups/GroupsVisualization.js +21 -22
  348. package/lib/esm/components/Groups/GroupsVisualization.js.map +1 -1
  349. package/lib/esm/components/Groups/GroupsVisualizationActions.js +4 -4
  350. package/lib/esm/components/Groups/GroupsVisualizationActions.js.map +1 -1
  351. package/lib/esm/components/Groups/OverlappedElementsInformationPanel.d.ts +1 -1
  352. package/lib/esm/components/Groups/OverlappedElementsInformationPanel.js +5 -5
  353. package/lib/esm/components/Groups/OverlappedElementsInformationPanel.js.map +1 -1
  354. package/lib/esm/components/Groups/OverlappedElementsInformationPanel.scss +7 -7
  355. package/lib/esm/components/Groups/QueryBuilder/QueryBuilder.js +13 -35
  356. package/lib/esm/components/Groups/QueryBuilder/QueryBuilder.js.map +1 -1
  357. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderActionPanel.js +4 -4
  358. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderActionPanel.js.map +1 -1
  359. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderCustomUI.d.ts +1 -1
  360. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderCustomUI.js +4 -4
  361. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderCustomUI.js.map +1 -1
  362. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderStep.js +4 -4
  363. package/lib/esm/components/Groups/QueryBuilder/QueryBuilderStep.js.map +1 -1
  364. package/lib/esm/components/Groups/ToggleGroupVisibility.js +3 -3
  365. package/lib/esm/components/Groups/ToggleGroupVisibility.js.map +1 -1
  366. package/lib/esm/components/Groups/groupsHelpers.js +9 -5
  367. package/lib/esm/components/Groups/groupsHelpers.js.map +1 -1
  368. package/lib/esm/components/Groups/hooks/useFetchGroups.js.map +1 -1
  369. package/lib/esm/components/Groups/hooks/useGroupsOperations.d.ts +1 -1
  370. package/lib/esm/components/Groups/hooks/useGroupsOperations.js +5 -5
  371. package/lib/esm/components/Groups/hooks/useGroupsOperations.js.map +1 -1
  372. package/lib/esm/components/Groups/hooks/useKeySetHiliteQueries.js.map +1 -1
  373. package/lib/esm/components/Groups/hooks/useVisualization.js +3 -5
  374. package/lib/esm/components/Groups/hooks/useVisualization.js.map +1 -1
  375. package/lib/esm/components/Mappings/BlockingOverlay.js +3 -3
  376. package/lib/esm/components/Mappings/BlockingOverlay.js.map +1 -1
  377. package/lib/esm/components/Mappings/Editing/MappingAction.js +11 -15
  378. package/lib/esm/components/Mappings/Editing/MappingAction.js.map +1 -1
  379. package/lib/esm/components/Mappings/Extraction/ExtractionLogCustomFilter.d.ts +1 -1
  380. package/lib/esm/components/Mappings/Extraction/ExtractionLogCustomFilter.js +1 -1
  381. package/lib/esm/components/Mappings/Extraction/ExtractionLogCustomFilter.js.map +1 -1
  382. package/lib/esm/components/Mappings/Extraction/ExtractionMessageModal.js +9 -6
  383. package/lib/esm/components/Mappings/Extraction/ExtractionMessageModal.js.map +1 -1
  384. package/lib/esm/components/Mappings/Extraction/ExtractionStates/QueuedExtractionState.js +3 -3
  385. package/lib/esm/components/Mappings/Extraction/ExtractionStates/QueuedExtractionState.js.map +1 -1
  386. package/lib/esm/components/Mappings/Extraction/ExtractionStates/RunningExtractionState.js +3 -3
  387. package/lib/esm/components/Mappings/Extraction/ExtractionStates/RunningExtractionState.js.map +1 -1
  388. package/lib/esm/components/Mappings/Extraction/ExtractionStates/StartingExtractionState.js +3 -3
  389. package/lib/esm/components/Mappings/Extraction/ExtractionStates/StartingExtractionState.js.map +1 -1
  390. package/lib/esm/components/Mappings/Extraction/ExtractionStates/TerminalExtractionState.js +3 -3
  391. package/lib/esm/components/Mappings/Extraction/ExtractionStates/TerminalExtractionState.js.map +1 -1
  392. package/lib/esm/components/Mappings/Extraction/ExtractionStatus.d.ts +1 -1
  393. package/lib/esm/components/Mappings/Extraction/ExtractionStatus.js +9 -9
  394. package/lib/esm/components/Mappings/Extraction/ExtractionStatus.js.map +1 -1
  395. package/lib/esm/components/Mappings/Extraction/ExtractionStatusIcon.js +4 -4
  396. package/lib/esm/components/Mappings/Extraction/ExtractionStatusIcon.js.map +1 -1
  397. package/lib/esm/components/Mappings/Import/ConfirmMappingsImport.js +27 -31
  398. package/lib/esm/components/Mappings/Import/ConfirmMappingsImport.js.map +1 -1
  399. package/lib/esm/components/Mappings/Import/MappingImportWizardModal.d.ts +1 -1
  400. package/lib/esm/components/Mappings/Import/MappingImportWizardModal.js +3 -3
  401. package/lib/esm/components/Mappings/Import/MappingImportWizardModal.js.map +1 -1
  402. package/lib/esm/components/Mappings/Import/SelectIModel.d.ts +1 -1
  403. package/lib/esm/components/Mappings/Import/SelectIModel.js +5 -5
  404. package/lib/esm/components/Mappings/Import/SelectIModel.js.map +1 -1
  405. package/lib/esm/components/Mappings/Import/SelectITwin.js +2 -2
  406. package/lib/esm/components/Mappings/Import/SelectITwin.js.map +1 -1
  407. package/lib/esm/components/Mappings/Import/SelectITwin.scss +1 -1
  408. package/lib/esm/components/Mappings/Import/SelectMappings.d.ts +1 -1
  409. package/lib/esm/components/Mappings/Import/SelectMappings.js +8 -8
  410. package/lib/esm/components/Mappings/Import/SelectMappings.js.map +1 -1
  411. package/lib/esm/components/Mappings/MappingListItem.js.map +1 -1
  412. package/lib/esm/components/Mappings/MappingViewActionGroup.d.ts +1 -1
  413. package/lib/esm/components/Mappings/MappingViewActionGroup.js +8 -8
  414. package/lib/esm/components/Mappings/MappingViewActionGroup.js.map +1 -1
  415. package/lib/esm/components/Mappings/Mappings.js +3 -3
  416. package/lib/esm/components/Mappings/Mappings.js.map +1 -1
  417. package/lib/esm/components/Mappings/MappingsView.js +15 -17
  418. package/lib/esm/components/Mappings/MappingsView.js.map +1 -1
  419. package/lib/esm/components/Mappings/hooks/useFetchExtractionStatus.js +3 -1
  420. package/lib/esm/components/Mappings/hooks/useFetchExtractionStatus.js.map +1 -1
  421. package/lib/esm/components/Mappings/hooks/useFetchMappingExtractionStatus.d.ts +1 -1
  422. package/lib/esm/components/Mappings/hooks/useFetchMappingExtractionStatus.js +3 -3
  423. package/lib/esm/components/Mappings/hooks/useFetchMappingExtractionStatus.js.map +1 -1
  424. package/lib/esm/components/Mappings/hooks/useFetchMappings.js +1 -1
  425. package/lib/esm/components/Mappings/hooks/useFetchMappings.js.map +1 -1
  426. package/lib/esm/components/Mappings/hooks/useMappingsOperations.js +36 -18
  427. package/lib/esm/components/Mappings/hooks/useMappingsOperations.js.map +1 -1
  428. package/lib/esm/components/Mappings/hooks/useRunExtraction.d.ts +1 -1
  429. package/lib/esm/components/Mappings/hooks/useRunExtraction.js +8 -6
  430. package/lib/esm/components/Mappings/hooks/useRunExtraction.js.map +1 -1
  431. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyAction.d.ts +1 -1
  432. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyAction.js +9 -9
  433. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyAction.js.map +1 -1
  434. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyActionWithVisuals.js +13 -15
  435. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyActionWithVisuals.js.map +1 -1
  436. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyTable.js +2 -2
  437. package/lib/esm/components/Properties/CalculatedProperties/CalculatedPropertyTable.js.map +1 -1
  438. package/lib/esm/components/Properties/CalculatedProperties/SharedCalculatedPropertyForms.js +5 -7
  439. package/lib/esm/components/Properties/CalculatedProperties/SharedCalculatedPropertyForms.js.map +1 -1
  440. package/lib/esm/components/Properties/CustomCalculations/CustomCalculationAction.d.ts +1 -1
  441. package/lib/esm/components/Properties/CustomCalculations/CustomCalculationAction.js +28 -22
  442. package/lib/esm/components/Properties/CustomCalculations/CustomCalculationAction.js.map +1 -1
  443. package/lib/esm/components/Properties/CustomCalculations/CustomCalculationAction.scss +1 -1
  444. package/lib/esm/components/Properties/CustomCalculations/CustomCalculationTable.js +17 -13
  445. package/lib/esm/components/Properties/CustomCalculations/CustomCalculationTable.js.map +1 -1
  446. package/lib/esm/components/Properties/GroupColorToggle.js +4 -4
  447. package/lib/esm/components/Properties/GroupColorToggle.js.map +1 -1
  448. package/lib/esm/components/Properties/GroupInformationPanel.js +3 -3
  449. package/lib/esm/components/Properties/GroupInformationPanel.js.map +1 -1
  450. package/lib/esm/components/Properties/GroupProperties/GroupPropertyAction.d.ts +1 -1
  451. package/lib/esm/components/Properties/GroupProperties/GroupPropertyAction.js +22 -29
  452. package/lib/esm/components/Properties/GroupProperties/GroupPropertyAction.js.map +1 -1
  453. package/lib/esm/components/Properties/GroupProperties/GroupPropertyListItem.d.ts +1 -1
  454. package/lib/esm/components/Properties/GroupProperties/GroupPropertyListItem.js +5 -5
  455. package/lib/esm/components/Properties/GroupProperties/GroupPropertyListItem.js.map +1 -1
  456. package/lib/esm/components/Properties/GroupProperties/GroupPropertyTable.d.ts +1 -1
  457. package/lib/esm/components/Properties/GroupProperties/GroupPropertyTable.js +16 -14
  458. package/lib/esm/components/Properties/GroupProperties/GroupPropertyTable.js.map +1 -1
  459. package/lib/esm/components/Properties/GroupProperties/GroupPropertyUtils.js +21 -40
  460. package/lib/esm/components/Properties/GroupProperties/GroupPropertyUtils.js.map +1 -1
  461. package/lib/esm/components/Properties/GroupProperties/GroupsPropertiesSelectionModal.js +26 -35
  462. package/lib/esm/components/Properties/GroupProperties/GroupsPropertiesSelectionModal.js.map +1 -1
  463. package/lib/esm/components/Properties/GroupProperties/SaveModal.d.ts +1 -1
  464. package/lib/esm/components/Properties/GroupProperties/SaveModal.js +8 -8
  465. package/lib/esm/components/Properties/GroupProperties/SaveModal.js.map +1 -1
  466. package/lib/esm/components/Properties/GroupProperties/SortableHorizontalTile.js +4 -4
  467. package/lib/esm/components/Properties/GroupProperties/SortableHorizontalTile.js.map +1 -1
  468. package/lib/esm/components/Properties/PropertyAction.js +9 -21
  469. package/lib/esm/components/Properties/PropertyAction.js.map +1 -1
  470. package/lib/esm/components/Properties/PropertyMenu.js +4 -4
  471. package/lib/esm/components/Properties/PropertyMenu.js.map +1 -1
  472. package/lib/esm/components/Properties/PropertyMenuWithVisualization.js +5 -5
  473. package/lib/esm/components/Properties/PropertyMenuWithVisualization.js.map +1 -1
  474. package/lib/esm/components/Properties/PropertyNameCell.d.ts +1 -1
  475. package/lib/esm/components/Properties/PropertyNameCell.js +4 -4
  476. package/lib/esm/components/Properties/PropertyNameCell.js.map +1 -1
  477. package/lib/esm/components/Properties/PropertyTable.js +5 -6
  478. package/lib/esm/components/Properties/PropertyTable.js.map +1 -1
  479. package/lib/esm/components/Properties/PropertyTableToolbar.d.ts +1 -1
  480. package/lib/esm/components/Properties/PropertyTableToolbar.js +4 -4
  481. package/lib/esm/components/Properties/PropertyTableToolbar.js.map +1 -1
  482. package/lib/esm/components/Properties/hooks/useFormulaValidation.js +3 -3
  483. package/lib/esm/components/Properties/hooks/useFormulaValidation.js.map +1 -1
  484. package/lib/esm/components/Properties/hooks/usePropertiesQuery.js.map +1 -1
  485. package/lib/esm/components/Properties/hooks/useValidator.js +4 -4
  486. package/lib/esm/components/Properties/hooks/useValidator.js.map +1 -1
  487. package/lib/esm/components/SharedComponents/ActionPanel.d.ts +1 -1
  488. package/lib/esm/components/SharedComponents/ActionPanel.js +9 -10
  489. package/lib/esm/components/SharedComponents/ActionPanel.js.map +1 -1
  490. package/lib/esm/components/SharedComponents/DeleteModal.d.ts +1 -1
  491. package/lib/esm/components/SharedComponents/DeleteModal.js +10 -11
  492. package/lib/esm/components/SharedComponents/DeleteModal.js.map +1 -1
  493. package/lib/esm/components/SharedComponents/EmptyMessage.js +4 -4
  494. package/lib/esm/components/SharedComponents/EmptyMessage.js.map +1 -1
  495. package/lib/esm/components/SharedComponents/LoadingOverlay.js +4 -4
  496. package/lib/esm/components/SharedComponents/LoadingOverlay.js.map +1 -1
  497. package/lib/esm/components/SharedComponents/LoadingSpinner.js +3 -3
  498. package/lib/esm/components/SharedComponents/LoadingSpinner.js.map +1 -1
  499. package/lib/esm/components/SharedComponents/StatusIcon.js +3 -3
  500. package/lib/esm/components/SharedComponents/StatusIcon.js.map +1 -1
  501. package/lib/esm/components/context/ExtractionClientContext.js.map +1 -1
  502. package/lib/esm/components/context/ExtractionStateJobContext.js +3 -3
  503. package/lib/esm/components/context/ExtractionStateJobContext.js.map +1 -1
  504. package/lib/esm/components/context/GroupHilitedElementsContext.js +3 -3
  505. package/lib/esm/components/context/GroupHilitedElementsContext.js.map +1 -1
  506. package/lib/esm/components/context/GroupingApiConfigContext.js.map +1 -1
  507. package/lib/esm/components/context/GroupingMappingCustomUIContext.js +3 -3
  508. package/lib/esm/components/context/GroupingMappingCustomUIContext.js.map +1 -1
  509. package/lib/esm/components/context/GroupsClientContext.js.map +1 -1
  510. package/lib/esm/components/context/IModelsClientContext.js.map +1 -1
  511. package/lib/esm/components/context/ITwinsClientContext.js +3 -3
  512. package/lib/esm/components/context/ITwinsClientContext.js.map +1 -1
  513. package/lib/esm/components/context/MappingClientContext.js.map +1 -1
  514. package/lib/esm/components/context/PropertiesClientContext.js.map +1 -1
  515. package/lib/esm/components/context/PropertiesGroupColorContext.js +3 -3
  516. package/lib/esm/components/context/PropertiesGroupColorContext.js.map +1 -1
  517. package/lib/esm/components/context/PropertyGridWrapperContext.js +3 -3
  518. package/lib/esm/components/context/PropertyGridWrapperContext.js.map +1 -1
  519. package/lib/esm/components/customUI/DefaultGroupingUI.js +3 -3
  520. package/lib/esm/components/customUI/DefaultGroupingUI.js.map +1 -1
  521. package/lib/esm/components/customUI/GroupQueryBuilderCustomUI.d.ts +1 -1
  522. package/lib/esm/components/customUI/GroupQueryBuilderCustomUI.js +14 -19
  523. package/lib/esm/components/customUI/GroupQueryBuilderCustomUI.js.map +1 -1
  524. package/lib/esm/components/customUI/GroupingMappingCustomUI.js.map +1 -1
  525. package/lib/esm/components/customUI/ManualGroupingCustomUI.d.ts +1 -1
  526. package/lib/esm/components/customUI/ManualGroupingCustomUI.js +8 -8
  527. package/lib/esm/components/customUI/ManualGroupingCustomUI.js.map +1 -1
  528. package/lib/esm/components/customUI/SearchGroupingCustomUI.d.ts +1 -1
  529. package/lib/esm/components/customUI/SearchGroupingCustomUI.js +16 -45
  530. package/lib/esm/components/customUI/SearchGroupingCustomUI.js.map +1 -1
  531. package/lib/esm/decorators/BboxDimensionsDecorator.js +5 -12
  532. package/lib/esm/decorators/BboxDimensionsDecorator.js.map +1 -1
  533. package/lib/esm/formula/FormulaDataTypeResolver.js +3 -3
  534. package/lib/esm/formula/FormulaDataTypeResolver.js.map +1 -1
  535. package/lib/esm/formula/FormulaFunctionProvider.js +146 -65
  536. package/lib/esm/formula/FormulaFunctionProvider.js.map +1 -1
  537. package/lib/esm/formula/FormulaOperatorsProvider.js +138 -44
  538. package/lib/esm/formula/FormulaOperatorsProvider.js.map +1 -1
  539. package/lib/esm/formula/FormulaSplitter.js +63 -13
  540. package/lib/esm/formula/FormulaSplitter.js.map +1 -1
  541. package/lib/esm/formula/FormulaTokensDataTypeResolver.js +7 -14
  542. package/lib/esm/formula/FormulaTokensDataTypeResolver.js.map +1 -1
  543. package/lib/esm/formula/IResult.js.map +1 -1
  544. package/lib/esm/formula/InfixToPostfixConverter.js +5 -5
  545. package/lib/esm/formula/InfixToPostfixConverter.js.map +1 -1
  546. package/lib/esm/formula/InputStream.js +3 -3
  547. package/lib/esm/formula/InputStream.js.map +1 -1
  548. package/lib/esm/formula/ParenthesisValidator.js +3 -3
  549. package/lib/esm/formula/ParenthesisValidator.js.map +1 -1
  550. package/lib/esm/formula/Queue.js +3 -3
  551. package/lib/esm/formula/Queue.js.map +1 -1
  552. package/lib/esm/formula/Stack.js +3 -3
  553. package/lib/esm/formula/Stack.js.map +1 -1
  554. package/lib/esm/formula/StringBuilder.js +3 -3
  555. package/lib/esm/formula/StringBuilder.js.map +1 -1
  556. package/lib/esm/formula/Types.js.map +1 -1
  557. package/lib/esm/formula/Utils.js +4 -4
  558. package/lib/esm/formula/Utils.js.map +1 -1
  559. package/lib/esm/grouping-mapping-widget.d.ts +4 -4
  560. package/lib/esm/grouping-mapping-widget.js +7 -7
  561. package/lib/esm/grouping-mapping-widget.js.map +1 -1
  562. package/lib/esm/test/GroupPropertyUtils.test.js +28 -27
  563. package/lib/esm/test/GroupPropertyUtils.test.js.map +1 -1
  564. package/lib/esm/test/GroupingMappingCustomUI.test.js +4 -6
  565. package/lib/esm/test/GroupingMappingCustomUI.test.js.map +1 -1
  566. package/lib/esm/test/MockFactory.js +3 -3
  567. package/lib/esm/test/MockFactory.js.map +1 -1
  568. package/lib/esm/test/PropertyFieldsHelpers.js +3 -3
  569. package/lib/esm/test/PropertyFieldsHelpers.js.map +1 -1
  570. package/lib/esm/test/QueryBuilder.test.js +3 -3
  571. package/lib/esm/test/QueryBuilder.test.js.map +1 -1
  572. package/lib/esm/test/QueryBuilder.testdata.js +3 -3
  573. package/lib/esm/test/QueryBuilder.testdata.js.map +1 -1
  574. package/lib/esm/test/QueryBuilderTestData.js.map +1 -1
  575. package/lib/esm/test/WidgetHeader.test.js +3 -3
  576. package/lib/esm/test/WidgetHeader.test.js.map +1 -1
  577. package/lib/esm/test/test-utils.js +4 -4
  578. package/lib/esm/test/test-utils.js.map +1 -1
  579. package/package.json +8 -4
@@ -1,7 +1,7 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import React, { useCallback, useEffect, useState } from "react";
6
6
  import { PropertyValueFormat } from "@itwin/appui-abstract";
7
7
  import { usePropertyGridWrapper } from "../context/PropertyGridWrapperContext";
@@ -14,16 +14,13 @@ const usePropertySelection = (property, currentPropertyList, queryBuilder) => {
14
14
  return currentPropertyList.includes(property);
15
15
  }
16
16
  if (property.value.valueFormat === PropertyValueFormat.Array) {
17
- return (property.value.items.length === 0 &&
18
- currentPropertyList.includes(property));
17
+ return property.value.items.length === 0 && currentPropertyList.includes(property);
19
18
  }
20
19
  return Object.values(property.value.members).every((subProp) => checkIfPropertyIsSelected(subProp));
21
20
  }, [currentPropertyList]);
22
21
  const isPropertySelected = checkIfPropertyIsSelected(property);
23
22
  const addProperty = useCallback(async (prop) => {
24
- if (prop.value.valueFormat === PropertyValueFormat.Primitive &&
25
- !currentPropertyList.includes(prop) &&
26
- (await queryBuilder?.addProperty(prop))) {
23
+ if (prop.value.valueFormat === PropertyValueFormat.Primitive && !currentPropertyList.includes(prop) && (await queryBuilder?.addProperty(prop))) {
27
24
  setIsCheckboxLoading(false);
28
25
  return true;
29
26
  }
@@ -44,8 +41,8 @@ const usePropertySelection = (property, currentPropertyList, queryBuilder) => {
44
41
  };
45
42
  };
46
43
  export const PropertyAction = ({ property }) => {
47
- const { currentPropertyList, queryBuilder, setCurrentPropertyList, setQuery, isUpdating, } = usePropertyGridWrapper();
48
- const { isPropertySelected, addProperty, removeProperty, isCheckboxLoading, setIsCheckboxLoading, } = usePropertySelection(property, currentPropertyList, queryBuilder);
44
+ const { currentPropertyList, queryBuilder, setCurrentPropertyList, setQuery, isUpdating } = usePropertyGridWrapper();
45
+ const { isPropertySelected, addProperty, removeProperty, isCheckboxLoading, setIsCheckboxLoading } = usePropertySelection(property, currentPropertyList, queryBuilder);
49
46
  useEffect(() => {
50
47
  setIsCheckboxLoading(isPropertySelected && isUpdating);
51
48
  }, [isPropertySelected, isUpdating, setIsCheckboxLoading]);
@@ -61,16 +58,7 @@ export const PropertyAction = ({ property }) => {
61
58
  setQuery(queryBuilder?.buildQueryString() ?? "");
62
59
  }
63
60
  }
64
- }, [
65
- addProperty,
66
- isPropertySelected,
67
- property,
68
- removeProperty,
69
- queryBuilder,
70
- setCurrentPropertyList,
71
- setQuery,
72
- ]);
73
- return (React.createElement("div", { className: "gmw-property-selection-checkbox" }, property.value.valueFormat === PropertyValueFormat.Primitive &&
74
- property.value.value !== undefined && (React.createElement(Checkbox, { checked: isPropertySelected, onChange: onPropertySelectionChanged, disabled: isUpdating, isLoading: isCheckboxLoading }))));
61
+ }, [addProperty, isPropertySelected, property, removeProperty, queryBuilder, setCurrentPropertyList, setQuery]);
62
+ return (React.createElement("div", { className: "gmw-property-selection-checkbox" }, property.value.valueFormat === PropertyValueFormat.Primitive && property.value.value !== undefined && (React.createElement(Checkbox, { checked: isPropertySelected, onChange: onPropertySelectionChanged, disabled: isUpdating, isLoading: isCheckboxLoading }))));
75
63
  };
76
64
  //# sourceMappingURL=PropertyAction.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyAction.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyAction.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEhE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,uCAAuC,CAAC;AAC/E,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,uBAAuB,CAAC;AAO/B,MAAM,oBAAoB,GAAG,CAC3B,QAAwB,EACxB,mBAAqC,EACrC,YAAsC,EACtC,EAAE;IACF,MAAM,CAAC,iBAAiB,EAAE,oBAAoB,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAElE,MAAM,yBAAyB,GAAG,WAAW,CAC3C,CAAC,QAAwB,EAAW,EAAE;QACpC,IAAI,QAAQ,CAAC,KAAK,CAAC,WAAW,KAAK,mBAAmB,CAAC,SAAS,EAAE;YAChE,OAAO,mBAAmB,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;SAC/C;QAED,IAAI,QAAQ,CAAC,KAAK,CAAC,WAAW,KAAK,mBAAmB,CAAC,KAAK,EAAE;YAC5D,OAAO,CACL,QAAQ,CAAC,KAAK,CAAC,KAAK,CAAC,MAAM,KAAK,CAAC;gBACjC,mBAAmB,CAAC,QAAQ,CAAC,QAAQ,CAAC,CACvC,CAAC;SACH;QACD,OAAO,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,KAAK,CAChD,CAAC,OAAuB,EAAE,EAAE,CAAC,yBAAyB,CAAC,OAAO,CAAC,CAChE,CAAC;IACJ,CAAC,EACD,CAAC,mBAAmB,CAAC,CACtB,CAAC;IAEF,MAAM,kBAAkB,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AAI,UAAU,CAAC,CAAC;IACzD,CAAC,EAAE,CAAC,kBAAkB,EAAE,UAAU,EAAE,oBAAoB,CAAC,CAAC,CAAC;IAE3D,MAAM,0BAA0B,GAAG,WAAW,CAAC,KAAK,IAAI,EAAE;QACxD,IAAI,kBAAkB,EAAE;YACtB,MAAM,cAAc,CAAC,QAAQ,CAAC,CAAC;YAC/B,sBAAsB,CAAC,CAAC,QAAQ,EAAE,EAAE,CAClC,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,QAAQ,CAAC,CACvC,CAAC;YACF,QAAQ,CAAC,YAAY,EAAE,gBAAgB,EAAE,IAAI,EAAE,CAAC,CAAC;SAClD;aAAM;YACL,IAAI,MAAM,WAAW,CAAC,QAAQ,CAAC,EAAE;gBAC/B,sBAAsB,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC;gBAChE,QAAQ,CAAC,YAAY,EAAE,gBAAgB,EAAE,IAAI,EAAE,CAAC,CAAC;aAClD;SACF;IACH,CAAC,EAAE;QACD,WAAW;QACX,kBAAkB;QAClB,QAAQ;QACR,cAAc;QACd,YAAY;QACZ,sBAAsB;QACtB,QAAQ;KACT,CAAC,CAAC;IAEH,OAAO,CACL,6BAAK,SAAS,EAAC,iCAAiC,IAC7C,QAAQ,CAAC,KAAK,CAAC,WAAW,KAAK,mBAAmB,CAAC,SAAS;QAC3D,QAAQ,CAAC,KAAK,CAAC,KAAK,KAAK,SAAS,IAAI,CACtC,oBAAC,QAAQ,IACP,OAAO,EAAE,kBAAkB,EAC3B,QAAQ,EAAE,0BAA0B,EACpC,QAAQ,EAAE,UAAU,EACpB,SAAS,EAAE,iBAAiB,GAC5B,CACH,CACG,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport React, { useCallback, useEffect, useState } from \"react\";\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\nimport { usePropertyGridWrapper } from \"../context/PropertyGridWrapperContext\";\nimport { Checkbox } from \"@itwin/itwinui-react\";\nimport \"./PropertyAction.scss\";\nimport type { QueryBuilder } from \"../Groups/QueryBuilder/QueryBuilder\";\n\nexport interface PropertyActionProps {\n property: PropertyRecord;\n}\n\nconst usePropertySelection = (\n property: PropertyRecord,\n currentPropertyList: PropertyRecord[],\n queryBuilder: QueryBuilder | undefined\n) => {\n const [isCheckboxLoading, setIsCheckboxLoading] = useState(false);\n\n const checkIfPropertyIsSelected = useCallback(\n (property: PropertyRecord): boolean => {\n if (property.value.valueFormat === PropertyValueFormat.Primitive) {\n return currentPropertyList.includes(property);\n }\n\n if (property.value.valueFormat === PropertyValueFormat.Array) {\n return (\n property.value.items.length === 0 &&\n currentPropertyList.includes(property)\n );\n }\n return Object.values(property.value.members).every(\n (subProp: PropertyRecord) => checkIfPropertyIsSelected(subProp)\n );\n },\n [currentPropertyList]\n );\n\n const isPropertySelected = checkIfPropertyIsSelected(property);\n\n const addProperty = useCallback(\n async (prop: PropertyRecord) => {\n if (\n prop.value.valueFormat === PropertyValueFormat.Primitive &&\n !currentPropertyList.includes(prop) &&\n (await queryBuilder?.addProperty(prop))\n ) {\n setIsCheckboxLoading(false);\n return true;\n }\n return false;\n },\n [currentPropertyList, queryBuilder]\n );\n\n const removeProperty = useCallback(\n async (prop: PropertyRecord) => {\n if (currentPropertyList.includes(prop)) {\n await queryBuilder?.removeProperty(prop);\n setIsCheckboxLoading(false);\n }\n },\n [currentPropertyList, queryBuilder]\n );\n\n return {\n isPropertySelected,\n addProperty,\n removeProperty,\n isCheckboxLoading,\n setIsCheckboxLoading,\n };\n};\n\nexport const PropertyAction = ({ property }: PropertyActionProps) => {\n const {\n currentPropertyList,\n queryBuilder,\n setCurrentPropertyList,\n setQuery,\n isUpdating,\n } = usePropertyGridWrapper();\n\n const {\n isPropertySelected,\n addProperty,\n removeProperty,\n isCheckboxLoading,\n setIsCheckboxLoading,\n } = usePropertySelection(property, currentPropertyList, queryBuilder);\n\n useEffect(() => {\n setIsCheckboxLoading(isPropertySelected && isUpdating);\n }, [isPropertySelected, isUpdating, setIsCheckboxLoading]);\n\n const onPropertySelectionChanged = useCallback(async () => {\n if (isPropertySelected) {\n await removeProperty(property);\n setCurrentPropertyList((prevList) =>\n prevList.filter((x) => x !== property)\n );\n setQuery(queryBuilder?.buildQueryString() ?? \"\");\n } else {\n if (await addProperty(property)) {\n setCurrentPropertyList((prevList) => prevList.concat(property));\n setQuery(queryBuilder?.buildQueryString() ?? \"\");\n }\n }\n }, [\n addProperty,\n isPropertySelected,\n property,\n removeProperty,\n queryBuilder,\n setCurrentPropertyList,\n setQuery,\n ]);\n\n return (\n <div className=\"gmw-property-selection-checkbox\">\n {property.value.valueFormat === PropertyValueFormat.Primitive &&\n property.value.value !== undefined && (\n <Checkbox\n checked={isPropertySelected}\n onChange={onPropertySelectionChanged}\n disabled={isUpdating}\n isLoading={isCheckboxLoading}\n />\n )}\n </div>\n );\n};\n"]}
1
+ {"version":3,"file":"PropertyAction.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyAction.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAEhE,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,MAAM,uCAAuC,CAAC;AAC/E,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,uBAAuB,CAAC;AAO/B,MAAM,oBAAoB,GAAG,CAAC,QAAwB,EAAE,mBAAqC,EAAE,YAAsC,EAAE,EAAE;IACvI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B,sBAAsB,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC;gBAChE,QAAQ,CAAC,YAAY,EAAE,gBAAgB,EAAE,IAAI,EAAE,CAAC,CAAC;aAClD;SACF;IACH,CAAC,EAAE,CAAC,WAAW,EAAE,kBAAkB,EAAE,QAAQ,EAAE,cAAc,EAAE,YAAY,EAAE,sBAAsB,EAAE,QAAQ,CAAC,CAAC,CAAC;IAEhH,OAAO,CACL,6BAAK,SAAS,EAAC,iCAAiC,IAC7C,QAAQ,CAAC,KAAK,CAAC,WAAW,KAAK,mBAAmB,CAAC,SAAS,IAAI,QAAQ,CAAC,KAAK,CAAC,KAAK,KAAK,SAAS,IAAI,CACrG,oBAAC,QAAQ,IAAC,OAAO,EAAE,kBAAkB,EAAE,QAAQ,EAAE,0BAA0B,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,iBAAiB,GAAI,CACpI,CACG,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport React, { useCallback, useEffect, useState } from \"react\";\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\nimport { usePropertyGridWrapper } from \"../context/PropertyGridWrapperContext\";\nimport { Checkbox } from \"@itwin/itwinui-react\";\nimport \"./PropertyAction.scss\";\nimport type { QueryBuilder } from \"../Groups/QueryBuilder/QueryBuilder\";\n\nexport interface PropertyActionProps {\n property: PropertyRecord;\n}\n\nconst usePropertySelection = (property: PropertyRecord, currentPropertyList: PropertyRecord[], queryBuilder: QueryBuilder | undefined) => {\n const [isCheckboxLoading, setIsCheckboxLoading] = useState(false);\n\n const checkIfPropertyIsSelected = useCallback(\n (property: PropertyRecord): boolean => {\n if (property.value.valueFormat === PropertyValueFormat.Primitive) {\n return currentPropertyList.includes(property);\n }\n\n if (property.value.valueFormat === PropertyValueFormat.Array) {\n return property.value.items.length === 0 && currentPropertyList.includes(property);\n }\n return Object.values(property.value.members).every((subProp: PropertyRecord) => checkIfPropertyIsSelected(subProp));\n },\n [currentPropertyList],\n );\n\n const isPropertySelected = checkIfPropertyIsSelected(property);\n\n const addProperty = useCallback(\n async (prop: PropertyRecord) => {\n if (prop.value.valueFormat === PropertyValueFormat.Primitive && !currentPropertyList.includes(prop) && (await queryBuilder?.addProperty(prop))) {\n setIsCheckboxLoading(false);\n return true;\n }\n return false;\n },\n [currentPropertyList, queryBuilder],\n );\n\n const removeProperty = useCallback(\n async (prop: PropertyRecord) => {\n if (currentPropertyList.includes(prop)) {\n await queryBuilder?.removeProperty(prop);\n setIsCheckboxLoading(false);\n }\n },\n [currentPropertyList, queryBuilder],\n );\n\n return {\n isPropertySelected,\n addProperty,\n removeProperty,\n isCheckboxLoading,\n setIsCheckboxLoading,\n };\n};\n\nexport const PropertyAction = ({ property }: PropertyActionProps) => {\n const { currentPropertyList, queryBuilder, setCurrentPropertyList, setQuery, isUpdating } = usePropertyGridWrapper();\n\n const { isPropertySelected, addProperty, removeProperty, isCheckboxLoading, setIsCheckboxLoading } = usePropertySelection(\n property,\n currentPropertyList,\n queryBuilder,\n );\n\n useEffect(() => {\n setIsCheckboxLoading(isPropertySelected && isUpdating);\n }, [isPropertySelected, isUpdating, setIsCheckboxLoading]);\n\n const onPropertySelectionChanged = useCallback(async () => {\n if (isPropertySelected) {\n await removeProperty(property);\n setCurrentPropertyList((prevList) => prevList.filter((x) => x !== property));\n setQuery(queryBuilder?.buildQueryString() ?? \"\");\n } else {\n if (await addProperty(property)) {\n setCurrentPropertyList((prevList) => prevList.concat(property));\n setQuery(queryBuilder?.buildQueryString() ?? \"\");\n }\n }\n }, [addProperty, isPropertySelected, property, removeProperty, queryBuilder, setCurrentPropertyList, setQuery]);\n\n return (\n <div className=\"gmw-property-selection-checkbox\">\n {property.value.valueFormat === PropertyValueFormat.Primitive && property.value.value !== undefined && (\n <Checkbox checked={isPropertySelected} onChange={onPropertySelectionChanged} disabled={isUpdating} isLoading={isCheckboxLoading} />\n )}\n </div>\n );\n};\n"]}
@@ -1,7 +1,7 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import React, { useCallback } from "react";
6
6
  import "./PropertyMenu.scss";
7
7
  import { GroupPropertyTable } from "./GroupProperties/GroupPropertyTable";
@@ -23,7 +23,7 @@ export const PropertyMenu = ({ mapping, group, onClickAddGroupProperty, onClickM
23
23
  const queryClient = useQueryClient();
24
24
  const { data: groupProperties, isFetching: isLoadingGroupProperties } = usePropertiesQuery(iModelId, mappingId, groupId, getAccessToken, propertiesClient);
25
25
  const refreshGroupProperties = useCallback(async () => queryClient.invalidateQueries({ queryKey: ["properties", iModelId, mappingId, group.id] }), [group.id, iModelId, mappingId, queryClient]);
26
- return (React.createElement("div", { className: 'gmw-property-menu-wrapper' },
26
+ return (React.createElement("div", { className: "gmw-property-menu-wrapper" },
27
27
  !hideGroupProps && (React.createElement(GroupPropertyTable, { iModelId: iModelId, mappingId: mappingId, groupId: groupId, onClickAdd: onClickAddGroupProperty, onClickModify: onClickModifyGroupProperty, isLoading: isLoadingGroupProperties, groupProperties: groupProperties ? groupProperties.properties : [], refresh: refreshGroupProperties })),
28
28
  !hideCalculatedProps && (React.createElement(CalculatedPropertyTable, { mappingId: mappingId, groupId: groupId, onClickAdd: onClickAddCalculatedProperty, onClickModify: onClickModifyCalculatedProperty, isLoading: isLoadingGroupProperties, calculatedProperties: groupProperties ? groupProperties.properties : [], refresh: refreshGroupProperties })),
29
29
  !hideCustomCalculationProps && (React.createElement(CustomCalculationTable, { mappingId: mappingId, groupId: groupId, onClickAdd: onClickAddCustomCalculationProperty, onClickModify: onClickModifyCustomCalculation, isLoading: isLoadingGroupProperties, customCalculations: groupProperties ? groupProperties.properties : [], refresh: refreshGroupProperties }))));
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyMenu.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyMenu.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,qBAAqB,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,2BAA2B,EAAE,MAAM,qCAAqC,CAAC;AAElF,OAAO,EAAE,uBAAuB,EAAE,MAAM,gDAAgD,CAAC;AACzF,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,mBAAmB,EAAE,MAAM,oCAAoC,CAAC;AAoBzE;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAC3B,OAAO,EACP,KAAK,EACL,uBAAuB,EACvB,0BAA0B,EAC1B,4BAA4B,EAC5B,+BAA+B,EAC/B,mCAAmC,EACnC,8BAA8B,EAC9B,cAAc,GAAG,KAAK,EACtB,mBAAmB,GAAG,KAAK,EAC3B,0BAA0B,GAAG,KAAK,GAChB,EAAE,EAAE;IACtB,MAAM,OAAO,GAAG,KAAK,CAAC,EAAE,CAAC;IACzB,MAAM,SAAS,GAAG,OAAO,CAAC,EAAE,CAAC;IAC7B,MAAM,EAAE,cAAc,EAAE,QAAQ,EAAE,GAAG,2BAA2B,EAAE,CAAC;IACnE,MAAM,gBAAgB,G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AAE,SAAS,EACpB,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,mCAAmC,EAC/C,aAAa,EAAE,8BAA8B,EAC7C,SAAS,EAAE,wBAAwB,EACnC,kBAAkB,EAAE,eAAe,CAAC,CAAC,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,EACrE,OAAO,EAAE,sBAAsB,GAC/B,CACH,CACG,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport React, { useCallback } from \"react\";\nimport \"./PropertyMenu.scss\";\nimport { GroupPropertyTable } from \"./GroupProperties/GroupPropertyTable\";\nimport { useGroupingMappingApiConfig } from \"../context/GroupingApiConfigContext\";\nimport type { GroupMinimal, Mapping, Property } from \"@itwin/insights-client\";\nimport { CalculatedPropertyTable } from \"./CalculatedProperties/CalculatedPropertyTable\";\nimport { CustomCalculationTable } from \"./CustomCalculations/CustomCalculationTable\";\nimport { usePropertiesQuery } from \"./hooks/usePropertiesQuery\";\nimport { useQueryClient } from \"@tanstack/react-query\";\nimport { usePropertiesClient } from \"../context/PropertiesClientContext\";\n\n/**\n * Props for the {@link PropertyMenu} component.\n * @public\n */\nexport interface PropertyMenuProps {\n mapping: Mapping;\n group: GroupMinimal;\n onClickAddGroupProperty?: () => void;\n onClickModifyGroupProperty?: (groupProperty: Property) => void;\n onClickAddCalculatedProperty?: () => void;\n onClickModifyCalculatedProperty?: (calculatedProperty: Property) => void;\n onClickAddCustomCalculationProperty?: () => void;\n onClickModifyCustomCalculation?: (customCalculation: Property) => void;\n hideGroupProps?: boolean;\n hideCalculatedProps?: boolean;\n hideCustomCalculationProps?: boolean;\n}\n\n/**\n * Component to display the properties of a group.\n * @public\n */\nexport const PropertyMenu = ({\n mapping,\n group,\n onClickAddGroupProperty,\n onClickModifyGroupProperty,\n onClickAddCalculatedProperty,\n onClickModifyCalculatedProperty,\n onClickAddCustomCalculationProperty,\n onClickModifyCustomCalculation,\n hideGroupProps = false,\n hideCalculatedProps = false,\n hideCustomCalculationProps = false,\n}: PropertyMenuProps) => {\n const groupId = group.id;\n const mappingId = mapping.id;\n const { getAccessToken, iModelId } = useGroupingMappingApiConfig();\n const propertiesClient = usePropertiesClient();\n const queryClient = useQueryClient();\n\n const { data: groupProperties, isFetching: isLoadingGroupProperties } = usePropertiesQuery(iModelId, mappingId, groupId, getAccessToken, propertiesClient);\n\n const refreshGroupProperties = useCallback(async () => queryClient.invalidateQueries({ queryKey: [\"properties\", iModelId, mappingId, group.id] }), [group.id, iModelId, mappingId, queryClient]);\n\n return (\n <div className='gmw-property-menu-wrapper'>\n {!hideGroupProps && (\n <GroupPropertyTable\n iModelId={iModelId}\n mappingId={mappingId}\n groupId={groupId}\n onClickAdd={onClickAddGroupProperty}\n onClickModify={onClickModifyGroupProperty}\n isLoading={isLoadingGroupProperties}\n groupProperties={groupProperties ? groupProperties.properties : []}\n refresh={refreshGroupProperties}\n />\n )}\n {!hideCalculatedProps && (\n <CalculatedPropertyTable\n mappingId={mappingId}\n groupId={groupId}\n onClickAdd={onClickAddCalculatedProperty}\n onClickModify={onClickModifyCalculatedProperty}\n isLoading={isLoadingGroupProperties}\n calculatedProperties={groupProperties ? groupProperties.properties : []}\n refresh={refreshGroupProperties}\n />\n )}\n {!hideCustomCalculationProps && (\n <CustomCalculationTable\n mappingId={mappingId}\n groupId={groupId}\n onClickAdd={onClickAddCustomCalculationProperty}\n onClickModify={onClickModifyCustomCalculation}\n isLoading={isLoadingGroupProperties}\n customCalculations={groupProperties ? groupProperties.properties : []}\n refresh={refreshGroupProperties}\n />\n )}\n </div>\n );\n};\n"]}
1
+ {"version":3,"file":"PropertyMenu.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyMenu.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,KAAK,EAAE,EAAE,W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,EAAE,QAAQ,EAAE,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,EAAE,CAAC,EACtG,CAAC,KAAK,CAAC,EAAE,EAAE,QAAQ,EAAE,SAAS,EAAE,WAAW,CAAC,CAC7C,CAAC;IAEF,OAAO,CACL,6BAAK,SAAS,EAAC,2BAA2B;QACvC,CAAC,cAAc,IAAI,CAClB,oBAAC,kBAAkB,IACjB,QAAQ,EAAE,QAAQ,EAClB,SAAS,EAAE,SAAS,EACpB,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,uBAAuB,EACnC,aAAa,EAAE,0BAA0B,EACzC,SAAS,EAAE,wBAAwB,EACnC,eAAe,EAAE,eAAe,CAAC,CAAC,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,EAClE,OAAO,EAAE,sBAAsB,GAC/B,CACH;QACA,CAAC,mBAAmB,IAAI,CACvB,oBAAC,uBAAuB,IACtB,SAAS,EAAE,SAAS,EACpB,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,4BAA4B,EACxC,aAAa,EAAE,+BAA+B,EAC9C,SAAS,EAAE,wBAAwB,EACnC,oBAAoB,EAAE,eAAe,CAAC,CAAC,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,EACvE,OAAO,EAAE,sBAAsB,GAC/B,CACH;QACA,CAAC,0BAA0B,IAAI,CAC9B,oBAAC,sBAAsB,IACrB,SAAS,EAAE,SAAS,EACpB,OAAO,EAAE,OAAO,EAChB,UAAU,EAAE,mCAAmC,EAC/C,aAAa,EAAE,8BAA8B,EAC7C,SAAS,EAAE,wBAAwB,EACnC,kBAAkB,EAAE,eAAe,CAAC,CAAC,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,EACrE,OAAO,EAAE,sBAAsB,GAC/B,CACH,CACG,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport React, { useCallback } from \"react\";\nimport \"./PropertyMenu.scss\";\nimport { GroupPropertyTable } from \"./GroupProperties/GroupPropertyTable\";\nimport { useGroupingMappingApiConfig } from \"../context/GroupingApiConfigContext\";\nimport type { GroupMinimal, Mapping, Property } from \"@itwin/insights-client\";\nimport { CalculatedPropertyTable } from \"./CalculatedProperties/CalculatedPropertyTable\";\nimport { CustomCalculationTable } from \"./CustomCalculations/CustomCalculationTable\";\nimport { usePropertiesQuery } from \"./hooks/usePropertiesQuery\";\nimport { useQueryClient } from \"@tanstack/react-query\";\nimport { usePropertiesClient } from \"../context/PropertiesClientContext\";\n\n/**\n * Props for the {@link PropertyMenu} component.\n * @public\n */\nexport interface PropertyMenuProps {\n mapping: Mapping;\n group: GroupMinimal;\n onClickAddGroupProperty?: () => void;\n onClickModifyGroupProperty?: (groupProperty: Property) => void;\n onClickAddCalculatedProperty?: () => void;\n onClickModifyCalculatedProperty?: (calculatedProperty: Property) => void;\n onClickAddCustomCalculationProperty?: () => void;\n onClickModifyCustomCalculation?: (customCalculation: Property) => void;\n hideGroupProps?: boolean;\n hideCalculatedProps?: boolean;\n hideCustomCalculationProps?: boolean;\n}\n\n/**\n * Component to display the properties of a group.\n * @public\n */\nexport const PropertyMenu = ({\n mapping,\n group,\n onClickAddGroupProperty,\n onClickModifyGroupProperty,\n onClickAddCalculatedProperty,\n onClickModifyCalculatedProperty,\n onClickAddCustomCalculationProperty,\n onClickModifyCustomCalculation,\n hideGroupProps = false,\n hideCalculatedProps = false,\n hideCustomCalculationProps = false,\n}: PropertyMenuProps) => {\n const groupId = group.id;\n const mappingId = mapping.id;\n const { getAccessToken, iModelId } = useGroupingMappingApiConfig();\n const propertiesClient = usePropertiesClient();\n const queryClient = useQueryClient();\n\n const { data: groupProperties, isFetching: isLoadingGroupProperties } = usePropertiesQuery(iModelId, mappingId, groupId, getAccessToken, propertiesClient);\n\n const refreshGroupProperties = useCallback(\n async () => queryClient.invalidateQueries({ queryKey: [\"properties\", iModelId, mappingId, group.id] }),\n [group.id, iModelId, mappingId, queryClient],\n );\n\n return (\n <div className=\"gmw-property-menu-wrapper\">\n {!hideGroupProps && (\n <GroupPropertyTable\n iModelId={iModelId}\n mappingId={mappingId}\n groupId={groupId}\n onClickAdd={onClickAddGroupProperty}\n onClickModify={onClickModifyGroupProperty}\n isLoading={isLoadingGroupProperties}\n groupProperties={groupProperties ? groupProperties.properties : []}\n refresh={refreshGroupProperties}\n />\n )}\n {!hideCalculatedProps && (\n <CalculatedPropertyTable\n mappingId={mappingId}\n groupId={groupId}\n onClickAdd={onClickAddCalculatedProperty}\n onClickModify={onClickModifyCalculatedProperty}\n isLoading={isLoadingGroupProperties}\n calculatedProperties={groupProperties ? groupProperties.properties : []}\n refresh={refreshGroupProperties}\n />\n )}\n {!hideCustomCalculationProps && (\n <CustomCalculationTable\n mappingId={mappingId}\n groupId={groupId}\n onClickAdd={onClickAddCustomCalculationProperty}\n onClickModify={onClickModifyCustomCalculation}\n isLoading={isLoadingGroupProperties}\n customCalculations={groupProperties ? groupProperties.properties : []}\n refresh={refreshGroupProperties}\n />\n )}\n </div>\n );\n};\n"]}
@@ -1,7 +1,7 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import React, { useState } from "react";
6
6
  import { PropertyMenu } from "./PropertyMenu";
7
7
  import { GroupColorToggle } from "./GroupColorToggle";
@@ -15,10 +15,10 @@ import "./PropertyMenuWithVisualization.scss";
15
15
  */
16
16
  export const PropertyMenuWithVisualization = ({ group, color, ...rest }) => {
17
17
  const [isInformationPanelOpen, setIsInformationPanelOpen] = useState(false);
18
- return (React.createElement(InformationPanelWrapper, { className: 'gmw-property-menu-vis-wrapper' },
18
+ return (React.createElement(InformationPanelWrapper, { className: "gmw-property-menu-vis-wrapper" },
19
19
  React.createElement("div", { className: "gmw-property-menu-vis-toolbar" },
20
20
  React.createElement(GroupColorToggle, { group: group, color: color, labelPosition: "left" }),
21
- React.createElement(IconButton, { styleType: 'borderless', onClick: () => setIsInformationPanelOpen(true), title: 'Group Information' },
21
+ React.createElement(IconButton, { styleType: "borderless", onClick: () => setIsInformationPanelOpen(true), title: "Group Information" },
22
22
  React.createElement(SvgProperties, null))),
23
23
  React.createElement(PropertyMenu, { group: group, ...rest }),
24
24
  React.createElement(GroupInformationPanel, { isOpen: isInformationPanelOpen, onClose: () => setIsInformationPanelOpen(false), query: group.query, groupName: group.groupName })));
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyMenuWithVisualization.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyMenuWithVisualization.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC3E,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,sCAAsC,CAAC;AAU9C;;;GAGG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,EAC5C,KAAK,EACL,KAAK,EACL,GAAG,IAAI,EAC4B,EAAE,EAAE;IACvC,MAAM,CAAC,sBAAsB,EAAE,yBAAyB,CAAC,GAAG,QAAQ,CAAU,KAAK,CAAC,CAAC;IAErF,OAAO,CACL,oBAAC,uBAAuB,IAAC,SAAS,EAAC,+BAA+B;QAChE,6BAAK,SAAS,EAAC,+BAA+B;YAC5C,oBAAC,gBAAgB,IAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,aAAa,EAAC,MAAM,GAAG;YACrE,oBAAC,UAAU,IACT,SAAS,EAAC,YAAY,EACtB,OAAO,EAAE,GAAG,EAAE,CAAC,yBAAyB,CAAC,IAAI,CAAC,EAC9C,KAAK,EAAC,mBAAmB;gBAEzB,oBAAC,aAAa,OAAG,CACN,CACT;QACN,oBAAC,YAAY,IAAC,KAAK,EAAE,KAAK,KAAM,IAAI,GAAI;QACxC,oBAAC,qBAAqB,IACpB,MAAM,EAAE,sBAAsB,EAC9B,OAAO,EAAE,GAAG,EAAE,CAAC,yBAAyB,CAAC,KAAK,CAAC,EAC/C,KAAK,EAAE,KAAK,CAAC,KAAK,EAClB,SAAS,EAAE,KAAK,CAAC,SAAS,GAC1B,CACsB,CAC3B,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport React, { useState } from \"react\";\nimport type { PropertyMenuProps } from \"./PropertyMenu\";\nimport { PropertyMenu } from \"./PropertyMenu\";\nimport { GroupColorToggle } from \"./GroupColorToggle\";\nimport { IconButton, InformationPanelWrapper } from \"@itwin/itwinui-react\";\nimport { GroupInformationPanel } from \"./GroupInformationPanel\";\nimport { SvgProperties } from \"@itwin/itwinui-icons-react\";\nimport \"./PropertyMenuWithVisualization.scss\";\n\n/**\n * Properties for the {@link PropertyMenuWithVisualization} component.\n * @public\n */\nexport interface PropertyMenuWithVisualizationProps extends PropertyMenuProps {\n color: string;\n}\n\n/**\n * Component to display a property menu with visualization.\n * @public\n */\nexport const PropertyMenuWithVisualization = ({\n group,\n color,\n ...rest\n}: PropertyMenuWithVisualizationProps) => {\n const [isInformationPanelOpen, setIsInformationPanelOpen] = useState<boolean>(false);\n\n return (\n <InformationPanelWrapper className='gmw-property-menu-vis-wrapper'>\n <div className=\"gmw-property-menu-vis-toolbar\">\n <GroupColorToggle group={group} color={color} labelPosition=\"left\" />\n <IconButton\n styleType='borderless'\n onClick={() => setIsInformationPanelOpen(true)}\n title='Group Information'\n >\n <SvgProperties />\n </IconButton>\n </div>\n <PropertyMenu group={group} {...rest} />\n <GroupInformationPanel\n isOpen={isInformationPanelOpen}\n onClose={() => setIsInformationPanelOpen(false)}\n query={group.query}\n groupName={group.groupName}\n />\n </InformationPanelWrapper>\n );\n};\n"]}
1
+ {"version":3,"file":"PropertyMenuWithVisualization.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyMenuWithVisualization.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAC3E,OAAO,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,sCAAsC,CAAC;AAU9C;;;GAGG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAG,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,IAAI,EAAsC,EAAE,EAAE;IAC7G,MAAM,CAAC,sBAAsB,EAAE,yBAAyB,CAAC,GAAG,QAAQ,CAAU,KAAK,CAAC,CAAC;IAErF,OAAO,CACL,oBAAC,uBAAuB,IAAC,SAAS,EAAC,+BAA+B;QAChE,6BAAK,SAAS,EAAC,+BAA+B;YAC5C,oBAAC,gBAAgB,IAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,aAAa,EAAC,MAAM,GAAG;YACrE,oBAAC,UAAU,IAAC,SAAS,EAAC,YAAY,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,yBAAyB,CAAC,IAAI,CAAC,EAAE,KAAK,EAAC,mBAAmB;gBAC1G,oBAAC,aAAa,OAAG,CACN,CACT;QACN,oBAAC,YAAY,IAAC,KAAK,EAAE,KAAK,KAAM,IAAI,GAAI;QACxC,oBAAC,qBAAqB,IAAC,MAAM,EAAE,sBAAsB,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,yBAAyB,CAAC,KAAK,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,SAAS,EAAE,KAAK,CAAC,SAAS,GAAI,CAClI,CAC3B,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport React, { useState } from \"react\";\nimport type { PropertyMenuProps } from \"./PropertyMenu\";\nimport { PropertyMenu } from \"./PropertyMenu\";\nimport { GroupColorToggle } from \"./GroupColorToggle\";\nimport { IconButton, InformationPanelWrapper } from \"@itwin/itwinui-react\";\nimport { GroupInformationPanel } from \"./GroupInformationPanel\";\nimport { SvgProperties } from \"@itwin/itwinui-icons-react\";\nimport \"./PropertyMenuWithVisualization.scss\";\n\n/**\n * Properties for the {@link PropertyMenuWithVisualization} component.\n * @public\n */\nexport interface PropertyMenuWithVisualizationProps extends PropertyMenuProps {\n color: string;\n}\n\n/**\n * Component to display a property menu with visualization.\n * @public\n */\nexport const PropertyMenuWithVisualization = ({ group, color, ...rest }: PropertyMenuWithVisualizationProps) => {\n const [isInformationPanelOpen, setIsInformationPanelOpen] = useState<boolean>(false);\n\n return (\n <InformationPanelWrapper className=\"gmw-property-menu-vis-wrapper\">\n <div className=\"gmw-property-menu-vis-toolbar\">\n <GroupColorToggle group={group} color={color} labelPosition=\"left\" />\n <IconButton styleType=\"borderless\" onClick={() => setIsInformationPanelOpen(true)} title=\"Group Information\">\n <SvgProperties />\n </IconButton>\n </div>\n <PropertyMenu group={group} {...rest} />\n <GroupInformationPanel isOpen={isInformationPanelOpen} onClose={() => setIsInformationPanelOpen(false)} query={group.query} groupName={group.groupName} />\n </InformationPanelWrapper>\n );\n};\n"]}
@@ -7,5 +7,5 @@ export interface PropertyNameCellProps<T extends {
7
7
  }
8
8
  export declare const PropertyNameCell: <T extends {
9
9
  propertyName: string;
10
- }>({ property, onClickModify, }: PropertyNameCellProps<T>) => JSX.Element;
10
+ }>({ property, onClickModify }: PropertyNameCellProps<T>) => JSX.Element;
11
11
  //# sourceMappingURL=PropertyNameCell.d.ts.map
@@ -1,8 +1,8 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import React from "react";
6
6
  import { Text } from "@itwin/itwinui-react";
7
- export const PropertyNameCell = ({ property, onClickModify, }) => onClickModify ? (React.createElement("div", { className: "iui-anchor", onClick: () => onClickModify(property) }, property.propertyName)) : (React.createElement(Text, null, property.propertyName));
7
+ export const PropertyNameCell = ({ property, onClickModify }) => onClickModify ? (React.createElement("div", { className: "iui-anchor", onClick: () => onClickModify(property) }, property.propertyName)) : (React.createElement(Text, null, property.propertyName));
8
8
  //# sourceMappingURL=PropertyNameCell.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyNameCell.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyNameCell.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAO5C,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAsC,EACpE,QAAQ,EACR,aAAa,GACY,EAAE,EAAE,CAC7B,aAAa,CAAC,CAAC,CAAC,CACd,6BAAK,SAAS,EAAC,YAAY,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,aAAa,CAAC,QAAQ,CAAC,IAC/D,QAAQ,CAAC,YAAY,CAClB,CACP,CAAC,CAAC,CAAC,CACF,oBAAC,IAAI,QAAE,QAAQ,CAAC,YAAY,CAAQ,CACrC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport React from \"react\";\nimport { Text } from \"@itwin/itwinui-react\";\n\nexport interface PropertyNameCellProps<T extends { propertyName: string }> {\n property: T;\n onClickModify?: (value: T) => void;\n}\n\nexport const PropertyNameCell = <T extends { propertyName: string },>({\n property,\n onClickModify,\n}: PropertyNameCellProps<T>) =>\n onClickModify ? (\n <div className=\"iui-anchor\" onClick={() => onClickModify(property)}>\n {property.propertyName}\n </div>\n ) : (\n <Text>{property.propertyName}</Text>\n );\n"]}
1
+ {"version":3,"file":"PropertyNameCell.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyNameCell.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAO5C,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAqC,EAAE,QAAQ,EAAE,aAAa,EAA4B,EAAE,EAAE,CAC5H,aAAa,CAAC,CAAC,CAAC,CACd,6BAAK,SAAS,EAAC,YAAY,EAAC,OAAO,EAAE,GAAG,EAAE,CAAC,aAAa,CAAC,QAAQ,CAAC,IAC/D,QAAQ,CAAC,YAAY,CAClB,CACP,CAAC,CAAC,CAAC,CACF,oBAAC,IAAI,QAAE,QAAQ,CAAC,YAAY,CAAQ,CACrC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport React from \"react\";\nimport { Text } from \"@itwin/itwinui-react\";\n\nexport interface PropertyNameCellProps<T extends { propertyName: string }> {\n property: T;\n onClickModify?: (value: T) => void;\n}\n\nexport const PropertyNameCell = <T extends { propertyName: string }>({ property, onClickModify }: PropertyNameCellProps<T>) =>\n onClickModify ? (\n <div className=\"iui-anchor\" onClick={() => onClickModify(property)}>\n {property.propertyName}\n </div>\n ) : (\n <Text>{property.propertyName}</Text>\n );\n"]}
@@ -1,7 +1,7 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import { Table } from "@itwin/itwinui-react";
6
6
  import React, { useCallback, useMemo, useState } from "react";
7
7
  import DeleteModal from "../SharedComponents/DeleteModal";
@@ -21,8 +21,7 @@ export const PropertyTable = ({ propertyType, columnsFactory, data, isLoading, o
21
21
  const memoizedColumns = useMemo(() => columnsFactory(handleShowDeleteModal), [columnsFactory, handleShowDeleteModal]);
22
22
  return (React.createElement("div", { className: "gmw-property-table-container" },
23
23
  React.createElement(PropertyTableToolbar, { propertyType: propertyType, onClickAddProperty: onClickAdd, refreshProperties: refreshProperties, isLoading: isLoading }),
24
- React.createElement(Table, { data: isLoading ? [] : data, density: 'extra-condensed', columns: memoizedColumns, emptyTableContent: `No ${propertyType} Properties`, isSortable: true, isLoading: isLoading }),
25
- showDeleteModal &&
26
- React.createElement(DeleteModal, { entityName: showDeleteModal.propertyName, onClose: handleCloseDeleteModal, onDelete: handleDeleteProperty })));
24
+ React.createElement(Table, { data: isLoading ? [] : data, density: "extra-condensed", columns: memoizedColumns, emptyTableContent: `No ${propertyType} Properties`, isSortable: true, isLoading: isLoading }),
25
+ showDeleteModal && React.createElement(DeleteModal, { entityName: showDeleteModal.propertyName, onClose: handleCloseDeleteModal, onDelete: handleDeleteProperty })));
27
26
  };
28
27
  //# sourceMappingURL=PropertyTable.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyTable.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyTable.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAC7C,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAG9D,OAAO,WAAW,MAAM,iCAAiC,CAAC;AAC1D,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,sBAAsB,CAAC;AAiB9B,MAAM,CAAC,MAAM,aAAa,GAAG,CAA8B,EACzD,YAAY,EACZ,cAAc,EACd,IAAI,EACJ,SAAS,EACT,UAAU,EACV,iBAAiB,EACjB,cAAc,GACQ,EAAE,EAAE;IAE1B,MAAM,CAAC,eAAe,EAAE,kBAAkB,CAAC,GAAG,QAAQ,CAAgB,SAAS,CAAC,CAAC;IAEjF,MAAM,oBAAoB,GAAG,WAAW,CAAC,KAAK,IAAI,EAAE;QAClD,MAAM,cAAc,CAAC,eAAe,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC;IAClD,CAAC,EAAE,CAAC,cAAc,EAAE,eAAe,EAAE,EAAE,CAAC,CAAC,CAAC;IAE1C,MAAM,qBAAqB,GAAG,WAAW,CAAC,CAAC,QAAW,EAAE,EAAE;QACxD,kBAAkB,CAAC,QAAQ,CAAC,CAAC;IAC/B,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,MAAM,sBAAsB,GAAG,GAAG,EAAE;QAClC,kBAAkB,CAAC,SAAS,CAAC,CAAC;IAChC,CAAC,CAAC;IAEF,MAAM,eAAe,GAAG,OAAO,CAAC,GAAG,EAAE,CACnC,cAAc,CAAC,qBAAqB,CAAC,EAAE,CAAC,cAAc,EAAE,qBAAqB,CAAC,CAAC,CAAC;IAElF,OAAO,CACL,6BAAK,SAAS,EAAC,8BAA8B;QAC3C,oBAAC,oBAAoB,IACnB,YAAY,EAAE,YAAY,EAC1B,kBAAkB,EAAE,UAAU,EAC9B,iBAAiB,EAAE,iBAAiB,EACpC,SAAS,EAAE,SAAS,GACpB;QACF,oBAAC,KAAK,IACJ,IAAI,EAAE,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,EAC3B,OAAO,EAAC,iBAAiB,EACzB,OAAO,EAAE,eAAe,EACxB,iBAAiB,EAAE,MAAM,YAAY,aAAa,EAClD,UAAU,QACV,SAAS,EAAE,SAAS,GACpB;QACD,eAAe;YACd,oBAAC,WAAW,IACV,UAAU,EAAE,eAAe,CAAC,YAAY,EACxC,OAAO,EAAE,sBAAsB,EAC/B,QAAQ,EAAE,oBAAoB,GAC9B,CACA,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { Table } from \"@itwin/itwinui-react\";\nimport React, { useCallback, useMemo, useState } from \"react\";\nimport type { Column } from \"react-table\";\nimport type { CreateTypeFromInterface } from \"../../common/utils\";\nimport DeleteModal from \"../SharedComponents/DeleteModal\";\nimport { PropertyTableToolbar } from \"./PropertyTableToolbar\";\nimport \"./PropertyTable.scss\";\n\nexport interface PropertyTableItem {\n propertyName: string;\n id: string;\n}\n\nexport interface PropertyTableProps<T extends PropertyTableItem> {\n propertyType: string;\n columnsFactory: (handleShowDeleteModal: (value: T) => void) => Array<Column<T>>;\n data: T[];\n isLoading: boolean;\n onClickAdd?: () => void;\n refreshProperties: () => Promise<void>;\n deleteProperty: (propertyId: string) => Promise<void>;\n}\n\nexport const PropertyTable = <T extends PropertyTableItem>({\n propertyType,\n columnsFactory,\n data,\n isLoading,\n onClickAdd,\n refreshProperties,\n deleteProperty,\n}: PropertyTableProps<T>) => {\n\n const [showDeleteModal, setShowDeleteModal] = useState<T | undefined>(undefined);\n\n const handleDeleteProperty = useCallback(async () => {\n await deleteProperty(showDeleteModal?.id ?? \"\");\n }, [deleteProperty, showDeleteModal?.id]);\n\n const handleShowDeleteModal = useCallback((property: T) => {\n setShowDeleteModal(property);\n }, []);\n\n const handleCloseDeleteModal = () => {\n setShowDeleteModal(undefined);\n };\n\n const memoizedColumns = useMemo(() =>\n columnsFactory(handleShowDeleteModal), [columnsFactory, handleShowDeleteModal]);\n\n return (\n <div className=\"gmw-property-table-container\">\n <PropertyTableToolbar\n propertyType={propertyType}\n onClickAddProperty={onClickAdd}\n refreshProperties={refreshProperties}\n isLoading={isLoading}\n />\n <Table<CreateTypeFromInterface<T>>\n data={isLoading ? [] : data}\n density='extra-condensed'\n columns={memoizedColumns}\n emptyTableContent={`No ${propertyType} Properties`}\n isSortable\n isLoading={isLoading}\n />\n {showDeleteModal &&\n <DeleteModal\n entityName={showDeleteModal.propertyName}\n onClose={handleCloseDeleteModal}\n onDelete={handleDeleteProperty}\n />}\n </div>\n );\n};\n"]}
1
+ {"version":3,"file":"PropertyTable.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyTable.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAC7C,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAG9D,OAAO,WAAW,MAAM,iCAAiC,CAAC;AA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a,EAClD,UAAU,QACV,SAAS,EAAE,SAAS,GACpB;QACD,eAAe,IAAI,oBAAC,WAAW,IAAC,UAAU,EAAE,eAAe,CAAC,YAAY,EAAE,OAAO,EAAE,sBAAsB,EAAE,QAAQ,EAAE,oBAAoB,GAAI,CAC1I,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { Table } from \"@itwin/itwinui-react\";\nimport React, { useCallback, useMemo, useState } from \"react\";\nimport type { Column } from \"react-table\";\nimport type { CreateTypeFromInterface } from \"../../common/utils\";\nimport DeleteModal from \"../SharedComponents/DeleteModal\";\nimport { PropertyTableToolbar } from \"./PropertyTableToolbar\";\nimport \"./PropertyTable.scss\";\n\nexport interface PropertyTableItem {\n propertyName: string;\n id: string;\n}\n\nexport interface PropertyTableProps<T extends PropertyTableItem> {\n propertyType: string;\n columnsFactory: (handleShowDeleteModal: (value: T) => void) => Array<Column<T>>;\n data: T[];\n isLoading: boolean;\n onClickAdd?: () => void;\n refreshProperties: () => Promise<void>;\n deleteProperty: (propertyId: string) => Promise<void>;\n}\n\nexport const PropertyTable = <T extends PropertyTableItem>({\n propertyType,\n columnsFactory,\n data,\n isLoading,\n onClickAdd,\n refreshProperties,\n deleteProperty,\n}: PropertyTableProps<T>) => {\n const [showDeleteModal, setShowDeleteModal] = useState<T | undefined>(undefined);\n\n const handleDeleteProperty = useCallback(async () => {\n await deleteProperty(showDeleteModal?.id ?? \"\");\n }, [deleteProperty, showDeleteModal?.id]);\n\n const handleShowDeleteModal = useCallback((property: T) => {\n setShowDeleteModal(property);\n }, []);\n\n const handleCloseDeleteModal = () => {\n setShowDeleteModal(undefined);\n };\n\n const memoizedColumns = useMemo(() => columnsFactory(handleShowDeleteModal), [columnsFactory, handleShowDeleteModal]);\n\n return (\n <div className=\"gmw-property-table-container\">\n <PropertyTableToolbar propertyType={propertyType} onClickAddProperty={onClickAdd} refreshProperties={refreshProperties} isLoading={isLoading} />\n <Table<CreateTypeFromInterface<T>>\n data={isLoading ? [] : data}\n density=\"extra-condensed\"\n columns={memoizedColumns}\n emptyTableContent={`No ${propertyType} Properties`}\n isSortable\n isLoading={isLoading}\n />\n {showDeleteModal && <DeleteModal entityName={showDeleteModal.propertyName} onClose={handleCloseDeleteModal} onDelete={handleDeleteProperty} />}\n </div>\n );\n};\n"]}
@@ -6,5 +6,5 @@ export interface PropertyTableToolbarProps {
6
6
  refreshProperties: () => void;
7
7
  isLoading: boolean;
8
8
  }
9
- export declare const PropertyTableToolbar: ({ propertyType, onClickAddProperty, refreshProperties, isLoading, }: PropertyTableToolbarProps) => JSX.Element;
9
+ export declare const PropertyTableToolbar: ({ propertyType, onClickAddProperty, refreshProperties, isLoading }: PropertyTableToolbarProps) => JSX.Element;
10
10
  //# sourceMappingURL=PropertyTableToolbar.d.ts.map
@@ -1,12 +1,12 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import React from "react";
6
6
  import { SvgAdd, SvgRefresh } from "@itwin/itwinui-icons-react";
7
7
  import { Button, IconButton } from "@itwin/itwinui-react";
8
8
  import "./PropertyTableToolbar.scss";
9
- export const PropertyTableToolbar = ({ propertyType, onClickAddProperty, refreshProperties, isLoading, }) => (React.createElement("div", { className: "gmw-property-table-toolbar" },
9
+ export const PropertyTableToolbar = ({ propertyType, onClickAddProperty, refreshProperties, isLoading }) => (React.createElement("div", { className: "gmw-property-table-toolbar" },
10
10
  onClickAddProperty && (React.createElement(Button, { startIcon: React.createElement(SvgAdd, null), styleType: "high-visibility", onClick: onClickAddProperty },
11
11
  "Add ",
12
12
  propertyType,
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyTableToolbar.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyTableToolbar.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,6BAA6B,CAAC;AASrC,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,EACnC,YAAY,EACZ,kBAAkB,EAClB,iBAAiB,EACjB,SAAS,GACiB,EAAE,EAAE,CAAC,CAC/B,6BAAK,SAAS,EAAC,4BAA4B;IACxC,kBAAkB,IAAI,CACrB,oBAAC,MAAM,IACL,SAAS,EAAE,oBAAC,MAAM,OAAG,EACrB,SAAS,EAAC,iBAAiB,EAC3B,OAAO,EAAE,kBAAkB;;QAEtB,YAAY;oBACV,CACV;IACD,oBAAC,UAAU,IACT,KAAK,EAAC,SAAS,EACf,SAAS,EAAC,mCAAmC,EAC7C,OAAO,EAAE,iBAAiB,EAC1B,QAAQ,EAAE,SAAS,EACnB,SAAS,EAAC,YAAY;QAEtB,oBAAC,UAAU,OAAG,CACH,CACT,CACP,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport React from \"react\";\nimport { SvgAdd, SvgRefresh } from \"@itwin/itwinui-icons-react\";\nimport { Button, IconButton } from \"@itwin/itwinui-react\";\nimport \"./PropertyTableToolbar.scss\";\n\nexport interface PropertyTableToolbarProps {\n propertyType: string;\n onClickAddProperty?: () => void;\n refreshProperties: () => void;\n isLoading: boolean;\n}\n\nexport const PropertyTableToolbar = ({\n propertyType,\n onClickAddProperty,\n refreshProperties,\n isLoading,\n}: PropertyTableToolbarProps) => (\n <div className=\"gmw-property-table-toolbar\">\n {onClickAddProperty && (\n <Button\n startIcon={<SvgAdd />}\n styleType=\"high-visibility\"\n onClick={onClickAddProperty}\n >\n Add {propertyType} Property\n </Button>\n )}\n <IconButton\n title=\"Refresh\"\n className=\"gmw-property-table-refresh-button\"\n onClick={refreshProperties}\n disabled={isLoading}\n styleType=\"borderless\"\n >\n <SvgRefresh />\n </IconButton>\n </div>\n);\n"]}
1
+ {"version":3,"file":"PropertyTableToolbar.js","sourceRoot":"","sources":["../../../../src/components/Properties/PropertyTableToolbar.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,6BAA6B,CAAC;AASrC,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,EAAE,YAAY,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,SAAS,EAA6B,EAAE,EAAE,CAAC,CACrI,6BAAK,SAAS,EAAC,4BAA4B;IACxC,kBAAkB,IAAI,CACrB,oBAAC,MAAM,IAAC,SAAS,EAAE,oBAAC,MAAM,OAAG,EAAE,SAAS,EAAC,iBAAiB,EAAC,OAAO,EAAE,kBAAkB;;QAC/E,YAAY;oBACV,CACV;IACD,oBAAC,UAAU,IAAC,KAAK,EAAC,SAAS,EAAC,SAAS,EAAC,mCAAmC,EAAC,OAAO,EAAE,iBAAiB,EAAE,QAAQ,EAAE,SAAS,EAAE,SAAS,EAAC,YAAY;QAC/I,oBAAC,UAAU,OAAG,CACH,CACT,CACP,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport React from \"react\";\nimport { SvgAdd, SvgRefresh } from \"@itwin/itwinui-icons-react\";\nimport { Button, IconButton } from \"@itwin/itwinui-react\";\nimport \"./PropertyTableToolbar.scss\";\n\nexport interface PropertyTableToolbarProps {\n propertyType: string;\n onClickAddProperty?: () => void;\n refreshProperties: () => void;\n isLoading: boolean;\n}\n\nexport const PropertyTableToolbar = ({ propertyType, onClickAddProperty, refreshProperties, isLoading }: PropertyTableToolbarProps) => (\n <div className=\"gmw-property-table-toolbar\">\n {onClickAddProperty && (\n <Button startIcon={<SvgAdd />} styleType=\"high-visibility\" onClick={onClickAddProperty}>\n Add {propertyType} Property\n </Button>\n )}\n <IconButton title=\"Refresh\" className=\"gmw-property-table-refresh-button\" onClick={refreshProperties} disabled={isLoading} styleType=\"borderless\">\n <SvgRefresh />\n </IconButton>\n </div>\n);\n"]}
@@ -1,7 +1,7 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import { useEffect, useState } from "react";
6
6
  import { resolveFormulaDataType } from "../../../formula/FormulaDataTypeResolver";
7
7
  import { debounce } from "../../../common/utils";
@@ -1 +1 @@
1
- {"version":3,"file":"useFormulaValidation.js","sourceRoot":"","sources":["../../../../../src/components/Properties/hooks/useFormulaValidation.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,sBAAsB,EAAE,MAAM,0CAA0C,CAAC;AAElF,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAEjD,SAAS,QAAQ,CA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,WAAW,CAAC,EAAE,CAAC;AAC3J,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { useEffect, useState } from \"react\";\nimport { resolveFormulaDataType } from \"../../../formula/FormulaDataTypeResolver\";\nimport type { DataType, PropertyMap } from \"../../../formula/Types\";\nimport { debounce } from \"../../../common/utils\";\n\nfunction validate(formulaName: string, formula: string, properties: PropertyMap, setFormulaErrorMessage: (s: string) => void, setIsValid: (b: boolean) => void, setDataType: (inferredDataType: DataType | undefined) => void ): boolean {\n if (!formula) {\n setFormulaErrorMessage(\"\");\n setIsValid(false);\n setDataType(undefined);\n return false;\n }\n\n const resolveFormulaType = resolveFormulaDataType(formulaName, formula, properties);\n const error = resolveFormulaType.errorMessage ?? \"\";\n setFormulaErrorMessage(error);\n setIsValid(!error);\n setDataType(resolveFormulaType.value);\n return !error;\n}\n\nconst debouncedValidationFunc = debounce(validate, 5000);\n\nexport function useFormulaValidation(formulaName: string, formula: string, properties: PropertyMap, setFormulaErrorMessage: (s: string) => void) {\n const [isValid, setIsValid] = useState(false);\n const [inferredDataType, setDataType] = useState<DataType | undefined>(undefined);\n useEffect(() => debouncedValidationFunc(formulaName, formula, properties, setFormulaErrorMessage, setIsValid, setDataType), [formulaName, formula, properties, setFormulaErrorMessage]);\n return { isValid, inferredDataType, forceValidation: () => validate(formulaName, formula, properties, setFormulaErrorMessage, setIsValid, setDataType) };\n}\n"]}
1
+ {"version":3,"file":"useFormulaValidation.js","sourceRoot":"","sources":["../../../../../src/components/Properties/hooks/useFormulaValidation.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5C,OAAO,EAAE,sBAAsB,EAAE,MAAM,0CAA0C,CAAC;AAElF,OAAO,EAAE,QAAQ,EAAE,MAAM,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AU,EAAE,sBAAsB,EAAE,UAAU,EAAE,WAAW,CAAC,EAAE,CAAC;AAC3J,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { useEffect, useState } from \"react\";\nimport { resolveFormulaDataType } from \"../../../formula/FormulaDataTypeResolver\";\nimport type { DataType, PropertyMap } from \"../../../formula/Types\";\nimport { debounce } from \"../../../common/utils\";\n\nfunction validate(\n formulaName: string,\n formula: string,\n properties: PropertyMap,\n setFormulaErrorMessage: (s: string) => void,\n setIsValid: (b: boolean) => void,\n setDataType: (inferredDataType: DataType | undefined) => void,\n): boolean {\n if (!formula) {\n setFormulaErrorMessage(\"\");\n setIsValid(false);\n setDataType(undefined);\n return false;\n }\n\n const resolveFormulaType = resolveFormulaDataType(formulaName, formula, properties);\n const error = resolveFormulaType.errorMessage ?? \"\";\n setFormulaErrorMessage(error);\n setIsValid(!error);\n setDataType(resolveFormulaType.value);\n return !error;\n}\n\nconst debouncedValidationFunc = debounce(validate, 5000);\n\nexport function useFormulaValidation(formulaName: string, formula: string, properties: PropertyMap, setFormulaErrorMessage: (s: string) => void) {\n const [isValid, setIsValid] = useState(false);\n const [inferredDataType, setDataType] = useState<DataType | undefined>(undefined);\n useEffect(\n () => debouncedValidationFunc(formulaName, formula, properties, setFormulaErrorMessage, setIsValid, setDataType),\n [formulaName, formula, properties, setFormulaErrorMessage],\n );\n return { isValid, inferredDataType, forceValidation: () => validate(formulaName, formula, properties, setFormulaErrorMessage, setIsValid, setDataType) };\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"usePropertiesQuery.js","sourceRoot":"","sources":["../../../../../src/components/Properties/hooks/usePropertiesQuery.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,QAAgB,EAAE,SAAiB,EAAE,OAAe,EAAE,cAAgC,EAAE,gBAAmC,EAAE,EAAE;IAChK,OAAO,QAAQ,CAAC;QACd,QAAQ,EAAE,CAAC,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,OAAO,CAAC;QACtD,OAAO,EAAG,KAAK,IAAI,EAAE,CAAC,gBAAgB,CAAC,aAAa,CAAC,MAAM,cAAc,EAAE,EAAE,SAAS,EAAE,OAAO,CAAC;KACjG,CAAC,CAAC;AACL,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport type { IPropertiesClient } from \"@itwin/insights-client\";\nimport { useQuery } from \"@tanstack/react-query\";\nimport type { GetAccessTokenFn } from \"../../context/GroupingApiConfigContext\";\n\nexport const usePropertiesQuery = (iModelId: string, mappingId: string, groupId: string, getAccessToken: GetAccessTokenFn, propertiesClient: IPropertiesClient) => {\n return useQuery({\n queryKey: [\"properties\", iModelId, mappingId, groupId],\n queryFn: async () => propertiesClient.getProperties(await getAccessToken(), mappingId, groupId),\n });\n};\n"]}
1
+ {"version":3,"file":"usePropertiesQuery.js","sourceRoot":"","sources":["../../../../../src/components/Properties/hooks/usePropertiesQuery.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAChC,QAAgB,EAChB,SAAiB,EACjB,OAAe,EACf,cAAgC,EAChC,gBAAmC,EACnC,EAAE;IACF,OAAO,QAAQ,CAAC;QACd,QAAQ,EAAE,CAAC,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,OAAO,CAAC;QACtD,OAAO,EAAE,KAAK,IAAI,EAAE,CAAC,gBAAgB,CAAC,aAAa,CAAC,MAAM,cAAc,EAAE,EAAE,SAAS,EAAE,OAAO,CAAC;KAChG,CAAC,CAAC;AACL,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport type { IPropertiesClient } from \"@itwin/insights-client\";\nimport { useQuery } from \"@tanstack/react-query\";\nimport type { GetAccessTokenFn } from \"../../context/GroupingApiConfigContext\";\n\nexport const usePropertiesQuery = (\n iModelId: string,\n mappingId: string,\n groupId: string,\n getAccessToken: GetAccessTokenFn,\n propertiesClient: IPropertiesClient,\n) => {\n return useQuery({\n queryKey: [\"properties\", iModelId, mappingId, groupId],\n queryFn: async () => propertiesClient.getProperties(await getAccessToken(), mappingId, groupId),\n });\n};\n"]}
@@ -1,7 +1,7 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import { useState } from "react";
6
6
  import SimpleReactValidator from "simple-react-validator";
7
7
  export const Validators = {
@@ -21,7 +21,7 @@ export const Validators = {
21
21
  FollowedByLettersUnderscoresAndDigits: {
22
22
  message: "Name can only contain letters, underscores, or digits",
23
23
  rule: (val) => {
24
- const regexPattern = new RegExp(/[\p{L}\p{Nl}\p{Nd}\p{Mn}\p{Mc}\p{Pc}\p{Cf}]+$/u);
24
+ const regexPattern = new RegExp(/^[\p{L}\p{Nl}\p{Nd}\p{Mn}\p{Mc}\p{Pc}\p{Cf}]+$/u);
25
25
  return regexPattern.test(val);
26
26
  },
27
27
  },
@@ -1 +1 @@
1
- {"version":3,"file":"useValidator.js","sourceRoot":"","sources":["../../../../../src/components/Properties/hooks/useValidator.ts"],"names":[],"mappings":"AAAA;;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AAG,IAAI,oBAAoB,CAAC;QACzC,QAAQ,EAAE,aAAa;QACvB,UAAU,EAAE,eAAe;KAC5B,CAAC,CAAC;IAEH,IAAI,IAAI,EAAE;QACR,SAAS,CAAC,YAAY,EAAE,CAAC;KAC1B;IAED,OAAO,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;AAC9B,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { useState } from \"react\";\nimport SimpleReactValidator from \"simple-react-validator\";\n\nexport const Validators = {\n NoDuplicateUnderscore: {\n message: 'Remove duplicate \"_\"',\n rule: (val: string) => {\n return !val.match(/__+/i);\n },\n },\n OnlyBeginsWithLetterOrUnderscore: {\n message: \"Name can only start with a letter or underscore.\",\n rule: (val: string) => {\n const regexPattern = new RegExp(/^[\\p{L}\\p{Nl}_]+/u);\n return regexPattern.test(val);\n },\n },\n FollowedByLettersUnderscoresAndDigits: {\n message: \"Name can only contain letters, underscores, or digits\",\n rule: (val: string) => {\n const regexPattern = new RegExp(/[\\p{L}\\p{Nl}\\p{Nd}\\p{Mn}\\p{Mc}\\p{Pc}\\p{Cf}]+$/u);\n return regexPattern.test(val);\n },\n },\n CharLimit: {\n message: \"There is an 128 character limit.\",\n rule: (val: string) => {\n return val.length <= 128;\n },\n },\n};\n\nexport const NAME_REQUIREMENTS =\n \"required|NoDuplicateUnderscore|OnlyBeginsWithLetterOrUnderscore|FollowedByLettersUnderscoresAndDigits|CharLimit\";\n\nexport const Messages = { required: \"This field is required.\" };\n\nconst useValidator = (\n customMessage = Messages,\n customValidator = Validators,\n): [SimpleReactValidator, React.Dispatch<React.SetStateAction<boolean>>] => {\n const [show, setShow] = useState(false);\n const validator = new SimpleReactValidator({\n messages: customMessage,\n validators: customValidator,\n });\n\n if (show) {\n validator.showMessages();\n }\n\n return [validator, setShow];\n};\n\nexport default useValidator;\n"]}
1
+ {"version":3,"file":"useValidator.js","sourceRoot":"","sources":["../../../../../src/components/Properties/hooks/useValidator.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,oBAAoB,MAAM,wBAAwB,CAAC;AAE1D,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,qBAAqB,EAAE;QACrB,OAAO,EAAE,sBAAsB;QAC/B,IAAI,EAAE,CAAC,GAAW,EAAE,EAAE;YACpB,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QAC5B,CAAC;KACF;IACD,gCAAgC,EAAE;QAChC,OAAO,EAAE,kDAAkD;QAC3D,IAAI,EAAE,CAAC,GAAW,EAAE,EAAE;YACpB,MAAM,YAAY,GAAG,IAAI,MAAM,CAAC,mBAAmB,CAAC,CAAC;YACrD,OAAO,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAChC,CAAC;KACF;IACD,qCAAqC,EAAE;QACrC,OAAO,EAAE,uDAAuD;QAChE,IAAI,EAAE,CAAC,GAAW,EAAE,EAAE;YACpB,MAAM,YAAY,GAAG,IAAI,MAAM,CAAC,iDAAiD,CAAC,CAAC;YACnF,OAAO,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAChC,CAAC;KACF;IACD,SAAS,EAAE;QACT,OAAO,EAAE,kCAAkC;QAC3C,IAAI,EAAE,CAAC,GAAW,EAAE,EAAE;YACpB,OAAO,GAAG,CAAC,MAAM,IAAI,GAAG,CAAC;QAC3B,CAAC;KACF;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAG,iHAAiH,CAAC;AAEnJ,MAAM,CAAC,MAAM,QAAQ,GAAG,EAAE,QAAQ,EAAE,yBAAyB,EAAE,CAAC;AAEhE,MAAM,YAAY,GAAG,CAAC,aAAa,GAAG,QAAQ,EAAE,eAAe,GAAG,UAAU,EAAyE,EAAE;IACrJ,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IACxC,MAAM,SAAS,GAAG,IAAI,oBAAoB,CAAC;QACzC,QAAQ,EAAE,aAAa;QACvB,UAAU,EAAE,eAAe;KAC5B,CAAC,CAAC;IAEH,IAAI,IAAI,EAAE;QACR,SAAS,CAAC,YAAY,EAAE,CAAC;KAC1B;IAED,OAAO,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;AAC9B,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { useState } from \"react\";\nimport SimpleReactValidator from \"simple-react-validator\";\n\nexport const Validators = {\n NoDuplicateUnderscore: {\n message: 'Remove duplicate \"_\"',\n rule: (val: string) => {\n return !val.match(/__+/i);\n },\n },\n OnlyBeginsWithLetterOrUnderscore: {\n message: \"Name can only start with a letter or underscore.\",\n rule: (val: string) => {\n const regexPattern = new RegExp(/^[\\p{L}\\p{Nl}_]+/u);\n return regexPattern.test(val);\n },\n },\n FollowedByLettersUnderscoresAndDigits: {\n message: \"Name can only contain letters, underscores, or digits\",\n rule: (val: string) => {\n const regexPattern = new RegExp(/^[\\p{L}\\p{Nl}\\p{Nd}\\p{Mn}\\p{Mc}\\p{Pc}\\p{Cf}]+$/u);\n return regexPattern.test(val);\n },\n },\n CharLimit: {\n message: \"There is an 128 character limit.\",\n rule: (val: string) => {\n return val.length <= 128;\n },\n },\n};\n\nexport const NAME_REQUIREMENTS = \"required|NoDuplicateUnderscore|OnlyBeginsWithLetterOrUnderscore|FollowedByLettersUnderscoresAndDigits|CharLimit\";\n\nexport const Messages = { required: \"This field is required.\" };\n\nconst useValidator = (customMessage = Messages, customValidator = Validators): [SimpleReactValidator, React.Dispatch<React.SetStateAction<boolean>>] => {\n const [show, setShow] = useState(false);\n const validator = new SimpleReactValidator({\n messages: customMessage,\n validators: customValidator,\n });\n\n if (show) {\n validator.showMessages();\n }\n\n return [validator, setShow];\n};\n\nexport default useValidator;\n"]}
@@ -7,6 +7,6 @@ export interface ActionPanelProps {
7
7
  isSavingDisabled?: boolean;
8
8
  isLoading?: boolean;
9
9
  }
10
- declare const ActionPanel: ({ onSave, onCancel, isCancelDisabled, isSavingDisabled, isLoading, }: ActionPanelProps) => JSX.Element;
10
+ declare const ActionPanel: ({ onSave, onCancel, isCancelDisabled, isSavingDisabled, isLoading }: ActionPanelProps) => JSX.Element;
11
11
  export default ActionPanel;
12
12
  //# sourceMappingURL=ActionPanel.d.ts.map
@@ -1,18 +1,17 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import { Button } from "@itwin/itwinui-react";
6
6
  import * as React from "react";
7
7
  import "./ActionPanel.scss";
8
8
  import { LoadingSpinner } from "./LoadingSpinner";
9
- const ActionPanel = ({ onSave, onCancel, isCancelDisabled = false, isSavingDisabled = false, isLoading = false, }) => {
10
- return (React.createElement("div", { id: 'action', className: 'gmw-action-panel-container' },
11
- React.createElement("div", { className: 'gmw-action-panel' },
12
- isLoading &&
13
- React.createElement(LoadingSpinner, null),
14
- React.createElement(Button, { disabled: isSavingDisabled || isLoading, styleType: 'high-visibility', id: 'save-app', onClick: onSave }, "Save"),
15
- onCancel && React.createElement(Button, { styleType: 'default', type: 'button', id: 'cancel', onClick: onCancel, disabled: isCancelDisabled || isLoading }, "Cancel"))));
9
+ const ActionPanel = ({ onSave, onCancel, isCancelDisabled = false, isSavingDisabled = false, isLoading = false }) => {
10
+ return (React.createElement("div", { id: "action", className: "gmw-action-panel-container" },
11
+ React.createElement("div", { className: "gmw-action-panel" },
12
+ isLoading && React.createElement(LoadingSpinner, null),
13
+ React.createElement(Button, { disabled: isSavingDisabled || isLoading, styleType: "high-visibility", id: "save-app", onClick: onSave }, "Save"),
14
+ onCancel && (React.createElement(Button, { styleType: "default", type: "button", id: "cancel", onClick: onCancel, disabled: isCancelDisabled || isLoading }, "Cancel")))));
16
15
  };
17
16
  export default ActionPanel;
18
17
  //# sourceMappingURL=ActionPanel.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ActionPanel.js","sourceRoot":"","sources":["../../../../src/components/SharedComponents/ActionPanel.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,oBAAoB,CAAC;AAC5B,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAUlD,MAAM,WAAW,GAAG,CAAC,EACnB,MAAM,EACN,QAAQ,EACR,gBAAgB,GAAG,KAAK,EACxB,gBAAgB,GAAG,KAAK,EACxB,SAAS,GAAG,KAAK,GACA,EAAe,EAAE;IAClC,OAAO,CACL,6BAAK,EAAE,EAAC,QAAQ,EAAC,SAAS,EAAC,4BAA4B;QACrD,6BAAK,SAAS,EAAC,kBAAkB;YAC9B,SAAS;gBACR,oBAAC,cAAc,OAAG;YAEpB,oBAAC,MAAM,IACL,QAAQ,EAAE,gBAAgB,IAAI,SAAS,EACvC,SAAS,EAAC,iBAAiB,EAC3B,EAAE,EAAC,UAAU,EACb,OAAO,EAAE,MAAM,WAGR;YACR,QAAQ,IAAI,oBAAC,MAAM,IAClB,SAAS,EAAC,SAAS,EACnB,IAAI,EAAC,QAAQ,EACb,EAAE,EAAC,QAAQ,EACX,OAAO,EAAE,QAAQ,EACjB,QAAQ,EAAE,gBAAgB,IAAI,SAAS,aAGhC,CACL,CACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { Button } from \"@itwin/itwinui-react\";\nimport * as React from \"react\";\nimport \"./ActionPanel.scss\";\nimport { LoadingSpinner } from \"./LoadingSpinner\";\n\nexport interface ActionPanelProps {\n onSave: () => void;\n onCancel?: () => void;\n isCancelDisabled?: boolean;\n isSavingDisabled?: boolean;\n isLoading?: boolean;\n}\n\nconst ActionPanel = ({\n onSave,\n onCancel,\n isCancelDisabled = false,\n isSavingDisabled = false,\n isLoading = false,\n}: ActionPanelProps): JSX.Element => {\n return (\n <div id='action' className='gmw-action-panel-container'>\n <div className='gmw-action-panel'>\n {isLoading &&\n <LoadingSpinner />\n }\n <Button\n disabled={isSavingDisabled || isLoading}\n styleType='high-visibility'\n id='save-app'\n onClick={onSave}\n >\n Save\n </Button>\n {onCancel && <Button\n styleType='default'\n type='button'\n id='cancel'\n onClick={onCancel}\n disabled={isCancelDisabled || isLoading}\n >\n Cancel\n </Button>}\n </div>\n </div>\n );\n};\n\nexport default ActionPanel;\n"]}
1
+ {"version":3,"file":"ActionPanel.js","sourceRoot":"","sources":["../../../../src/components/SharedComponents/ActionPanel.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,oBAAoB,CAAC;AAC5B,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAUlD,MAAM,WAAW,GAAG,CAAC,EAAE,MAAM,EAAE,QAAQ,EAAE,gBAAgB,GAAG,KAAK,EAAE,gBAAgB,GAAG,KAAK,EAAE,SAAS,GAAG,KAAK,EAAoB,EAAe,EAAE;IACjJ,OAAO,CACL,6BAAK,EAAE,EAAC,QAAQ,EAAC,SAAS,EAAC,4BAA4B;QACrD,6BAAK,SAAS,EAAC,kBAAkB;YAC9B,SAAS,IAAI,oBAAC,cAAc,OAAG;YAChC,oBAAC,MAAM,IAAC,QAAQ,EAAE,gBAAgB,IAAI,SAAS,EAAE,SAAS,EAAC,iBAAiB,EAAC,EAAE,EAAC,UAAU,EAAC,OAAO,EAAE,MAAM,WAEjG;YACR,QAAQ,IAAI,CACX,oBAAC,MAAM,IAAC,SAAS,EAAC,SAAS,EAAC,IAAI,EAAC,QAAQ,EAAC,EAAE,EAAC,QAAQ,EAAC,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,gBAAgB,IAAI,SAAS,aAEvG,CACV,CACG,CACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { Button } from \"@itwin/itwinui-react\";\nimport * as React from \"react\";\nimport \"./ActionPanel.scss\";\nimport { LoadingSpinner } from \"./LoadingSpinner\";\n\nexport interface ActionPanelProps {\n onSave: () => void;\n onCancel?: () => void;\n isCancelDisabled?: boolean;\n isSavingDisabled?: boolean;\n isLoading?: boolean;\n}\n\nconst ActionPanel = ({ onSave, onCancel, isCancelDisabled = false, isSavingDisabled = false, isLoading = false }: ActionPanelProps): JSX.Element => {\n return (\n <div id=\"action\" className=\"gmw-action-panel-container\">\n <div className=\"gmw-action-panel\">\n {isLoading && <LoadingSpinner />}\n <Button disabled={isSavingDisabled || isLoading} styleType=\"high-visibility\" id=\"save-app\" onClick={onSave}>\n Save\n </Button>\n {onCancel && (\n <Button styleType=\"default\" type=\"button\" id=\"cancel\" onClick={onCancel} disabled={isCancelDisabled || isLoading}>\n Cancel\n </Button>\n )}\n </div>\n </div>\n );\n};\n\nexport default ActionPanel;\n"]}
@@ -5,6 +5,6 @@ export interface DeleteModalProps {
5
5
  onClose: () => void;
6
6
  onDelete: () => Promise<void>;
7
7
  }
8
- export declare const DeleteModal: ({ entityName, onClose, onDelete, }: DeleteModalProps) => JSX.Element;
8
+ export declare const DeleteModal: ({ entityName, onClose, onDelete }: DeleteModalProps) => JSX.Element;
9
9
  export default DeleteModal;
10
10
  //# sourceMappingURL=DeleteModal.d.ts.map
@@ -1,13 +1,13 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
5
- import { Button, MiddleTextTruncation, Modal, ModalButtonBar, Text, } from "@itwin/itwinui-react";
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
+ import { Button, MiddleTextTruncation, Modal, ModalButtonBar, Text } from "@itwin/itwinui-react";
6
6
  import { useMutation } from "@tanstack/react-query";
7
7
  import React, { useCallback, useState } from "react";
8
8
  import "./DeleteModal.scss";
9
9
  import { LoadingSpinner } from "./LoadingSpinner";
10
- export const DeleteModal = ({ entityName, onClose, onDelete, }) => {
10
+ export const DeleteModal = ({ entityName, onClose, onDelete }) => {
11
11
  const [localEntityName] = useState(entityName);
12
12
  const deleteMutation = useMutation({
13
13
  mutationFn: onDelete,
@@ -19,16 +19,15 @@ export const DeleteModal = ({ entityName, onClose, onDelete, }) => {
19
19
  deleteMutation.mutate();
20
20
  }, [deleteMutation]);
21
21
  return (React.createElement(React.Fragment, null,
22
- React.createElement(Modal, { title: 'Confirm', modalRootId: 'grouping-mapping-widget', isOpen: !!localEntityName, isDismissible: !deleteMutation.isLoading, onClose: onClose },
22
+ React.createElement(Modal, { title: "Confirm", modalRootId: "grouping-mapping-widget", isOpen: !!localEntityName, isDismissible: !deleteMutation.isLoading, onClose: onClose },
23
23
  React.createElement("div", { className: "gmw-delete-modal-body-text" },
24
24
  React.createElement(Text, { variant: "leading", as: "h3" }, "Are you sure you want to delete"),
25
25
  React.createElement("strong", null, React.createElement(MiddleTextTruncation, { text: `${entityName}?` }))),
26
26
  React.createElement(ModalButtonBar, null,
27
- deleteMutation.isLoading &&
28
- React.createElement("div", { className: "gmw-loading-delete" },
29
- React.createElement(LoadingSpinner, null)),
30
- React.createElement(Button, { styleType: 'high-visibility', onClick: deleteCallback, disabled: deleteMutation.isLoading }, "Delete"),
31
- React.createElement(Button, { styleType: 'default', onClick: onClose, disabled: deleteMutation.isLoading }, "Cancel")))));
27
+ deleteMutation.isLoading && (React.createElement("div", { className: "gmw-loading-delete" },
28
+ React.createElement(LoadingSpinner, null))),
29
+ React.createElement(Button, { styleType: "high-visibility", onClick: deleteCallback, disabled: deleteMutation.isLoading }, "Delete"),
30
+ React.createElement(Button, { styleType: "default", onClick: onClose, disabled: deleteMutation.isLoading }, "Cancel")))));
32
31
  };
33
32
  export default DeleteModal;
34
33
  //# sourceMappingURL=DeleteModal.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DeleteModal.js","sourceRoot":"","sources":["../../../../src/components/SharedComponents/DeleteModal.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EACL,MAAM,EACN,oBAAoB,EACpB,KAAK,EACL,cAAc,EACd,IAAI,GACL,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACrD,OAAO,oBAAoB,CAAC;AAC5B,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAQlD,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,EAC1B,UAAU,EACV,OAAO,EACP,QAAQ,GACS,EAAE,EAAE;IACrB,MAAM,CAAC,eAAe,CAAC,GAAG,QAAQ,CAAC,UAAU,CAAC,CAAC;IAE/C,MAAM,cAAc,GAAG,WAAW,CAAC;QACjC,UAAU,EAAE,QAAQ;QACpB,SAAS,EAAE,KAAK,IAAI,EAAE;YACpB,OAAO,EAAE,CAAC;QACZ,CAAC;KACF,CAAC,CAAC;IAEH,MAAM,cAAc,GAAG,WAAW,CAAC,GAAG,EAAE;QACtC,cAAc,CAAC,MAAM,EAAE,CAAC;IAC1B,CAAC,EAAE,CAAC,cAAc,CAAC,CAAC,CAAC;IAErB,OAAO,CACL;QACE,oBAAC,KAAK,IACJ,KAAK,EAAC,SAAS,EACf,WAAW,EAAC,yBAAyB,EACrC,MAAM,EAAE,CAAC,CAAC,eAAe,EACzB,aAAa,EAAE,CAAC,cAAc,CAAC,SAAS,EACxC,OAAO,EAAE,OAAO;YAEhB,6BAAK,SAAS,EAAC,4BAA4B;gBACzC,oBAAC,IAAI,IAAC,OAAO,EAAC,SAAS,EAAC,EAAE,EAAC,IAAI,sCAExB;gBACP,oCACG,oBAAC,oBAAoB,IAAC,IAAI,EAAE,GAAG,UAAU,GAAG,GAAI,CAC1C,CACL;YACN,oBAAC,cAAc;gBACZ,cAAc,CAAC,SAAS;oBACvB,6BAAK,SAAS,EAAC,oBAAoB;wBACjC,oBAAC,cAAc,OAAG,CACd;gBACR,oBAAC,MAAM,IAAC,SAAS,EAAC,iBAAiB,EAAC,OAAO,EAAE,cAAc,EAAE,QAAQ,EAAE,cAAc,CAAC,SAAS,aAEtF;gBACT,oBAAC,MAAM,IACL,SAAS,EAAC,SAAS,EACnB,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,cAAc,CAAC,SAAS,aAG3B,CACM,CACX,CACP,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport {\n Button,\n MiddleTextTruncation,\n Modal,\n ModalButtonBar,\n Text,\n} from \"@itwin/itwinui-react\";\nimport { useMutation } from \"@tanstack/react-query\";\nimport React, { useCallback, useState } from \"react\";\nimport \"./DeleteModal.scss\";\nimport { LoadingSpinner } from \"./LoadingSpinner\";\n\nexport interface DeleteModalProps {\n entityName: string;\n onClose: () => void;\n onDelete: () => Promise<void>;\n}\n\nexport const DeleteModal = ({\n entityName,\n onClose,\n onDelete,\n}: DeleteModalProps) => {\n const [localEntityName] = useState(entityName);\n\n const deleteMutation = useMutation({\n mutationFn: onDelete,\n onSuccess: async () => {\n onClose();\n },\n });\n\n const deleteCallback = useCallback(() => {\n deleteMutation.mutate();\n }, [deleteMutation]);\n\n return (\n <>\n <Modal\n title='Confirm'\n modalRootId='grouping-mapping-widget'\n isOpen={!!localEntityName}\n isDismissible={!deleteMutation.isLoading}\n onClose={onClose}\n >\n <div className=\"gmw-delete-modal-body-text\">\n <Text variant=\"leading\" as=\"h3\">\n Are you sure you want to delete\n </Text>\n <strong>\n {<MiddleTextTruncation text={`${entityName}?`} />}\n </strong>\n </div>\n <ModalButtonBar>\n {deleteMutation.isLoading &&\n <div className=\"gmw-loading-delete\">\n <LoadingSpinner />\n </div>}\n <Button styleType='high-visibility' onClick={deleteCallback} disabled={deleteMutation.isLoading}>\n Delete\n </Button>\n <Button\n styleType='default'\n onClick={onClose}\n disabled={deleteMutation.isLoading}\n >\n Cancel\n </Button>\n </ModalButtonBar>\n </Modal>\n </>\n );\n};\n\nexport default DeleteModal;\n"]}
1
+ {"version":3,"file":"DeleteModal.js","sourceRoot":"","sources":["../../../../src/components/SharedComponents/DeleteModal.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,MAAM,EAAE,oBAAoB,EAAE,KAAK,EAAE,cAAc,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AACjG,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;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C,MAAM,IAAC,SAAS,EAAC,SAAS,EAAC,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,cAAc,CAAC,SAAS,aAEvE,CACM,CACX,CACP,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { Button, MiddleTextTruncation, Modal, ModalButtonBar, Text } from \"@itwin/itwinui-react\";\nimport { useMutation } from \"@tanstack/react-query\";\nimport React, { useCallback, useState } from \"react\";\nimport \"./DeleteModal.scss\";\nimport { LoadingSpinner } from \"./LoadingSpinner\";\n\nexport interface DeleteModalProps {\n entityName: string;\n onClose: () => void;\n onDelete: () => Promise<void>;\n}\n\nexport const DeleteModal = ({ entityName, onClose, onDelete }: DeleteModalProps) => {\n const [localEntityName] = useState(entityName);\n\n const deleteMutation = useMutation({\n mutationFn: onDelete,\n onSuccess: async () => {\n onClose();\n },\n });\n\n const deleteCallback = useCallback(() => {\n deleteMutation.mutate();\n }, [deleteMutation]);\n\n return (\n <>\n <Modal title=\"Confirm\" modalRootId=\"grouping-mapping-widget\" isOpen={!!localEntityName} isDismissible={!deleteMutation.isLoading} onClose={onClose}>\n <div className=\"gmw-delete-modal-body-text\">\n <Text variant=\"leading\" as=\"h3\">\n Are you sure you want to delete\n </Text>\n <strong>{<MiddleTextTruncation text={`${entityName}?`} />}</strong>\n </div>\n <ModalButtonBar>\n {deleteMutation.isLoading && (\n <div className=\"gmw-loading-delete\">\n <LoadingSpinner />\n </div>\n )}\n <Button styleType=\"high-visibility\" onClick={deleteCallback} disabled={deleteMutation.isLoading}>\n Delete\n </Button>\n <Button styleType=\"default\" onClick={onClose} disabled={deleteMutation.isLoading}>\n Cancel\n </Button>\n </ModalButtonBar>\n </Modal>\n </>\n );\n};\n\nexport default DeleteModal;\n"]}
@@ -1,10 +1,10 @@
1
1
  /*---------------------------------------------------------------------------------------------
2
- * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
- * See LICENSE.md in the project root for license terms and full copyright notice.
4
- *--------------------------------------------------------------------------------------------*/
2
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
3
+ * See LICENSE.md in the project root for license terms and full copyright notice.
4
+ *--------------------------------------------------------------------------------------------*/
5
5
  import { Text } from "@itwin/itwinui-react";
6
6
  import React from "react";
7
7
  import "./EmptyMessage.scss";
8
- export const EmptyMessage = ({ message }) => (React.createElement("div", { className: 'gmw-empty-message-center-overlay' },
8
+ export const EmptyMessage = ({ message }) => (React.createElement("div", { className: "gmw-empty-message-center-overlay" },
9
9
  React.createElement(Text, null, message)));
10
10
  //# sourceMappingURL=EmptyMessage.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"EmptyMessage.js","sourceRoot":"","sources":["../../../../src/components/SharedComponents/EmptyMessage.tsx"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,qBAAqB,CAAC;AAM7B,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAAE,OAAO,EAAqB,EAAE,EAAE,CAAC,CAC9D,6BAAK,SAAS,EAAC,kCAAkC;IAC/C,oBAAC,IAAI,QAAE,OAAO,CAAQ,CAClB,CACP,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n* See LICENSE.md in the project root for license terms and full copyright notice.\n*--------------------------------------------------------------------------------------------*/\nimport { Text } from \"@itwin/itwinui-react\";\nimport React from \"react\";\nimport \"./EmptyMessage.scss\";\n\nexport interface EmptyMessageProps {\n message: string;\n}\n\nexport const EmptyMessage = ({ message }: EmptyMessageProps) => (\n <div className='gmw-empty-message-center-overlay'>\n <Text>{message}</Text>\n </div>\n);\n"]}
1
+ {"version":3,"file":"EmptyMessage.js","sourceRoot":"","sources":["../../../../src/components/SharedComponents/EmptyMessage.tsx"],"names":[],"mappings":"AAAA;;;gGAGgG;AAChG,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,qBAAqB,CAAC;AAM7B,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAAE,OAAO,EAAqB,EAAE,EAAE,CAAC,CAC9D,6BAAK,SAAS,EAAC,kCAAkC;IAC/C,oBAAC,IAAI,QAAE,OAAO,CAAQ,CAClB,CACP,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { Text } from \"@itwin/itwinui-react\";\nimport React from \"react\";\nimport \"./EmptyMessage.scss\";\n\nexport interface EmptyMessageProps {\n message: string;\n}\n\nexport const EmptyMessage = ({ message }: EmptyMessageProps) => (\n <div className=\"gmw-empty-message-center-overlay\">\n <Text>{message}</Text>\n </div>\n);\n"]}