@itwin/components-react 4.1.0-dev.1 → 4.1.0

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 (441) hide show
  1. package/CHANGELOG.md +9 -1
  2. package/lib/cjs/components-react/UiComponents.js.map +1 -1
  3. package/lib/cjs/components-react/_target.scss +9 -9
  4. package/lib/cjs/components-react/common/DateUtils.js.map +1 -1
  5. package/lib/cjs/components-react/common/DelayedSpinner.js.map +1 -1
  6. package/lib/cjs/components-react/common/HighlightedText.js.map +1 -1
  7. package/lib/cjs/components-react/common/HighlightingComponentProps.js.map +1 -1
  8. package/lib/cjs/components-react/common/IImageLoader.js.map +1 -1
  9. package/lib/cjs/components-react/common/ImageRenderer.js.map +1 -1
  10. package/lib/cjs/components-react/common/Links.js.map +1 -1
  11. package/lib/cjs/components-react/common/PageOptions.js.map +1 -1
  12. package/lib/cjs/components-react/common/SubscriptionScheduler.js.map +1 -1
  13. package/lib/cjs/components-react/common/UseAsyncValue.js.map +1 -1
  14. package/lib/cjs/components-react/common/UseContextWithMandatoryProvider.js.map +1 -1
  15. package/lib/cjs/components-react/common/UseDebouncedAsyncValue.js.map +1 -1
  16. package/lib/cjs/components-react/common/UseRerender.js.map +1 -1
  17. package/lib/cjs/components-react/common/countMatchesInString.js.map +1 -1
  18. package/lib/cjs/components-react/common/selection/SelectionHandler.js.map +1 -1
  19. package/lib/cjs/components-react/common/selection/SelectionModes.js.map +1 -1
  20. package/lib/cjs/components-react/converters/BooleanTypeConverter.js.map +1 -1
  21. package/lib/cjs/components-react/converters/CompositeTypeConverter.js.map +1 -1
  22. package/lib/cjs/components-react/converters/DateTimeTypeConverter.js.map +1 -1
  23. package/lib/cjs/components-react/converters/EnumTypeConverter.js.map +1 -1
  24. package/lib/cjs/components-react/converters/HexadecimalTypeConverter.js.map +1 -1
  25. package/lib/cjs/components-react/converters/NavigationPropertyTypeConverter.js.map +1 -1
  26. package/lib/cjs/components-react/converters/NumericTypeConverter.js.map +1 -1
  27. package/lib/cjs/components-react/converters/PointTypeConverter.js.map +1 -1
  28. package/lib/cjs/components-react/converters/StringTypeConverter.js.map +1 -1
  29. package/lib/cjs/components-react/converters/TypeConverter.js.map +1 -1
  30. package/lib/cjs/components-react/converters/TypeConverterManager.js.map +1 -1
  31. package/lib/cjs/components-react/converters/valuetypes/ConvertedTypes.js.map +1 -1
  32. package/lib/cjs/components-react/datepicker/DateField.js.map +1 -1
  33. package/lib/cjs/components-react/datepicker/DateField.scss +22 -22
  34. package/lib/cjs/components-react/datepicker/DatePicker.js.map +1 -1
  35. package/lib/cjs/components-react/datepicker/DatePicker.scss +176 -176
  36. package/lib/cjs/components-react/datepicker/DatePickerPopupButton.js.map +1 -1
  37. package/lib/cjs/components-react/datepicker/DatePickerPopupButton.scss +57 -57
  38. package/lib/cjs/components-react/datepicker/IntlFormatter.js.map +1 -1
  39. package/lib/cjs/components-react/datepicker/TimeField.js.map +1 -1
  40. package/lib/cjs/components-react/datepicker/TimeField.scss +76 -76
  41. package/lib/cjs/components-react/editors/BooleanEditor.js.map +1 -1
  42. package/lib/cjs/components-react/editors/BooleanEditor.scss +22 -22
  43. package/lib/cjs/components-react/editors/CustomNumberEditor.js.map +1 -1
  44. package/lib/cjs/components-react/editors/CustomNumberEditor.scss +20 -20
  45. package/lib/cjs/components-react/editors/DateTimeEditor.js.map +1 -1
  46. package/lib/cjs/components-react/editors/DateTimeEditor.scss +9 -9
  47. package/lib/cjs/components-react/editors/EditorContainer.js.map +1 -1
  48. package/lib/cjs/components-react/editors/EditorContainer.scss +6 -6
  49. package/lib/cjs/components-react/editors/EnumButtonGroupEditor.js.map +1 -1
  50. package/lib/cjs/components-react/editors/EnumButtonGroupEditor.scss +141 -141
  51. package/lib/cjs/components-react/editors/EnumEditor.js.map +1 -1
  52. package/lib/cjs/components-react/editors/EnumEditor.scss +22 -22
  53. package/lib/cjs/components-react/editors/IconEditor.js.map +1 -1
  54. package/lib/cjs/components-react/editors/IconEditor.scss +16 -16
  55. package/lib/cjs/components-react/editors/ImageCheckBoxEditor.js.map +1 -1
  56. package/lib/cjs/components-react/editors/ImageCheckBoxEditor.scss +24 -24
  57. package/lib/cjs/components-react/editors/NumericInputEditor.js.map +1 -1
  58. package/lib/cjs/components-react/editors/NumericInputEditor.scss +16 -16
  59. package/lib/cjs/components-react/editors/PopupButton.js.map +1 -1
  60. package/lib/cjs/components-react/editors/PopupButton.scss +116 -116
  61. package/lib/cjs/components-react/editors/PropertyEditorManager.js.map +1 -1
  62. package/lib/cjs/components-react/editors/SliderEditor.js.map +1 -1
  63. package/lib/cjs/components-react/editors/SliderEditor.scss +13 -13
  64. package/lib/cjs/components-react/editors/TextEditor.js.map +1 -1
  65. package/lib/cjs/components-react/editors/TextEditor.scss +20 -20
  66. package/lib/cjs/components-react/editors/TextareaEditor.js.map +1 -1
  67. package/lib/cjs/components-react/editors/TextareaEditor.scss +14 -14
  68. package/lib/cjs/components-react/editors/ToggleEditor.js.map +1 -1
  69. package/lib/cjs/components-react/editors/ToggleEditor.scss +23 -23
  70. package/lib/cjs/components-react/editors/variables.scss +7 -7
  71. package/lib/cjs/components-react/favorite/FavoritePropertiesRenderer.js.map +1 -1
  72. package/lib/cjs/components-react/favorite/FavoritePropertyList.js.map +1 -1
  73. package/lib/cjs/components-react/filter-builder/FilterBuilder.js.map +1 -1
  74. package/lib/cjs/components-react/filter-builder/FilterBuilderContext.js.map +1 -1
  75. package/lib/cjs/components-react/filter-builder/FilterBuilderRule.js.map +1 -1
  76. package/lib/cjs/components-react/filter-builder/FilterBuilderRule.scss +38 -38
  77. package/lib/cjs/components-react/filter-builder/FilterBuilderRuleGroup.js.map +1 -1
  78. package/lib/cjs/components-react/filter-builder/FilterBuilderRuleGroup.scss +68 -68
  79. package/lib/cjs/components-react/filter-builder/FilterBuilderRuleOperator.js.map +1 -1
  80. package/lib/cjs/components-react/filter-builder/FilterBuilderRuleProperty.js.map +1 -1
  81. package/lib/cjs/components-react/filter-builder/FilterBuilderRuleValue.js.map +1 -1
  82. package/lib/cjs/components-react/filter-builder/FilterBuilderState.js.map +1 -1
  83. package/lib/cjs/components-react/filter-builder/Operators.js.map +1 -1
  84. package/lib/cjs/components-react/filter-builder/Types.js.map +1 -1
  85. package/lib/cjs/components-react/filtering/FilteringInput.js.map +1 -1
  86. package/lib/cjs/components-react/filtering/FilteringInput.scss +58 -58
  87. package/lib/cjs/components-react/filtering/ResultSelector.js.map +1 -1
  88. package/lib/cjs/components-react/filtering/ResultSelector.scss +68 -68
  89. package/lib/cjs/components-react/iconpicker/IconPickerButton.js.map +1 -1
  90. package/lib/cjs/components-react/iconpicker/IconPickerButton.scss +75 -75
  91. package/lib/cjs/components-react/inputs/ParsedInput.js.map +1 -1
  92. package/lib/cjs/components-react/inputs/ParsedInput.scss +23 -23
  93. package/lib/cjs/components-react/properties/ItemStyle.js.map +1 -1
  94. package/lib/cjs/components-react/properties/LinkHandler.js.map +1 -1
  95. package/lib/cjs/components-react/properties/ValueRendererManager.js.map +1 -1
  96. package/lib/cjs/components-react/properties/renderers/ActionButtonList.js.map +1 -1
  97. package/lib/cjs/components-react/properties/renderers/ActionButtonList.scss +25 -25
  98. package/lib/cjs/components-react/properties/renderers/ActionButtonRenderer.js.map +1 -1
  99. package/lib/cjs/components-react/properties/renderers/CommonPropertyRenderer.js.map +1 -1
  100. package/lib/cjs/components-react/properties/renderers/NonPrimitivePropertyRenderer.js.map +1 -1
  101. package/lib/cjs/components-react/properties/renderers/NonPrimitivePropertyRenderer.scss +17 -17
  102. package/lib/cjs/components-react/properties/renderers/PrimitivePropertyRenderer.js.map +1 -1
  103. package/lib/cjs/components-react/properties/renderers/PropertyGridColumns.js.map +1 -1
  104. package/lib/cjs/components-react/properties/renderers/PropertyRenderer.js.map +1 -1
  105. package/lib/cjs/components-react/properties/renderers/PropertyView.js.map +1 -1
  106. package/lib/cjs/components-react/properties/renderers/PropertyView.scss +111 -111
  107. package/lib/cjs/components-react/properties/renderers/label/NonPrimitivePropertyLabelRenderer.js.map +1 -1
  108. package/lib/cjs/components-react/properties/renderers/label/PrimitivePropertyLabelRenderer.js.map +1 -1
  109. package/lib/cjs/components-react/properties/renderers/label/PropertyLabelRenderer.js.map +1 -1
  110. package/lib/cjs/components-react/properties/renderers/label/PropertyLabelRenderer.scss +88 -88
  111. package/lib/cjs/components-react/properties/renderers/value/ArrayPropertyValueRenderer.js.map +1 -1
  112. package/lib/cjs/components-react/properties/renderers/value/DoublePropertyValueRenderer.js.map +1 -1
  113. package/lib/cjs/components-react/properties/renderers/value/MergedPropertyValueRenderer.js.map +1 -1
  114. package/lib/cjs/components-react/properties/renderers/value/MultilineTextPropertyValueRenderer.js.map +1 -1
  115. package/lib/cjs/components-react/properties/renderers/value/NavigationPropertyValueRenderer.js.map +1 -1
  116. package/lib/cjs/components-react/properties/renderers/value/PrimitivePropertyValueRenderer.js.map +1 -1
  117. package/lib/cjs/components-react/properties/renderers/value/StructPropertyValueRenderer.js.map +1 -1
  118. package/lib/cjs/components-react/properties/renderers/value/UrlPropertyValueRenderer.js.map +1 -1
  119. package/lib/cjs/components-react/properties/renderers/value/WithContextStyle.js.map +1 -1
  120. package/lib/cjs/components-react/properties/renderers/value/table/ArrayValueRenderer.js.map +1 -1
  121. package/lib/cjs/components-react/properties/renderers/value/table/NonPrimitiveValueRenderer.js.map +1 -1
  122. package/lib/cjs/components-react/properties/renderers/value/table/StructValueRenderer.js.map +1 -1
  123. package/lib/cjs/components-react/propertygrid/PropertyCategoryRendererManager.js.map +1 -1
  124. package/lib/cjs/components-react/propertygrid/PropertyDataProvider.js.map +1 -1
  125. package/lib/cjs/components-react/propertygrid/SimplePropertyDataProvider.js.map +1 -1
  126. package/lib/cjs/components-react/propertygrid/component/ColumnResizingPropertyListPropsSupplier.js.map +1 -1
  127. package/lib/cjs/components-react/propertygrid/component/FlatItemNestedBorderWrapper.js.map +1 -1
  128. package/lib/cjs/components-react/propertygrid/component/PropertyCategoryBlock.js.map +1 -1
  129. package/lib/cjs/components-react/propertygrid/component/PropertyGrid.scss +73 -73
  130. package/lib/cjs/components-react/propertygrid/component/PropertyGridCommons.js.map +1 -1
  131. package/lib/cjs/components-react/propertygrid/component/PropertyGridEventsRelatedPropsSupplier.js.map +1 -1
  132. package/lib/cjs/components-react/propertygrid/component/PropertyList.js.map +1 -1
  133. package/lib/cjs/components-react/propertygrid/component/VirtualizedPropertyGrid.js.map +1 -1
  134. package/lib/cjs/components-react/propertygrid/component/VirtualizedPropertyGrid.scss +101 -101
  135. package/lib/cjs/components-react/propertygrid/component/VirtualizedPropertyGridWithDataProvider.js.map +1 -1
  136. package/lib/cjs/components-react/propertygrid/dataproviders/FilteringDataProvider.js.map +1 -1
  137. package/lib/cjs/components-react/propertygrid/dataproviders/filterers/CompositePropertyDataFilterer.js.map +1 -1
  138. package/lib/cjs/components-react/propertygrid/dataproviders/filterers/DisplayValuePropertyDataFilterer.js.map +1 -1
  139. package/lib/cjs/components-react/propertygrid/dataproviders/filterers/LabelPropertyDataFilterer.js.map +1 -1
  140. package/lib/cjs/components-react/propertygrid/dataproviders/filterers/PropertyCategoryLabelFilterer.js.map +1 -1
  141. package/lib/cjs/components-react/propertygrid/dataproviders/filterers/PropertyDataFiltererBase.js.map +1 -1
  142. package/lib/cjs/components-react/propertygrid/internal/PropertyGridEventHandler.js.map +1 -1
  143. package/lib/cjs/components-react/propertygrid/internal/PropertyGridHooks.js.map +1 -1
  144. package/lib/cjs/components-react/propertygrid/internal/PropertyGridModel.js.map +1 -1
  145. package/lib/cjs/components-react/propertygrid/internal/PropertyGridModelChangeEvent.js.map +1 -1
  146. package/lib/cjs/components-react/propertygrid/internal/PropertyGridModelSource.js.map +1 -1
  147. package/lib/cjs/components-react/propertygrid/internal/flat-items/FlatGridItem.js.map +1 -1
  148. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableCategorizedArrayProperty.js.map +1 -1
  149. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableCategorizedPrimitiveProperty.js.map +1 -1
  150. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableCategorizedStructProperty.js.map +1 -1
  151. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableCustomGridCategory.js.map +1 -1
  152. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableFlatGridItem.js.map +1 -1
  153. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableGridCategory.js.map +1 -1
  154. package/lib/cjs/components-react/propertygrid/internal/flat-items/MutableGridItemFactory.js.map +1 -1
  155. package/lib/cjs/components-react/propertygrid/internal/flat-properties/FlatNonPrimitivePropertyRenderer.js.map +1 -1
  156. package/lib/cjs/components-react/propertygrid/internal/flat-properties/FlatPropertyRenderer.js.map +1 -1
  157. package/lib/cjs/components-react/selectable-content/SelectableContent.js.map +1 -1
  158. package/lib/cjs/components-react/selectable-content/SelectableContent.scss +20 -20
  159. package/lib/cjs/components-react/toolbar/Item.js.map +1 -1
  160. package/lib/cjs/components-react/toolbar/Item.scss +91 -91
  161. package/lib/cjs/components-react/toolbar/ItemWrapper.js.map +1 -1
  162. package/lib/cjs/components-react/toolbar/ItemWrapper.scss +10 -10
  163. package/lib/cjs/components-react/toolbar/Items.js.map +1 -1
  164. package/lib/cjs/components-react/toolbar/Items.scss +96 -96
  165. package/lib/cjs/components-react/toolbar/Overflow.js.map +1 -1
  166. package/lib/cjs/components-react/toolbar/Overflow.scss +57 -57
  167. package/lib/cjs/components-react/toolbar/OverflowPanel.js.map +1 -1
  168. package/lib/cjs/components-react/toolbar/OverflowPanel.scss +37 -37
  169. package/lib/cjs/components-react/toolbar/PopupItem.js.map +1 -1
  170. package/lib/cjs/components-react/toolbar/PopupItem.scss +88 -88
  171. package/lib/cjs/components-react/toolbar/PopupItemWithDrag.js.map +1 -1
  172. package/lib/cjs/components-react/toolbar/PopupItemsPanel.js.map +1 -1
  173. package/lib/cjs/components-react/toolbar/Toolbar.js.map +1 -1
  174. package/lib/cjs/components-react/toolbar/Toolbar.scss +18 -18
  175. package/lib/cjs/components-react/toolbar/ToolbarWithOverflow.js.map +1 -1
  176. package/lib/cjs/components-react/toolbar/_variables.scss +34 -34
  177. package/lib/cjs/components-react/toolbar/groupPanel/BackArrow.js.map +1 -1
  178. package/lib/cjs/components-react/toolbar/groupPanel/BackArrow.scss +44 -44
  179. package/lib/cjs/components-react/toolbar/groupPanel/Column.js.map +1 -1
  180. package/lib/cjs/components-react/toolbar/groupPanel/Column.scss +9 -9
  181. package/lib/cjs/components-react/toolbar/groupPanel/Columns.js.map +1 -1
  182. package/lib/cjs/components-react/toolbar/groupPanel/Columns.scss +10 -10
  183. package/lib/cjs/components-react/toolbar/groupPanel/Panel.js.map +1 -1
  184. package/lib/cjs/components-react/toolbar/groupPanel/Panel.scss +15 -15
  185. package/lib/cjs/components-react/toolbar/groupPanel/Title.js.map +1 -1
  186. package/lib/cjs/components-react/toolbar/groupPanel/Title.scss +33 -33
  187. package/lib/cjs/components-react/toolbar/groupPanel/_variables.scss +16 -16
  188. package/lib/cjs/components-react/toolbar/groupPanel/tool/Expander.js.map +1 -1
  189. package/lib/cjs/components-react/toolbar/groupPanel/tool/Expander.scss +29 -29
  190. package/lib/cjs/components-react/toolbar/groupPanel/tool/Tool.js.map +1 -1
  191. package/lib/cjs/components-react/toolbar/groupPanel/tool/Tool.scss +117 -117
  192. package/lib/cjs/components-react/toolbar/groupPanel/tool/_variables.scss +12 -12
  193. package/lib/cjs/components-react/toolbar/useDragInteraction.js.map +1 -1
  194. package/lib/cjs/components-react/toolbar/utilities/Direction.js.map +1 -1
  195. package/lib/cjs/components-react/tree/HighlightingEngine.js.map +1 -1
  196. package/lib/cjs/components-react/tree/HighlightingEngine.scss +7 -7
  197. package/lib/cjs/components-react/tree/ImageLoader.js.map +1 -1
  198. package/lib/cjs/components-react/tree/SimpleTreeDataProvider.js.map +1 -1
  199. package/lib/cjs/components-react/tree/TreeComponentTestId.js.map +1 -1
  200. package/lib/cjs/components-react/tree/TreeDataProvider.js.map +1 -1
  201. package/lib/cjs/components-react/tree/controlled/Observable.js.map +1 -1
  202. package/lib/cjs/components-react/tree/controlled/TreeActions.js.map +1 -1
  203. package/lib/cjs/components-react/tree/controlled/TreeEventDispatcher.js.map +1 -1
  204. package/lib/cjs/components-react/tree/controlled/TreeEventHandler.js.map +1 -1
  205. package/lib/cjs/components-react/tree/controlled/TreeEvents.js.map +1 -1
  206. package/lib/cjs/components-react/tree/controlled/TreeHooks.js.map +1 -1
  207. package/lib/cjs/components-react/tree/controlled/TreeModel.js.map +1 -1
  208. package/lib/cjs/components-react/tree/controlled/TreeModelSource.js.map +1 -1
  209. package/lib/cjs/components-react/tree/controlled/TreeNodeLoader.js.map +1 -1
  210. package/lib/cjs/components-react/tree/controlled/component/ControlledTree.js.map +1 -1
  211. package/lib/cjs/components-react/tree/controlled/component/ControlledTree.scss +102 -102
  212. package/lib/cjs/components-react/tree/controlled/component/NodeContent.js.map +1 -1
  213. package/lib/cjs/components-react/tree/controlled/component/NodeContent.scss +27 -27
  214. package/lib/cjs/components-react/tree/controlled/component/TreeNodeEditor.js.map +1 -1
  215. package/lib/cjs/components-react/tree/controlled/component/TreeNodeRenderer.js.map +1 -1
  216. package/lib/cjs/components-react/tree/controlled/component/TreeRenderer.js.map +1 -1
  217. package/lib/cjs/components-react/tree/controlled/internal/SparseTree.js.map +1 -1
  218. package/lib/cjs/components-react/tree/controlled/internal/TreeModelMutator.js.map +1 -1
  219. package/lib/cjs/components-react/tree/controlled/internal/TreeSelectionManager.js.map +1 -1
  220. package/lib/cjs/components-react.js.map +1 -1
  221. package/lib/esm/components-react/UiComponents.js.map +1 -1
  222. package/lib/esm/components-react/_target.scss +9 -9
  223. package/lib/esm/components-react/common/DateUtils.js.map +1 -1
  224. package/lib/esm/components-react/common/DelayedSpinner.js.map +1 -1
  225. package/lib/esm/components-react/common/HighlightedText.js.map +1 -1
  226. package/lib/esm/components-react/common/HighlightingComponentProps.js.map +1 -1
  227. package/lib/esm/components-react/common/IImageLoader.js.map +1 -1
  228. package/lib/esm/components-react/common/ImageRenderer.js.map +1 -1
  229. package/lib/esm/components-react/common/Links.js.map +1 -1
  230. package/lib/esm/components-react/common/PageOptions.js.map +1 -1
  231. package/lib/esm/components-react/common/SubscriptionScheduler.js.map +1 -1
  232. package/lib/esm/components-react/common/UseAsyncValue.js.map +1 -1
  233. package/lib/esm/components-react/common/UseContextWithMandatoryProvider.js.map +1 -1
  234. package/lib/esm/components-react/common/UseDebouncedAsyncValue.js.map +1 -1
  235. package/lib/esm/components-react/common/UseRerender.js.map +1 -1
  236. package/lib/esm/components-react/common/countMatchesInString.js.map +1 -1
  237. package/lib/esm/components-react/common/selection/SelectionHandler.js.map +1 -1
  238. package/lib/esm/components-react/common/selection/SelectionModes.js.map +1 -1
  239. package/lib/esm/components-react/converters/BooleanTypeConverter.js.map +1 -1
  240. package/lib/esm/components-react/converters/CompositeTypeConverter.js.map +1 -1
  241. package/lib/esm/components-react/converters/DateTimeTypeConverter.js.map +1 -1
  242. package/lib/esm/components-react/converters/EnumTypeConverter.js.map +1 -1
  243. package/lib/esm/components-react/converters/HexadecimalTypeConverter.js.map +1 -1
  244. package/lib/esm/components-react/converters/NavigationPropertyTypeConverter.js.map +1 -1
  245. package/lib/esm/components-react/converters/NumericTypeConverter.js.map +1 -1
  246. package/lib/esm/components-react/converters/PointTypeConverter.js.map +1 -1
  247. package/lib/esm/components-react/converters/StringTypeConverter.js.map +1 -1
  248. package/lib/esm/components-react/converters/TypeConverter.js.map +1 -1
  249. package/lib/esm/components-react/converters/TypeConverterManager.js.map +1 -1
  250. package/lib/esm/components-react/converters/valuetypes/ConvertedTypes.js.map +1 -1
  251. package/lib/esm/components-react/datepicker/DateField.js.map +1 -1
  252. package/lib/esm/components-react/datepicker/DateField.scss +22 -22
  253. package/lib/esm/components-react/datepicker/DatePicker.js.map +1 -1
  254. package/lib/esm/components-react/datepicker/DatePicker.scss +176 -176
  255. package/lib/esm/components-react/datepicker/DatePickerPopupButton.js.map +1 -1
  256. package/lib/esm/components-react/datepicker/DatePickerPopupButton.scss +57 -57
  257. package/lib/esm/components-react/datepicker/IntlFormatter.js.map +1 -1
  258. package/lib/esm/components-react/datepicker/TimeField.js.map +1 -1
  259. package/lib/esm/components-react/datepicker/TimeField.scss +76 -76
  260. package/lib/esm/components-react/editors/BooleanEditor.js.map +1 -1
  261. package/lib/esm/components-react/editors/BooleanEditor.scss +22 -22
  262. package/lib/esm/components-react/editors/CustomNumberEditor.js.map +1 -1
  263. package/lib/esm/components-react/editors/CustomNumberEditor.scss +20 -20
  264. package/lib/esm/components-react/editors/DateTimeEditor.js.map +1 -1
  265. package/lib/esm/components-react/editors/DateTimeEditor.scss +9 -9
  266. package/lib/esm/components-react/editors/EditorContainer.js.map +1 -1
  267. package/lib/esm/components-react/editors/EditorContainer.scss +6 -6
  268. package/lib/esm/components-react/editors/EnumButtonGroupEditor.js.map +1 -1
  269. package/lib/esm/components-react/editors/EnumButtonGroupEditor.scss +141 -141
  270. package/lib/esm/components-react/editors/EnumEditor.js.map +1 -1
  271. package/lib/esm/components-react/editors/EnumEditor.scss +22 -22
  272. package/lib/esm/components-react/editors/IconEditor.js.map +1 -1
  273. package/lib/esm/components-react/editors/IconEditor.scss +16 -16
  274. package/lib/esm/components-react/editors/ImageCheckBoxEditor.js.map +1 -1
  275. package/lib/esm/components-react/editors/ImageCheckBoxEditor.scss +24 -24
  276. package/lib/esm/components-react/editors/NumericInputEditor.js.map +1 -1
  277. package/lib/esm/components-react/editors/NumericInputEditor.scss +16 -16
  278. package/lib/esm/components-react/editors/PopupButton.js.map +1 -1
  279. package/lib/esm/components-react/editors/PopupButton.scss +116 -116
  280. package/lib/esm/components-react/editors/PropertyEditorManager.js.map +1 -1
  281. package/lib/esm/components-react/editors/SliderEditor.js.map +1 -1
  282. package/lib/esm/components-react/editors/SliderEditor.scss +13 -13
  283. package/lib/esm/components-react/editors/TextEditor.js.map +1 -1
  284. package/lib/esm/components-react/editors/TextEditor.scss +20 -20
  285. package/lib/esm/components-react/editors/TextareaEditor.js.map +1 -1
  286. package/lib/esm/components-react/editors/TextareaEditor.scss +14 -14
  287. package/lib/esm/components-react/editors/ToggleEditor.js.map +1 -1
  288. package/lib/esm/components-react/editors/ToggleEditor.scss +23 -23
  289. package/lib/esm/components-react/editors/variables.scss +7 -7
  290. package/lib/esm/components-react/favorite/FavoritePropertiesRenderer.js.map +1 -1
  291. package/lib/esm/components-react/favorite/FavoritePropertyList.js.map +1 -1
  292. package/lib/esm/components-react/filter-builder/FilterBuilder.js.map +1 -1
  293. package/lib/esm/components-react/filter-builder/FilterBuilderContext.js.map +1 -1
  294. package/lib/esm/components-react/filter-builder/FilterBuilderRule.js.map +1 -1
  295. package/lib/esm/components-react/filter-builder/FilterBuilderRule.scss +38 -38
  296. package/lib/esm/components-react/filter-builder/FilterBuilderRuleGroup.js.map +1 -1
  297. package/lib/esm/components-react/filter-builder/FilterBuilderRuleGroup.scss +68 -68
  298. package/lib/esm/components-react/filter-builder/FilterBuilderRuleOperator.js.map +1 -1
  299. package/lib/esm/components-react/filter-builder/FilterBuilderRuleProperty.js.map +1 -1
  300. package/lib/esm/components-react/filter-builder/FilterBuilderRuleValue.js.map +1 -1
  301. package/lib/esm/components-react/filter-builder/FilterBuilderState.js.map +1 -1
  302. package/lib/esm/components-react/filter-builder/Operators.js.map +1 -1
  303. package/lib/esm/components-react/filter-builder/Types.js.map +1 -1
  304. package/lib/esm/components-react/filtering/FilteringInput.js.map +1 -1
  305. package/lib/esm/components-react/filtering/FilteringInput.scss +58 -58
  306. package/lib/esm/components-react/filtering/ResultSelector.js.map +1 -1
  307. package/lib/esm/components-react/filtering/ResultSelector.scss +68 -68
  308. package/lib/esm/components-react/iconpicker/IconPickerButton.js.map +1 -1
  309. package/lib/esm/components-react/iconpicker/IconPickerButton.scss +75 -75
  310. package/lib/esm/components-react/inputs/ParsedInput.js.map +1 -1
  311. package/lib/esm/components-react/inputs/ParsedInput.scss +23 -23
  312. package/lib/esm/components-react/properties/ItemStyle.js.map +1 -1
  313. package/lib/esm/components-react/properties/LinkHandler.js.map +1 -1
  314. package/lib/esm/components-react/properties/ValueRendererManager.js.map +1 -1
  315. package/lib/esm/components-react/properties/renderers/ActionButtonList.js.map +1 -1
  316. package/lib/esm/components-react/properties/renderers/ActionButtonList.scss +25 -25
  317. package/lib/esm/components-react/properties/renderers/ActionButtonRenderer.js.map +1 -1
  318. package/lib/esm/components-react/properties/renderers/CommonPropertyRenderer.js.map +1 -1
  319. package/lib/esm/components-react/properties/renderers/NonPrimitivePropertyRenderer.js.map +1 -1
  320. package/lib/esm/components-react/properties/renderers/NonPrimitivePropertyRenderer.scss +17 -17
  321. package/lib/esm/components-react/properties/renderers/PrimitivePropertyRenderer.js.map +1 -1
  322. package/lib/esm/components-react/properties/renderers/PropertyGridColumns.js.map +1 -1
  323. package/lib/esm/components-react/properties/renderers/PropertyRenderer.js.map +1 -1
  324. package/lib/esm/components-react/properties/renderers/PropertyView.js.map +1 -1
  325. package/lib/esm/components-react/properties/renderers/PropertyView.scss +111 -111
  326. package/lib/esm/components-react/properties/renderers/label/NonPrimitivePropertyLabelRenderer.js.map +1 -1
  327. package/lib/esm/components-react/properties/renderers/label/PrimitivePropertyLabelRenderer.js.map +1 -1
  328. package/lib/esm/components-react/properties/renderers/label/PropertyLabelRenderer.js.map +1 -1
  329. package/lib/esm/components-react/properties/renderers/label/PropertyLabelRenderer.scss +88 -88
  330. package/lib/esm/components-react/properties/renderers/value/ArrayPropertyValueRenderer.js.map +1 -1
  331. package/lib/esm/components-react/properties/renderers/value/DoublePropertyValueRenderer.js.map +1 -1
  332. package/lib/esm/components-react/properties/renderers/value/MergedPropertyValueRenderer.js.map +1 -1
  333. package/lib/esm/components-react/properties/renderers/value/MultilineTextPropertyValueRenderer.js.map +1 -1
  334. package/lib/esm/components-react/properties/renderers/value/NavigationPropertyValueRenderer.js.map +1 -1
  335. package/lib/esm/components-react/properties/renderers/value/PrimitivePropertyValueRenderer.js.map +1 -1
  336. package/lib/esm/components-react/properties/renderers/value/StructPropertyValueRenderer.js.map +1 -1
  337. package/lib/esm/components-react/properties/renderers/value/UrlPropertyValueRenderer.js.map +1 -1
  338. package/lib/esm/components-react/properties/renderers/value/WithContextStyle.js.map +1 -1
  339. package/lib/esm/components-react/properties/renderers/value/table/ArrayValueRenderer.js.map +1 -1
  340. package/lib/esm/components-react/properties/renderers/value/table/NonPrimitiveValueRenderer.js.map +1 -1
  341. package/lib/esm/components-react/properties/renderers/value/table/StructValueRenderer.js.map +1 -1
  342. package/lib/esm/components-react/propertygrid/PropertyCategoryRendererManager.js.map +1 -1
  343. package/lib/esm/components-react/propertygrid/PropertyDataProvider.js.map +1 -1
  344. package/lib/esm/components-react/propertygrid/SimplePropertyDataProvider.js.map +1 -1
  345. package/lib/esm/components-react/propertygrid/component/ColumnResizingPropertyListPropsSupplier.js.map +1 -1
  346. package/lib/esm/components-react/propertygrid/component/FlatItemNestedBorderWrapper.js.map +1 -1
  347. package/lib/esm/components-react/propertygrid/component/PropertyCategoryBlock.js.map +1 -1
  348. package/lib/esm/components-react/propertygrid/component/PropertyGrid.scss +73 -73
  349. package/lib/esm/components-react/propertygrid/component/PropertyGridCommons.js.map +1 -1
  350. package/lib/esm/components-react/propertygrid/component/PropertyGridEventsRelatedPropsSupplier.js.map +1 -1
  351. package/lib/esm/components-react/propertygrid/component/PropertyList.js.map +1 -1
  352. package/lib/esm/components-react/propertygrid/component/VirtualizedPropertyGrid.js.map +1 -1
  353. package/lib/esm/components-react/propertygrid/component/VirtualizedPropertyGrid.scss +101 -101
  354. package/lib/esm/components-react/propertygrid/component/VirtualizedPropertyGridWithDataProvider.js.map +1 -1
  355. package/lib/esm/components-react/propertygrid/dataproviders/FilteringDataProvider.js.map +1 -1
  356. package/lib/esm/components-react/propertygrid/dataproviders/filterers/CompositePropertyDataFilterer.js.map +1 -1
  357. package/lib/esm/components-react/propertygrid/dataproviders/filterers/DisplayValuePropertyDataFilterer.js.map +1 -1
  358. package/lib/esm/components-react/propertygrid/dataproviders/filterers/LabelPropertyDataFilterer.js.map +1 -1
  359. package/lib/esm/components-react/propertygrid/dataproviders/filterers/PropertyCategoryLabelFilterer.js.map +1 -1
  360. package/lib/esm/components-react/propertygrid/dataproviders/filterers/PropertyDataFiltererBase.js.map +1 -1
  361. package/lib/esm/components-react/propertygrid/internal/PropertyGridEventHandler.js.map +1 -1
  362. package/lib/esm/components-react/propertygrid/internal/PropertyGridHooks.js.map +1 -1
  363. package/lib/esm/components-react/propertygrid/internal/PropertyGridModel.js.map +1 -1
  364. package/lib/esm/components-react/propertygrid/internal/PropertyGridModelChangeEvent.js.map +1 -1
  365. package/lib/esm/components-react/propertygrid/internal/PropertyGridModelSource.js.map +1 -1
  366. package/lib/esm/components-react/propertygrid/internal/flat-items/FlatGridItem.js.map +1 -1
  367. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableCategorizedArrayProperty.js.map +1 -1
  368. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableCategorizedPrimitiveProperty.js.map +1 -1
  369. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableCategorizedStructProperty.js.map +1 -1
  370. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableCustomGridCategory.js.map +1 -1
  371. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableFlatGridItem.js.map +1 -1
  372. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableGridCategory.js.map +1 -1
  373. package/lib/esm/components-react/propertygrid/internal/flat-items/MutableGridItemFactory.js.map +1 -1
  374. package/lib/esm/components-react/propertygrid/internal/flat-properties/FlatNonPrimitivePropertyRenderer.js.map +1 -1
  375. package/lib/esm/components-react/propertygrid/internal/flat-properties/FlatPropertyRenderer.js.map +1 -1
  376. package/lib/esm/components-react/selectable-content/SelectableContent.js.map +1 -1
  377. package/lib/esm/components-react/selectable-content/SelectableContent.scss +20 -20
  378. package/lib/esm/components-react/toolbar/Item.js.map +1 -1
  379. package/lib/esm/components-react/toolbar/Item.scss +91 -91
  380. package/lib/esm/components-react/toolbar/ItemWrapper.js.map +1 -1
  381. package/lib/esm/components-react/toolbar/ItemWrapper.scss +10 -10
  382. package/lib/esm/components-react/toolbar/Items.js.map +1 -1
  383. package/lib/esm/components-react/toolbar/Items.scss +96 -96
  384. package/lib/esm/components-react/toolbar/Overflow.js.map +1 -1
  385. package/lib/esm/components-react/toolbar/Overflow.scss +57 -57
  386. package/lib/esm/components-react/toolbar/OverflowPanel.js.map +1 -1
  387. package/lib/esm/components-react/toolbar/OverflowPanel.scss +37 -37
  388. package/lib/esm/components-react/toolbar/PopupItem.js.map +1 -1
  389. package/lib/esm/components-react/toolbar/PopupItem.scss +88 -88
  390. package/lib/esm/components-react/toolbar/PopupItemWithDrag.js.map +1 -1
  391. package/lib/esm/components-react/toolbar/PopupItemsPanel.js.map +1 -1
  392. package/lib/esm/components-react/toolbar/Toolbar.js.map +1 -1
  393. package/lib/esm/components-react/toolbar/Toolbar.scss +18 -18
  394. package/lib/esm/components-react/toolbar/ToolbarWithOverflow.js.map +1 -1
  395. package/lib/esm/components-react/toolbar/_variables.scss +34 -34
  396. package/lib/esm/components-react/toolbar/groupPanel/BackArrow.js.map +1 -1
  397. package/lib/esm/components-react/toolbar/groupPanel/BackArrow.scss +44 -44
  398. package/lib/esm/components-react/toolbar/groupPanel/Column.js.map +1 -1
  399. package/lib/esm/components-react/toolbar/groupPanel/Column.scss +9 -9
  400. package/lib/esm/components-react/toolbar/groupPanel/Columns.js.map +1 -1
  401. package/lib/esm/components-react/toolbar/groupPanel/Columns.scss +10 -10
  402. package/lib/esm/components-react/toolbar/groupPanel/Panel.js.map +1 -1
  403. package/lib/esm/components-react/toolbar/groupPanel/Panel.scss +15 -15
  404. package/lib/esm/components-react/toolbar/groupPanel/Title.js.map +1 -1
  405. package/lib/esm/components-react/toolbar/groupPanel/Title.scss +33 -33
  406. package/lib/esm/components-react/toolbar/groupPanel/_variables.scss +16 -16
  407. package/lib/esm/components-react/toolbar/groupPanel/tool/Expander.js.map +1 -1
  408. package/lib/esm/components-react/toolbar/groupPanel/tool/Expander.scss +29 -29
  409. package/lib/esm/components-react/toolbar/groupPanel/tool/Tool.js.map +1 -1
  410. package/lib/esm/components-react/toolbar/groupPanel/tool/Tool.scss +117 -117
  411. package/lib/esm/components-react/toolbar/groupPanel/tool/_variables.scss +12 -12
  412. package/lib/esm/components-react/toolbar/useDragInteraction.js.map +1 -1
  413. package/lib/esm/components-react/toolbar/utilities/Direction.js.map +1 -1
  414. package/lib/esm/components-react/tree/HighlightingEngine.js.map +1 -1
  415. package/lib/esm/components-react/tree/HighlightingEngine.scss +7 -7
  416. package/lib/esm/components-react/tree/ImageLoader.js.map +1 -1
  417. package/lib/esm/components-react/tree/SimpleTreeDataProvider.js.map +1 -1
  418. package/lib/esm/components-react/tree/TreeComponentTestId.js.map +1 -1
  419. package/lib/esm/components-react/tree/TreeDataProvider.js.map +1 -1
  420. package/lib/esm/components-react/tree/controlled/Observable.js.map +1 -1
  421. package/lib/esm/components-react/tree/controlled/TreeActions.js.map +1 -1
  422. package/lib/esm/components-react/tree/controlled/TreeEventDispatcher.js.map +1 -1
  423. package/lib/esm/components-react/tree/controlled/TreeEventHandler.js.map +1 -1
  424. package/lib/esm/components-react/tree/controlled/TreeEvents.js.map +1 -1
  425. package/lib/esm/components-react/tree/controlled/TreeHooks.js.map +1 -1
  426. package/lib/esm/components-react/tree/controlled/TreeModel.js.map +1 -1
  427. package/lib/esm/components-react/tree/controlled/TreeModelSource.js.map +1 -1
  428. package/lib/esm/components-react/tree/controlled/TreeNodeLoader.js.map +1 -1
  429. package/lib/esm/components-react/tree/controlled/component/ControlledTree.js.map +1 -1
  430. package/lib/esm/components-react/tree/controlled/component/ControlledTree.scss +102 -102
  431. package/lib/esm/components-react/tree/controlled/component/NodeContent.js.map +1 -1
  432. package/lib/esm/components-react/tree/controlled/component/NodeContent.scss +27 -27
  433. package/lib/esm/components-react/tree/controlled/component/TreeNodeEditor.js.map +1 -1
  434. package/lib/esm/components-react/tree/controlled/component/TreeNodeRenderer.js.map +1 -1
  435. package/lib/esm/components-react/tree/controlled/component/TreeRenderer.js.map +1 -1
  436. package/lib/esm/components-react/tree/controlled/internal/SparseTree.js.map +1 -1
  437. package/lib/esm/components-react/tree/controlled/internal/TreeModelMutator.js.map +1 -1
  438. package/lib/esm/components-react/tree/controlled/internal/TreeSelectionManager.js.map +1 -1
  439. package/lib/esm/components-react.js.map +1 -1
  440. package/lib/public/locales/en/UiComponents.json +139 -139
  441. package/package.json +3 -3
@@ -1 +1 @@
1
- {"version":3,"file":"VirtualizedPropertyGrid.js","sourceRoot":"","sources":["../../../../../src/components-react/propertygrid/component/VirtualizedPropertyGrid.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAE/F;;GAEG;AACH,0CAAwC;AACxC,4DAAoC;AACpC,6CAA+B;AAE/B,+CAA0D;AAE1D,sDAA6C;AAE7C,kDAAgD;AAChD,kGAAkG;AAKlG,kGAAmF;AAEnF,oHAAiH;AACjH,gGAA6F;AAC7F,oFAA8E;AAC9E,oFAAiF;AACjF,2FAAwF;AAIxF,wFAAqF;AAErF,uGAAoG;AACpG,+EAA4E;AAC5E,mEAAgE;AAEhE,+DAA4D;AAC5D,qGAAkG;AAyFlG,MAAM,CACJ,mCAAmC,EACnC,oCAAoC,EACpC,8BAA8B,EAC/B,GAAG,IAAA,oEAAkC,EAA8B,6BAA6B,CAAC,CAAC;AAEnG;;;GAGG;AACH,MAAa,uBAAwB,SAAQ,KAAK,CAAC,SAAqE;IAGtH,gBAAgB;IAChB,YAAY,KAAmC;;QAC7C,KAAK,CAAC,KAAK,CAAC,CAAC;QAJP,aAAQ,GAAG,KAAK,CAAC,SAAS,EAAoB,CAAC;QA6G/C,4BAAuB,GAAG,CAAC,KAAa,EAAE,GAAW,EAAE,SAAiB,EAAE,EAAE;YAClF,IAAI,IAAI,CAAC,KAAK,CAAC,kBAAkB,CAAC,GAAG,CAAC,GAAG,CAAC,KAAK,SAAS,EAAE;gBACxD,OAA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AAC,WAAW,EAAE,eAAe,CAAC,CACjD,CAAC;IAEF,OAAO,CACL,6BAAK,GAAG,EAAE,MAAM,IACb,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,QAAQ,EAAE,KAAK,CAAC,CACvC,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*--------------------------------------------------------------------------------------------*/\n\n/** @packageDocumentation\n * @module PropertyGrid\n */\nimport \"./VirtualizedPropertyGrid.scss\";\nimport classnames from \"classnames\";\nimport * as React from \"react\";\nimport type { ListChildComponentProps} from \"react-window\";\nimport { areEqual, VariableSizeList } from \"react-window\";\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\nimport { assert } from \"@itwin/core-bentley\";\nimport type { RatioChangeResult } from \"@itwin/core-react\";\nimport { Orientation } from \"@itwin/core-react\";\nimport { createContextWithMandatoryProvider } from \"../../common/UseContextWithMandatoryProvider\";\nimport type { PropertyUpdatedArgs } from \"../../editors/EditorContainer\";\nimport type { ActionButtonRenderer } from \"../../properties/renderers/ActionButtonRenderer\";\nimport type { PropertyGridColumnInfo } from \"../../properties/renderers/PropertyGridColumns\";\nimport type { PropertyValueRendererManager } from \"../../properties/ValueRendererManager\";\nimport { FilteredType } from \"../dataproviders/filterers/PropertyDataFiltererBase\";\nimport type { FlatGridItem, GridCategoryItem } from \"../internal/flat-items/FlatGridItem\";\nimport { MutableCategorizedPrimitiveProperty } from \"../internal/flat-items/MutableCategorizedPrimitiveProperty\";\nimport { MutableCustomGridCategory } from \"../internal/flat-items/MutableCustomGridCategory\";\nimport { FlatGridItemType } from \"../internal/flat-items/MutableFlatGridItem\";\nimport { MutableGridCategory } from \"../internal/flat-items/MutableGridCategory\";\nimport { FlatPropertyRenderer } from \"../internal/flat-properties/FlatPropertyRenderer\";\nimport type { IPropertyGridEventHandler } from \"../internal/PropertyGridEventHandler\";\nimport type { IPropertyGridModel } from \"../internal/PropertyGridModel\";\nimport type { PropertyCategoryRendererProps } from \"../PropertyCategoryRendererManager\";\nimport { PropertyCategoryRendererManager } from \"../PropertyCategoryRendererManager\";\nimport type { IPropertyDataProvider, PropertyCategory } from \"../PropertyDataProvider\";\nimport { ColumnResizingPropertyListPropsSupplier } from \"./ColumnResizingPropertyListPropsSupplier\";\nimport { FlatItemNestedBorderWrapper } from \"./FlatItemNestedBorderWrapper\";\nimport { PropertyCategoryBlock } from \"./PropertyCategoryBlock\";\nimport type { CommonPropertyGridProps, PropertyGridContentHighlightProps } from \"./PropertyGridCommons\";\nimport { PropertyGridCommons } from \"./PropertyGridCommons\";\nimport { PropertyGridEventsRelatedPropsSupplier } from \"./PropertyGridEventsRelatedPropsSupplier\";\n\n/** Properties for [[VirtualizedPropertyGrid]] React component\n * @public\n */\nexport interface VirtualizedPropertyGridProps extends CommonPropertyGridProps {\n /** Property grid view model that defines what needs to be rendered */\n model: IPropertyGridModel;\n /** Handler of the events raised from the property grid */\n eventHandler: IPropertyGridEventHandler;\n /** Property data provider used by the property grid */\n dataProvider: IPropertyDataProvider;\n /** Properties for highlighting property data in the grid. */\n highlight?: PropertyGridContentHighlightProps;\n /** Custom property category renderer manager. Defaults to [[PropertyCategoryRendererManager.defaultManager]]. */\n propertyCategoryRendererManager?: PropertyCategoryRendererManager;\n /** Width of the property grid component. */\n width: number;\n /** Height of the property grid component. */\n height: number;\n}\n\n/** State of [[VirtualizedPropertyGrid]] React component\n * @internal\n */\ninterface VirtualizedPropertyGridState {\n /** List of PropertyGrid categories */\n gridItems: FlatGridItem[];\n /** Actual orientation used by the property grid */\n orientation: Orientation;\n /** Keeps record of dynamic node heights */\n dynamicNodeHeights: Map<string, number>;\n /** When resetting node height cache, marks the point at which heights have become stale */\n resetIndex: number;\n}\n\n/**\n * Context of [[VirtualizedPropertyGrid]] component.\n * @internal\n */\nexport interface PropertyGridInternalContext {\n gridItems: FlatGridItem[];\n gridEventHandler: IPropertyGridEventHandler;\n gridModel: IPropertyGridModel;\n\n style?: React.CSSProperties;\n className?: string;\n gridContext: VirtualizedPropertyGridContext;\n onItemHeightChanged: (index: number, key: string, height: number) => void;\n}\n\n/**\n * Context of the surrounding [VirtualizedPropertyGrid]($components-react) component.\n * @public\n */\nexport interface VirtualizedPropertyGridContext {\n orientation: Orientation;\n gridWidth: number;\n\n isPropertyHoverEnabled: boolean;\n isPropertySelectionEnabled: boolean;\n selectedPropertyKey?: string;\n\n onPropertyClicked?: (property: PropertyRecord, key?: string) => void;\n onPropertyRightClicked?: (property: PropertyRecord, key?: string) => void;\n onPropertyContextMenu?: (property: PropertyRecord, e: React.MouseEvent) => void;\n\n editingPropertyKey?: string;\n onEditCommit?: (args: PropertyUpdatedArgs, category: PropertyCategory) => void;\n onEditCancel?: () => void;\n\n eventHandler: IPropertyGridEventHandler;\n dataProvider: IPropertyDataProvider;\n\n actionButtonRenderers?: ActionButtonRenderer[];\n propertyValueRendererManager?: PropertyValueRendererManager;\n propertyCategoryRendererManager?: PropertyCategoryRendererManager;\n\n columnRatio: number;\n columnInfo: PropertyGridColumnInfo;\n isResizeHandleBeingDragged: boolean;\n isResizeHandleHovered: boolean;\n onColumnRatioChanged: (ratio: number) => void | RatioChangeResult;\n onResizeHandleDragChanged: (newValue: boolean) => void;\n onResizeHandleHoverChanged: (newValue: boolean) => void;\n\n highlight?: PropertyGridContentHighlightProps;\n}\n\nconst [\n PropertyGridInternalContextProvider,\n _PropertyGridInternalContextConsumer,\n usePropertyGridInternalContext,\n] = createContextWithMandatoryProvider<PropertyGridInternalContext>(\"PropertyGridInternalContext\");\n\n/**\n * VirtualizedPropertyGrid React component.\n * @public\n */\nexport class VirtualizedPropertyGrid extends React.Component<VirtualizedPropertyGridProps, VirtualizedPropertyGridState> {\n private _listRef = React.createRef<VariableSizeList>();\n\n /** @internal */\n constructor(props: VirtualizedPropertyGridProps) {\n super(props);\n this.state = {\n gridItems: [],\n orientation: props.orientation ?? Orientation.Horizontal,\n dynamicNodeHeights: new Map(),\n resetIndex: 0,\n };\n }\n\n /** @internal */\n public override componentDidUpdate(prevProps: VirtualizedPropertyGridProps, prevState: VirtualizedPropertyGridState) {\n if (this.props.orientation !== prevProps.orientation\n || this.props.isOrientationFixed !== prevProps.isOrientationFixed\n || this.props.horizontalOrientationMinWidth !== prevProps.horizontalOrientationMinWidth\n || this.props.width !== prevProps.width)\n this.updateOrientation(this.props.width);\n\n if (this.props.model !== prevProps.model) {\n // istanbul ignore else\n if (this._listRef.current)\n this._listRef.current.resetAfterIndex(0);\n }\n\n if (this.props.highlight !== prevProps.highlight && this.props.highlight?.activeHighlight && this.state.gridItems.length !== 0) {\n let index = 0;\n let foundMatchingItem = false;\n for (const item of this.state.gridItems) {\n if (item instanceof MutableCategorizedPrimitiveProperty && this.props.highlight.activeHighlight.highlightedItemIdentifier === item.derivedRecord.property.name\n || item instanceof MutableGridCategory && this.props.highlight.activeHighlight.highlightedItemIdentifier === item.name) {\n foundMatchingItem = true;\n break;\n }\n index++;\n }\n if (foundMatchingItem) {\n // istanbul ignore else\n if (this._listRef.current)\n this._listRef.current.scrollToItem(index);\n }\n }\n\n if (this.state.dynamicNodeHeights !== prevState.dynamicNodeHeights) {\n // istanbul ignore else\n if (this._listRef.current)\n this._listRef.current.resetAfterIndex(this.state.resetIndex);\n }\n }\n\n /** @internal */\n public static getDerivedStateFromProps(props: VirtualizedPropertyGridProps, state: VirtualizedPropertyGridState): VirtualizedPropertyGridState | null {\n return {\n ...state,\n gridItems: props.model.getVisibleFlatGrid(),\n };\n }\n\n private updateOrientation(width: number) {\n const { orientation, isOrientationFixed, horizontalOrientationMinWidth } = { ...this.props };\n const currentOrientation = PropertyGridCommons.getCurrentOrientation(width, orientation, isOrientationFixed, horizontalOrientationMinWidth);\n\n if (currentOrientation !== this.state.orientation) {\n this.setState({ orientation: currentOrientation });\n // istanbul ignore else\n if (this._listRef.current)\n this._listRef.current.resetAfterIndex(0);\n }\n }\n\n /**\n * Calculate given node height depending on it's type, position in category, parent category depth and current orientation.\n * @param node FlatGridItem node for which to calculate height\n * @returns current height of node.\n */\n private calculateNodeHeight(node: FlatGridItem) {\n const categoryHeaderHeight = 38;\n const categoryHeaderPadding = 4;\n const categoryPropertyHeight = 27;\n const bottomBorderPadding = 5;\n const verticalPrimitivePropertyHeight = 55;\n\n return getPropertyHeight(this.state) + node.lastInNumberOfCategories * bottomBorderPadding;\n\n function getPropertyHeight(state: VirtualizedPropertyGridState) {\n const dynamicHeight = state.dynamicNodeHeights.get(node.key);\n if (dynamicHeight !== undefined) {\n if (node instanceof MutableCustomGridCategory) {\n return categoryHeaderHeight + categoryHeaderPadding\n + (node.isExpanded ? dynamicHeight + bottomBorderPadding : 0);\n }\n\n return dynamicHeight + (state.orientation === Orientation.Vertical ? 28 : 0);\n }\n\n if (node.type === FlatGridItemType.Category) {\n return categoryHeaderHeight + categoryHeaderPadding;\n }\n\n if (state.orientation === Orientation.Vertical && node.type === FlatGridItemType.Primitive) {\n return verticalPrimitivePropertyHeight;\n }\n\n return categoryPropertyHeight;\n }\n }\n\n private _handleNodeHeightChange = (index: number, key: string, newHeight: number) => {\n if (this.state.dynamicNodeHeights.get(key) === newHeight) {\n return;\n }\n\n this.setState((state) => {\n return {\n ...state,\n dynamicNodeHeights: new Map(state.dynamicNodeHeights).set(key, newHeight),\n resetIndex: index,\n };\n });\n };\n\n private _calculateNodeHeightByIndex = (index: number) => {\n const node = this.state.gridItems[index];\n return this.calculateNodeHeight(node);\n };\n\n private calculateEstimatedHeight() {\n let sum = 0;\n for (const node of this.state.gridItems)\n sum += this.calculateNodeHeight(node);\n\n return Math.ceil(sum / this.state.gridItems.length);\n }\n\n private _getNodeKey = (index: number) => {\n const node = this.state.gridItems[index];\n return node.key;\n };\n\n /** @internal */\n public override render() {\n return <ColumnResizingPropertyListPropsSupplier\n orientation={this.state.orientation}\n width={this.props.width}\n minLabelWidth={this.props.minLabelWidth}\n minValueWidth={this.props.minValueWidth}\n actionButtonWidth={this.props.actionButtonWidth}\n >\n {(columnResizeContext) => (\n <PropertyGridEventsRelatedPropsSupplier\n isPropertySelectionEnabled={this.props.isPropertySelectionEnabled ?? false}\n isPropertySelectionOnRightClickEnabled={this.props.isPropertySelectionOnRightClickEnabled}\n isPropertyEditingEnabled={this.props.isPropertyEditingEnabled}\n onPropertyContextMenu={this.props.onPropertyContextMenu}\n onPropertyUpdated={this.props.onPropertyUpdated}\n onPropertySelectionChanged={this.props.onPropertySelectionChanged}\n isPropertyHoverEnabled={this.props.isPropertyHoverEnabled ?? false}\n >\n {(selectionContext) => {\n const gridContext: VirtualizedPropertyGridContext = {\n orientation: columnResizeContext.orientation,\n gridWidth: this.props.width,\n\n isPropertyHoverEnabled: selectionContext.isPropertyHoverEnabled,\n isPropertySelectionEnabled: selectionContext.isPropertySelectionEnabled,\n selectedPropertyKey: selectionContext.selectedPropertyKey,\n\n onPropertyClicked: selectionContext.onPropertyClicked,\n onPropertyRightClicked: selectionContext.onPropertyRightClicked,\n onPropertyContextMenu: selectionContext.onPropertyContextMenu,\n\n editingPropertyKey: selectionContext.editingPropertyKey,\n onEditCommit: selectionContext.onEditCommit,\n onEditCancel: selectionContext.onEditCancel,\n\n eventHandler: this.props.eventHandler,\n dataProvider: this.props.dataProvider,\n\n actionButtonRenderers: this.props.actionButtonRenderers,\n propertyValueRendererManager: this.props.propertyValueRendererManager,\n propertyCategoryRendererManager: this.props.propertyCategoryRendererManager,\n\n columnRatio: columnResizeContext.columnRatio,\n columnInfo: columnResizeContext.columnInfo,\n isResizeHandleBeingDragged: columnResizeContext.isResizeHandleBeingDragged,\n isResizeHandleHovered: columnResizeContext.isResizeHandleHovered,\n onColumnRatioChanged: columnResizeContext.onColumnChanged,\n onResizeHandleDragChanged: columnResizeContext.onResizeHandleDragChanged,\n onResizeHandleHoverChanged: columnResizeContext.onResizeHandleHoverChanged,\n\n highlight: this.props.highlight,\n };\n\n const renderContext: PropertyGridInternalContext = {\n gridItems: this.state.gridItems,\n gridEventHandler: this.props.eventHandler,\n gridModel: this.props.model,\n style: this.props.style,\n className: this.props.className,\n onItemHeightChanged: this._handleNodeHeightChange,\n gridContext,\n };\n\n return (\n <PropertyGridInternalContextProvider value={renderContext}>\n <div className={classnames(\"components-virtualized-property-grid\", \"components-smallEditor-host\")}>\n <VariableSizeList\n className={classnames(\"components-property-grid-wrapper\", \"ReactWindow__VariableSizeList\", this.props.className)}\n width={this.props.width}\n height={this.props.height}\n itemCount={this.state.gridItems.length}\n itemSize={this._calculateNodeHeightByIndex}\n estimatedItemSize={this.calculateEstimatedHeight()}\n overscanCount={10}\n layout=\"vertical\"\n style={this.props.style}\n itemKey={this._getNodeKey}\n ref={this._listRef}\n >\n {FlatGridItemNode}\n </VariableSizeList>\n </div>\n </PropertyGridInternalContextProvider>\n );\n }}\n </PropertyGridEventsRelatedPropsSupplier >\n )}\n </ColumnResizingPropertyListPropsSupplier>;\n }\n}\n\nconst FlatGridItemNode = React.memo(\n ({ index, style: virtualizedListStyle }: ListChildComponentProps) => {\n const { gridItems, gridEventHandler, gridModel, gridContext, className, style, onItemHeightChanged } = usePropertyGridInternalContext(FlatGridItemNode);\n const node = gridItems[index];\n\n const onExpansionToggled = React.useCallback(\n () => gridEventHandler.onExpansionToggled(node.selectionKey),\n [gridEventHandler, node.selectionKey],\n );\n const onHeightChanged = React.useCallback(\n (newHeight: number) => onItemHeightChanged(index, node.key, newHeight),\n [onItemHeightChanged, index, node.key],\n );\n\n function getDisplayNode() {\n const lastInNumberOfCategories = node.lastInNumberOfCategories;\n switch (node.type) {\n case FlatGridItemType.Category:\n const categoryRendererManager = gridContext.propertyCategoryRendererManager\n ?? PropertyCategoryRendererManager.defaultManager;\n const customRenderer = categoryRendererManager.getCategoryComponent(node);\n const wrapperClassName = classnames(\n \"virtualized-grid-node-content\",\n customRenderer !== undefined ? \"virtualized-grid-node-custom-category\" : \"virtualized-grid-node-category\",\n );\n return (\n <FlatItemNestedBorderWrapper\n borderCount={node.depth}\n bottomBorderCount={lastInNumberOfCategories}\n className={wrapperClassName}\n >\n <PropertyCategoryBlock\n className={className}\n style={style}\n category={node.derivedCategory}\n onExpansionToggled={onExpansionToggled}\n highlight={gridContext.highlight?.filteredTypes?.includes(FilteredType.Category) ?\n gridContext.highlight :\n undefined\n }\n >\n {customRenderer !== undefined && (\n <CustomCategoryContent\n renderer={customRenderer}\n categoryItem={node}\n gridContext={gridContext}\n onHeightChanged={onHeightChanged}\n />\n )}\n </PropertyCategoryBlock>\n </FlatItemNestedBorderWrapper>\n );\n case FlatGridItemType.Array:\n case FlatGridItemType.Struct:\n case FlatGridItemType.Primitive:\n const selectionKey = node.selectionKey;\n const parentCategoryItem = gridModel.getItem(node.parentCategorySelectionKey) as GridCategoryItem;\n\n return (\n <FlatItemNestedBorderWrapper\n borderCount={parentCategoryItem.depth + 1}\n bottomBorderCount={lastInNumberOfCategories}\n className=\"virtualized-grid-node-content\"\n >\n <FlatPropertyRenderer\n key={node.key}\n uniqueKey={selectionKey}\n propertyRecord={node.derivedRecord}\n orientation={gridContext.orientation}\n indentation={node.depth}\n width={gridContext.gridWidth}\n\n isHoverable={gridContext.isPropertyHoverEnabled}\n isSelectable={gridContext.isPropertySelectionEnabled}\n isSelected={selectionKey === gridContext.selectedPropertyKey}\n\n onClick={node.type === FlatGridItemType.Primitive ? gridContext.onPropertyClicked : undefined}\n onRightClick={node.type === FlatGridItemType.Primitive ? gridContext.onPropertyRightClicked : undefined}\n onContextMenu={gridContext.onPropertyContextMenu}\n\n category={parentCategoryItem.derivedCategory}\n isEditing={selectionKey === gridContext.editingPropertyKey}\n onEditCommit={gridContext.onEditCommit}\n onEditCancel={gridContext.onEditCancel}\n\n isExpanded={node.isExpanded}\n onExpansionToggled={onExpansionToggled}\n onHeightChanged={onHeightChanged}\n\n actionButtonRenderers={gridContext.actionButtonRenderers}\n propertyValueRendererManager={gridContext.propertyValueRendererManager}\n\n columnRatio={gridContext.columnRatio}\n columnInfo={gridContext.columnInfo}\n isResizeHandleBeingDragged={gridContext.isResizeHandleBeingDragged}\n isResizeHandleHovered={gridContext.isResizeHandleHovered}\n onColumnRatioChanged={gridContext.onColumnRatioChanged}\n onResizeHandleDragChanged={gridContext.onResizeHandleDragChanged}\n onResizeHandleHoverChanged={gridContext.onResizeHandleHoverChanged}\n\n highlight={gridContext.highlight ?\n { applyOnLabel: (gridContext.highlight.filteredTypes?.includes(FilteredType.Label)) ?? false, applyOnValue: (gridContext.highlight.filteredTypes?.includes(FilteredType.Value)) ?? false, ...gridContext.highlight } :\n undefined\n }\n />\n </FlatItemNestedBorderWrapper>\n );\n }\n }\n\n return (\n <div className=\"virtualized-grid-node\" style={virtualizedListStyle}>\n {getDisplayNode()}\n </div>\n );\n },\n areEqual,\n);\n\nFlatGridItemNode.displayName = \"FlatGridItemNode\";\n\ninterface CustomCategoryContentProps {\n categoryItem: GridCategoryItem;\n renderer: React.ComponentType<PropertyCategoryRendererProps>;\n gridContext: VirtualizedPropertyGridContext;\n onHeightChanged: (newHeight: number) => void;\n}\n\nconst CustomCategoryContent: React.FC<CustomCategoryContentProps> = (props) => {\n const { onHeightChanged } = props;\n const divRef = React.useRef<HTMLDivElement>(null);\n\n React.useLayoutEffect(\n () => {\n assert(divRef.current !== null);\n const contentHeight = divRef.current.getBoundingClientRect().height;\n onHeightChanged(contentHeight);\n },\n [props.gridContext.orientation, onHeightChanged],\n );\n\n return (\n <div ref={divRef}>\n {React.createElement(props.renderer, props)}\n </div>\n );\n};\n"]}
1
+ {"version":3,"file":"VirtualizedPropertyGrid.js","sourceRoot":"","sources":["../../../../../src/components-react/propertygrid/component/VirtualizedPropertyGrid.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAE/F;;GAEG;AACH,0CAAwC;AACxC,4DAAoC;AACpC,6CAA+B;AAE/B,+CAA0D;AAE1D,sDAA6C;AAE7C,kDAAgD;AAChD,kGAAkG;AAKlG,kGAAmF;AAEnF,oHAAiH;AACjH,g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OAAO,CACL,6BAAK,SAAS,EAAC,uBAAuB,EAAC,KAAK,EAAE,oBAAoB,IAC/D,cAAc,EAAE,CACb,CACP,CAAC;AACJ,CAAC,EACD,uBAAQ,CACT,CAAC;AAEF,gBAAgB,CAAC,WAAW,GAAG,kBAAkB,CAAC;AASlD,MAAM,qBAAqB,GAAyC,CAAC,KAAK,EAAE,EAAE;IAC5E,MAAM,EAAE,eAAe,EAAE,GAAG,KAAK,CAAC;IAClC,MAAM,MAAM,GAAG,KAAK,CAAC,MAAM,CAAiB,IAAI,CAAC,CAAC;IAElD,KAAK,CAAC,eAAe,CACnB,GAAG,EAAE;QACH,IAAA,qBAAM,EAAC,MAAM,CAAC,OAAO,KAAK,IAAI,CAAC,CAAC;QAChC,MAAM,aAAa,GAAG,MAAM,CAAC,OAAO,CAAC,qBAAqB,EAAE,CAAC,MAAM,CAAC;QACpE,eAAe,CAAC,aAAa,CAAC,CAAC;IACjC,CAAC,EACD,CAAC,KAAK,CAAC,WAAW,CAAC,WAAW,EAAE,eAAe,CAAC,CACjD,CAAC;IAEF,OAAO,CACL,6BAAK,GAAG,EAAE,MAAM,IACb,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC,QAAQ,EAAE,KAAK,CAAC,CACvC,CACP,CAAC;AACJ,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\nimport \"./VirtualizedPropertyGrid.scss\";\r\nimport classnames from \"classnames\";\r\nimport * as React from \"react\";\r\nimport type { ListChildComponentProps} from \"react-window\";\r\nimport { areEqual, VariableSizeList } from \"react-window\";\r\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\r\nimport { assert } from \"@itwin/core-bentley\";\r\nimport type { RatioChangeResult } from \"@itwin/core-react\";\r\nimport { Orientation } from \"@itwin/core-react\";\r\nimport { createContextWithMandatoryProvider } from \"../../common/UseContextWithMandatoryProvider\";\r\nimport type { PropertyUpdatedArgs } from \"../../editors/EditorContainer\";\r\nimport type { ActionButtonRenderer } from \"../../properties/renderers/ActionButtonRenderer\";\r\nimport type { PropertyGridColumnInfo } from \"../../properties/renderers/PropertyGridColumns\";\r\nimport type { PropertyValueRendererManager } from \"../../properties/ValueRendererManager\";\r\nimport { FilteredType } from \"../dataproviders/filterers/PropertyDataFiltererBase\";\r\nimport type { FlatGridItem, GridCategoryItem } from \"../internal/flat-items/FlatGridItem\";\r\nimport { MutableCategorizedPrimitiveProperty } from \"../internal/flat-items/MutableCategorizedPrimitiveProperty\";\r\nimport { MutableCustomGridCategory } from \"../internal/flat-items/MutableCustomGridCategory\";\r\nimport { FlatGridItemType } from \"../internal/flat-items/MutableFlatGridItem\";\r\nimport { MutableGridCategory } from \"../internal/flat-items/MutableGridCategory\";\r\nimport { FlatPropertyRenderer } from \"../internal/flat-properties/FlatPropertyRenderer\";\r\nimport type { IPropertyGridEventHandler } from \"../internal/PropertyGridEventHandler\";\r\nimport type { IPropertyGridModel } from \"../internal/PropertyGridModel\";\r\nimport type { PropertyCategoryRendererProps } from \"../PropertyCategoryRendererManager\";\r\nimport { PropertyCategoryRendererManager } from \"../PropertyCategoryRendererManager\";\r\nimport type { IPropertyDataProvider, PropertyCategory } from \"../PropertyDataProvider\";\r\nimport { ColumnResizingPropertyListPropsSupplier } from \"./ColumnResizingPropertyListPropsSupplier\";\r\nimport { FlatItemNestedBorderWrapper } from \"./FlatItemNestedBorderWrapper\";\r\nimport { PropertyCategoryBlock } from \"./PropertyCategoryBlock\";\r\nimport type { CommonPropertyGridProps, PropertyGridContentHighlightProps } from \"./PropertyGridCommons\";\r\nimport { PropertyGridCommons } from \"./PropertyGridCommons\";\r\nimport { PropertyGridEventsRelatedPropsSupplier } from \"./PropertyGridEventsRelatedPropsSupplier\";\r\n\r\n/** Properties for [[VirtualizedPropertyGrid]] React component\r\n * @public\r\n */\r\nexport interface VirtualizedPropertyGridProps extends CommonPropertyGridProps {\r\n /** Property grid view model that defines what needs to be rendered */\r\n model: IPropertyGridModel;\r\n /** Handler of the events raised from the property grid */\r\n eventHandler: IPropertyGridEventHandler;\r\n /** Property data provider used by the property grid */\r\n dataProvider: IPropertyDataProvider;\r\n /** Properties for highlighting property data in the grid. */\r\n highlight?: PropertyGridContentHighlightProps;\r\n /** Custom property category renderer manager. Defaults to [[PropertyCategoryRendererManager.defaultManager]]. */\r\n propertyCategoryRendererManager?: PropertyCategoryRendererManager;\r\n /** Width of the property grid component. */\r\n width: number;\r\n /** Height of the property grid component. */\r\n height: number;\r\n}\r\n\r\n/** State of [[VirtualizedPropertyGrid]] React component\r\n * @internal\r\n */\r\ninterface VirtualizedPropertyGridState {\r\n /** List of PropertyGrid categories */\r\n gridItems: FlatGridItem[];\r\n /** Actual orientation used by the property grid */\r\n orientation: Orientation;\r\n /** Keeps record of dynamic node heights */\r\n dynamicNodeHeights: Map<string, number>;\r\n /** When resetting node height cache, marks the point at which heights have become stale */\r\n resetIndex: number;\r\n}\r\n\r\n/**\r\n * Context of [[VirtualizedPropertyGrid]] component.\r\n * @internal\r\n */\r\nexport interface PropertyGridInternalContext {\r\n gridItems: FlatGridItem[];\r\n gridEventHandler: IPropertyGridEventHandler;\r\n gridModel: IPropertyGridModel;\r\n\r\n style?: React.CSSProperties;\r\n className?: string;\r\n gridContext: VirtualizedPropertyGridContext;\r\n onItemHeightChanged: (index: number, key: string, height: number) => void;\r\n}\r\n\r\n/**\r\n * Context of the surrounding [VirtualizedPropertyGrid]($components-react) component.\r\n * @public\r\n */\r\nexport interface VirtualizedPropertyGridContext {\r\n orientation: Orientation;\r\n gridWidth: number;\r\n\r\n isPropertyHoverEnabled: boolean;\r\n isPropertySelectionEnabled: boolean;\r\n selectedPropertyKey?: string;\r\n\r\n onPropertyClicked?: (property: PropertyRecord, key?: string) => void;\r\n onPropertyRightClicked?: (property: PropertyRecord, key?: string) => void;\r\n onPropertyContextMenu?: (property: PropertyRecord, e: React.MouseEvent) => void;\r\n\r\n editingPropertyKey?: string;\r\n onEditCommit?: (args: PropertyUpdatedArgs, category: PropertyCategory) => void;\r\n onEditCancel?: () => void;\r\n\r\n eventHandler: IPropertyGridEventHandler;\r\n dataProvider: IPropertyDataProvider;\r\n\r\n actionButtonRenderers?: ActionButtonRenderer[];\r\n propertyValueRendererManager?: PropertyValueRendererManager;\r\n propertyCategoryRendererManager?: PropertyCategoryRendererManager;\r\n\r\n columnRatio: number;\r\n columnInfo: PropertyGridColumnInfo;\r\n isResizeHandleBeingDragged: boolean;\r\n isResizeHandleHovered: boolean;\r\n onColumnRatioChanged: (ratio: number) => void | RatioChangeResult;\r\n onResizeHandleDragChanged: (newValue: boolean) => void;\r\n onResizeHandleHoverChanged: (newValue: boolean) => void;\r\n\r\n highlight?: PropertyGridContentHighlightProps;\r\n}\r\n\r\nconst [\r\n PropertyGridInternalContextProvider,\r\n _PropertyGridInternalContextConsumer,\r\n usePropertyGridInternalContext,\r\n] = createContextWithMandatoryProvider<PropertyGridInternalContext>(\"PropertyGridInternalContext\");\r\n\r\n/**\r\n * VirtualizedPropertyGrid React component.\r\n * @public\r\n */\r\nexport class VirtualizedPropertyGrid extends React.Component<VirtualizedPropertyGridProps, VirtualizedPropertyGridState> {\r\n private _listRef = React.createRef<VariableSizeList>();\r\n\r\n /** @internal */\r\n constructor(props: VirtualizedPropertyGridProps) {\r\n super(props);\r\n this.state = {\r\n gridItems: [],\r\n orientation: props.orientation ?? Orientation.Horizontal,\r\n dynamicNodeHeights: new Map(),\r\n resetIndex: 0,\r\n };\r\n }\r\n\r\n /** @internal */\r\n public override componentDidUpdate(prevProps: VirtualizedPropertyGridProps, prevState: VirtualizedPropertyGridState) {\r\n if (this.props.orientation !== prevProps.orientation\r\n || this.props.isOrientationFixed !== prevProps.isOrientationFixed\r\n || this.props.horizontalOrientationMinWidth !== prevProps.horizontalOrientationMinWidth\r\n || this.props.width !== prevProps.width)\r\n this.updateOrientation(this.props.width);\r\n\r\n if (this.props.model !== prevProps.model) {\r\n // istanbul ignore else\r\n if (this._listRef.current)\r\n this._listRef.current.resetAfterIndex(0);\r\n }\r\n\r\n if (this.props.highlight !== prevProps.highlight && this.props.highlight?.activeHighlight && this.state.gridItems.length !== 0) {\r\n let index = 0;\r\n let foundMatchingItem = false;\r\n for (const item of this.state.gridItems) {\r\n if (item instanceof MutableCategorizedPrimitiveProperty && this.props.highlight.activeHighlight.highlightedItemIdentifier === item.derivedRecord.property.name\r\n || item instanceof MutableGridCategory && this.props.highlight.activeHighlight.highlightedItemIdentifier === item.name) {\r\n foundMatchingItem = true;\r\n break;\r\n }\r\n index++;\r\n }\r\n if (foundMatchingItem) {\r\n // istanbul ignore else\r\n if (this._listRef.current)\r\n this._listRef.current.scrollToItem(index);\r\n }\r\n }\r\n\r\n if (this.state.dynamicNodeHeights !== prevState.dynamicNodeHeights) {\r\n // istanbul ignore else\r\n if (this._listRef.current)\r\n this._listRef.current.resetAfterIndex(this.state.resetIndex);\r\n }\r\n }\r\n\r\n /** @internal */\r\n public static getDerivedStateFromProps(props: VirtualizedPropertyGridProps, state: VirtualizedPropertyGridState): VirtualizedPropertyGridState | null {\r\n return {\r\n ...state,\r\n gridItems: props.model.getVisibleFlatGrid(),\r\n };\r\n }\r\n\r\n private updateOrientation(width: number) {\r\n const { orientation, isOrientationFixed, horizontalOrientationMinWidth } = { ...this.props };\r\n const currentOrientation = PropertyGridCommons.getCurrentOrientation(width, orientation, isOrientationFixed, horizontalOrientationMinWidth);\r\n\r\n if (currentOrientation !== this.state.orientation) {\r\n this.setState({ orientation: currentOrientation });\r\n // istanbul ignore else\r\n if (this._listRef.current)\r\n this._listRef.current.resetAfterIndex(0);\r\n }\r\n }\r\n\r\n /**\r\n * Calculate given node height depending on it's type, position in category, parent category depth and current orientation.\r\n * @param node FlatGridItem node for which to calculate height\r\n * @returns current height of node.\r\n */\r\n private calculateNodeHeight(node: FlatGridItem) {\r\n const categoryHeaderHeight = 38;\r\n const categoryHeaderPadding = 4;\r\n const categoryPropertyHeight = 27;\r\n const bottomBorderPadding = 5;\r\n const verticalPrimitivePropertyHeight = 55;\r\n\r\n return getPropertyHeight(this.state) + node.lastInNumberOfCategories * bottomBorderPadding;\r\n\r\n function getPropertyHeight(state: VirtualizedPropertyGridState) {\r\n const dynamicHeight = state.dynamicNodeHeights.get(node.key);\r\n if (dynamicHeight !== undefined) {\r\n if (node instanceof MutableCustomGridCategory) {\r\n return categoryHeaderHeight + categoryHeaderPadding\r\n + (node.isExpanded ? dynamicHeight + bottomBorderPadding : 0);\r\n }\r\n\r\n return dynamicHeight + (state.orientation === Orientation.Vertical ? 28 : 0);\r\n }\r\n\r\n if (node.type === FlatGridItemType.Category) {\r\n return categoryHeaderHeight + categoryHeaderPadding;\r\n }\r\n\r\n if (state.orientation === Orientation.Vertical && node.type === FlatGridItemType.Primitive) {\r\n return verticalPrimitivePropertyHeight;\r\n }\r\n\r\n return categoryPropertyHeight;\r\n }\r\n }\r\n\r\n private _handleNodeHeightChange = (index: number, key: string, newHeight: number) => {\r\n if (this.state.dynamicNodeHeights.get(key) === newHeight) {\r\n return;\r\n }\r\n\r\n this.setState((state) => {\r\n return {\r\n ...state,\r\n dynamicNodeHeights: new Map(state.dynamicNodeHeights).set(key, newHeight),\r\n resetIndex: index,\r\n };\r\n });\r\n };\r\n\r\n private _calculateNodeHeightByIndex = (index: number) => {\r\n const node = this.state.gridItems[index];\r\n return this.calculateNodeHeight(node);\r\n };\r\n\r\n private calculateEstimatedHeight() {\r\n let sum = 0;\r\n for (const node of this.state.gridItems)\r\n sum += this.calculateNodeHeight(node);\r\n\r\n return Math.ceil(sum / this.state.gridItems.length);\r\n }\r\n\r\n private _getNodeKey = (index: number) => {\r\n const node = this.state.gridItems[index];\r\n return node.key;\r\n };\r\n\r\n /** @internal */\r\n public override render() {\r\n return <ColumnResizingPropertyListPropsSupplier\r\n orientation={this.state.orientation}\r\n width={this.props.width}\r\n minLabelWidth={this.props.minLabelWidth}\r\n minValueWidth={this.props.minValueWidth}\r\n actionButtonWidth={this.props.actionButtonWidth}\r\n >\r\n {(columnResizeContext) => (\r\n <PropertyGridEventsRelatedPropsSupplier\r\n isPropertySelectionEnabled={this.props.isPropertySelectionEnabled ?? false}\r\n isPropertySelectionOnRightClickEnabled={this.props.isPropertySelectionOnRightClickEnabled}\r\n isPropertyEditingEnabled={this.props.isPropertyEditingEnabled}\r\n onPropertyContextMenu={this.props.onPropertyContextMenu}\r\n onPropertyUpdated={this.props.onPropertyUpdated}\r\n onPropertySelectionChanged={this.props.onPropertySelectionChanged}\r\n isPropertyHoverEnabled={this.props.isPropertyHoverEnabled ?? false}\r\n >\r\n {(selectionContext) => {\r\n const gridContext: VirtualizedPropertyGridContext = {\r\n orientation: columnResizeContext.orientation,\r\n gridWidth: this.props.width,\r\n\r\n isPropertyHoverEnabled: selectionContext.isPropertyHoverEnabled,\r\n isPropertySelectionEnabled: selectionContext.isPropertySelectionEnabled,\r\n selectedPropertyKey: selectionContext.selectedPropertyKey,\r\n\r\n onPropertyClicked: selectionContext.onPropertyClicked,\r\n onPropertyRightClicked: selectionContext.onPropertyRightClicked,\r\n onPropertyContextMenu: selectionContext.onPropertyContextMenu,\r\n\r\n editingPropertyKey: selectionContext.editingPropertyKey,\r\n onEditCommit: selectionContext.onEditCommit,\r\n onEditCancel: selectionContext.onEditCancel,\r\n\r\n eventHandler: this.props.eventHandler,\r\n dataProvider: this.props.dataProvider,\r\n\r\n actionButtonRenderers: this.props.actionButtonRenderers,\r\n propertyValueRendererManager: this.props.propertyValueRendererManager,\r\n propertyCategoryRendererManager: this.props.propertyCategoryRendererManager,\r\n\r\n columnRatio: columnResizeContext.columnRatio,\r\n columnInfo: columnResizeContext.columnInfo,\r\n isResizeHandleBeingDragged: columnResizeContext.isResizeHandleBeingDragged,\r\n isResizeHandleHovered: columnResizeContext.isResizeHandleHovered,\r\n onColumnRatioChanged: columnResizeContext.onColumnChanged,\r\n onResizeHandleDragChanged: columnResizeContext.onResizeHandleDragChanged,\r\n onResizeHandleHoverChanged: columnResizeContext.onResizeHandleHoverChanged,\r\n\r\n highlight: this.props.highlight,\r\n };\r\n\r\n const renderContext: PropertyGridInternalContext = {\r\n gridItems: this.state.gridItems,\r\n gridEventHandler: this.props.eventHandler,\r\n gridModel: this.props.model,\r\n style: this.props.style,\r\n className: this.props.className,\r\n onItemHeightChanged: this._handleNodeHeightChange,\r\n gridContext,\r\n };\r\n\r\n return (\r\n <PropertyGridInternalContextProvider value={renderContext}>\r\n <div className={classnames(\"components-virtualized-property-grid\", \"components-smallEditor-host\")}>\r\n <VariableSizeList\r\n className={classnames(\"components-property-grid-wrapper\", \"ReactWindow__VariableSizeList\", this.props.className)}\r\n width={this.props.width}\r\n height={this.props.height}\r\n itemCount={this.state.gridItems.length}\r\n itemSize={this._calculateNodeHeightByIndex}\r\n estimatedItemSize={this.calculateEstimatedHeight()}\r\n overscanCount={10}\r\n layout=\"vertical\"\r\n style={this.props.style}\r\n itemKey={this._getNodeKey}\r\n ref={this._listRef}\r\n >\r\n {FlatGridItemNode}\r\n </VariableSizeList>\r\n </div>\r\n </PropertyGridInternalContextProvider>\r\n );\r\n }}\r\n </PropertyGridEventsRelatedPropsSupplier >\r\n )}\r\n </ColumnResizingPropertyListPropsSupplier>;\r\n }\r\n}\r\n\r\nconst FlatGridItemNode = React.memo(\r\n ({ index, style: virtualizedListStyle }: ListChildComponentProps) => {\r\n const { gridItems, gridEventHandler, gridModel, gridContext, className, style, onItemHeightChanged } = usePropertyGridInternalContext(FlatGridItemNode);\r\n const node = gridItems[index];\r\n\r\n const onExpansionToggled = React.useCallback(\r\n () => gridEventHandler.onExpansionToggled(node.selectionKey),\r\n [gridEventHandler, node.selectionKey],\r\n );\r\n const onHeightChanged = React.useCallback(\r\n (newHeight: number) => onItemHeightChanged(index, node.key, newHeight),\r\n [onItemHeightChanged, index, node.key],\r\n );\r\n\r\n function getDisplayNode() {\r\n const lastInNumberOfCategories = node.lastInNumberOfCategories;\r\n switch (node.type) {\r\n case FlatGridItemType.Category:\r\n const categoryRendererManager = gridContext.propertyCategoryRendererManager\r\n ?? PropertyCategoryRendererManager.defaultManager;\r\n const customRenderer = categoryRendererManager.getCategoryComponent(node);\r\n const wrapperClassName = classnames(\r\n \"virtualized-grid-node-content\",\r\n customRenderer !== undefined ? \"virtualized-grid-node-custom-category\" : \"virtualized-grid-node-category\",\r\n );\r\n return (\r\n <FlatItemNestedBorderWrapper\r\n borderCount={node.depth}\r\n bottomBorderCount={lastInNumberOfCategories}\r\n className={wrapperClassName}\r\n >\r\n <PropertyCategoryBlock\r\n className={className}\r\n style={style}\r\n category={node.derivedCategory}\r\n onExpansionToggled={onExpansionToggled}\r\n highlight={gridContext.highlight?.filteredTypes?.includes(FilteredType.Category) ?\r\n gridContext.highlight :\r\n undefined\r\n }\r\n >\r\n {customRenderer !== undefined && (\r\n <CustomCategoryContent\r\n renderer={customRenderer}\r\n categoryItem={node}\r\n gridContext={gridContext}\r\n onHeightChanged={onHeightChanged}\r\n />\r\n )}\r\n </PropertyCategoryBlock>\r\n </FlatItemNestedBorderWrapper>\r\n );\r\n case FlatGridItemType.Array:\r\n case FlatGridItemType.Struct:\r\n case FlatGridItemType.Primitive:\r\n const selectionKey = node.selectionKey;\r\n const parentCategoryItem = gridModel.getItem(node.parentCategorySelectionKey) as GridCategoryItem;\r\n\r\n return (\r\n <FlatItemNestedBorderWrapper\r\n borderCount={parentCategoryItem.depth + 1}\r\n bottomBorderCount={lastInNumberOfCategories}\r\n className=\"virtualized-grid-node-content\"\r\n >\r\n <FlatPropertyRenderer\r\n key={node.key}\r\n uniqueKey={selectionKey}\r\n propertyRecord={node.derivedRecord}\r\n orientation={gridContext.orientation}\r\n indentation={node.depth}\r\n width={gridContext.gridWidth}\r\n\r\n isHoverable={gridContext.isPropertyHoverEnabled}\r\n isSelectable={gridContext.isPropertySelectionEnabled}\r\n isSelected={selectionKey === gridContext.selectedPropertyKey}\r\n\r\n onClick={node.type === FlatGridItemType.Primitive ? gridContext.onPropertyClicked : undefined}\r\n onRightClick={node.type === FlatGridItemType.Primitive ? gridContext.onPropertyRightClicked : undefined}\r\n onContextMenu={gridContext.onPropertyContextMenu}\r\n\r\n category={parentCategoryItem.derivedCategory}\r\n isEditing={selectionKey === gridContext.editingPropertyKey}\r\n onEditCommit={gridContext.onEditCommit}\r\n onEditCancel={gridContext.onEditCancel}\r\n\r\n isExpanded={node.isExpanded}\r\n onExpansionToggled={onExpansionToggled}\r\n onHeightChanged={onHeightChanged}\r\n\r\n actionButtonRenderers={gridContext.actionButtonRenderers}\r\n propertyValueRendererManager={gridContext.propertyValueRendererManager}\r\n\r\n columnRatio={gridContext.columnRatio}\r\n columnInfo={gridContext.columnInfo}\r\n isResizeHandleBeingDragged={gridContext.isResizeHandleBeingDragged}\r\n isResizeHandleHovered={gridContext.isResizeHandleHovered}\r\n onColumnRatioChanged={gridContext.onColumnRatioChanged}\r\n onResizeHandleDragChanged={gridContext.onResizeHandleDragChanged}\r\n onResizeHandleHoverChanged={gridContext.onResizeHandleHoverChanged}\r\n\r\n highlight={gridContext.highlight ?\r\n { applyOnLabel: (gridContext.highlight.filteredTypes?.includes(FilteredType.Label)) ?? false, applyOnValue: (gridContext.highlight.filteredTypes?.includes(FilteredType.Value)) ?? false, ...gridContext.highlight } :\r\n undefined\r\n }\r\n />\r\n </FlatItemNestedBorderWrapper>\r\n );\r\n }\r\n }\r\n\r\n return (\r\n <div className=\"virtualized-grid-node\" style={virtualizedListStyle}>\r\n {getDisplayNode()}\r\n </div>\r\n );\r\n },\r\n areEqual,\r\n);\r\n\r\nFlatGridItemNode.displayName = \"FlatGridItemNode\";\r\n\r\ninterface CustomCategoryContentProps {\r\n categoryItem: GridCategoryItem;\r\n renderer: React.ComponentType<PropertyCategoryRendererProps>;\r\n gridContext: VirtualizedPropertyGridContext;\r\n onHeightChanged: (newHeight: number) => void;\r\n}\r\n\r\nconst CustomCategoryContent: React.FC<CustomCategoryContentProps> = (props) => {\r\n const { onHeightChanged } = props;\r\n const divRef = React.useRef<HTMLDivElement>(null);\r\n\r\n React.useLayoutEffect(\r\n () => {\r\n assert(divRef.current !== null);\r\n const contentHeight = divRef.current.getBoundingClientRect().height;\r\n onHeightChanged(contentHeight);\r\n },\r\n [props.gridContext.orientation, onHeightChanged],\r\n );\r\n\r\n return (\r\n <div ref={divRef}>\r\n {React.createElement(props.renderer, props)}\r\n </div>\r\n );\r\n};\r\n"]}
@@ -1,101 +1,101 @@
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 "~@itwin/core-react/lib/cjs/core-react/expandable/list";
6
- @import "~@itwin/core-react/lib/cjs/core-react/scrollbar";
7
-
8
- .components-virtualized-property-grid-loader {
9
- height: 100%;
10
- display: flex;
11
- align-items: center;
12
- justify-content: center;
13
- }
14
-
15
- .components-virtualized-property-grid {
16
- user-select: none;
17
- }
18
-
19
- .components-property-grid-wrapper {
20
- @include uicore-touch-scrolling;
21
- @include uicore-scrollbar();
22
- }
23
-
24
- .virtualized-grid-node {
25
- > :not(.virtualized-grid-node-category) {
26
- background: var(--iui-color-background);
27
- }
28
-
29
- .nested-border-middle {
30
- height: 100%;
31
- padding: 0 4px;
32
- box-sizing: border-box;
33
- border-left: 1px solid var(--iui-color-border);
34
- border-right: 1px solid var(--iui-color-border);
35
- }
36
-
37
- .nested-border-bottom {
38
- border-bottom: 1px solid var(--iui-color-border);
39
- padding-bottom: 4px;
40
- }
41
-
42
- .components--clickable {
43
- cursor: pointer;
44
- box-sizing: border-box;
45
-
46
- &:not(.components--selected) {
47
- &:hover {
48
- // Highlight the whole row of inner-most expandable block
49
- margin: 0 -4px;
50
- // Compensate the negative margin by adding padding
51
- padding: 0 12px;
52
-
53
- background: var(--iui-color-background-hover);
54
- }
55
- }
56
- }
57
-
58
- .components--selected {
59
- // Highlight the whole row of inner-most expandable block
60
- margin: 0 -4px;
61
- // Compensate the negative margin by adding padding (minus one for border)
62
- padding: 0px 11px;
63
-
64
- background-color: var(--iui-color-background-accent-muted);
65
- border: 1px solid var(--iui-color-border-accent);
66
- }
67
-
68
- .components--hoverable {
69
- &:hover {
70
- background: var(--iui-color-background-hover);
71
-
72
- &:not(.components--selected) {
73
- // Highlight the whole row of inner-most expandable block
74
- margin: 0 -4px;
75
- // Compensate the negative margin by adding padding
76
- padding: 0 12px;
77
- }
78
- }
79
- }
80
- }
81
-
82
- .virtualized-grid-node-category {
83
- padding-top: 4px;
84
-
85
- .iui-expandable-content {
86
- // We are rendering virtualized content below the expandable block
87
- display: none;
88
- }
89
- }
90
-
91
- .virtualized-grid-node-custom-category {
92
- padding-top: 4px;
93
-
94
- .iui-expandable-content > div {
95
- padding: 0 4px 4px 4px;
96
- }
97
- }
98
-
99
- .virtualized-grid-node-content {
100
- height: 100%;
101
- }
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 "~@itwin/core-react/lib/cjs/core-react/expandable/list";
6
+ @import "~@itwin/core-react/lib/cjs/core-react/scrollbar";
7
+
8
+ .components-virtualized-property-grid-loader {
9
+ height: 100%;
10
+ display: flex;
11
+ align-items: center;
12
+ justify-content: center;
13
+ }
14
+
15
+ .components-virtualized-property-grid {
16
+ user-select: none;
17
+ }
18
+
19
+ .components-property-grid-wrapper {
20
+ @include uicore-touch-scrolling;
21
+ @include uicore-scrollbar();
22
+ }
23
+
24
+ .virtualized-grid-node {
25
+ > :not(.virtualized-grid-node-category) {
26
+ background: var(--iui-color-background);
27
+ }
28
+
29
+ .nested-border-middle {
30
+ height: 100%;
31
+ padding: 0 4px;
32
+ box-sizing: border-box;
33
+ border-left: 1px solid var(--iui-color-border);
34
+ border-right: 1px solid var(--iui-color-border);
35
+ }
36
+
37
+ .nested-border-bottom {
38
+ border-bottom: 1px solid var(--iui-color-border);
39
+ padding-bottom: 4px;
40
+ }
41
+
42
+ .components--clickable {
43
+ cursor: pointer;
44
+ box-sizing: border-box;
45
+
46
+ &:not(.components--selected) {
47
+ &:hover {
48
+ // Highlight the whole row of inner-most expandable block
49
+ margin: 0 -4px;
50
+ // Compensate the negative margin by adding padding
51
+ padding: 0 12px;
52
+
53
+ background: var(--iui-color-background-hover);
54
+ }
55
+ }
56
+ }
57
+
58
+ .components--selected {
59
+ // Highlight the whole row of inner-most expandable block
60
+ margin: 0 -4px;
61
+ // Compensate the negative margin by adding padding (minus one for border)
62
+ padding: 0px 11px;
63
+
64
+ background-color: var(--iui-color-background-accent-muted);
65
+ border: 1px solid var(--iui-color-border-accent);
66
+ }
67
+
68
+ .components--hoverable {
69
+ &:hover {
70
+ background: var(--iui-color-background-hover);
71
+
72
+ &:not(.components--selected) {
73
+ // Highlight the whole row of inner-most expandable block
74
+ margin: 0 -4px;
75
+ // Compensate the negative margin by adding padding
76
+ padding: 0 12px;
77
+ }
78
+ }
79
+ }
80
+ }
81
+
82
+ .virtualized-grid-node-category {
83
+ padding-top: 4px;
84
+
85
+ .iui-expandable-content {
86
+ // We are rendering virtualized content below the expandable block
87
+ display: none;
88
+ }
89
+ }
90
+
91
+ .virtualized-grid-node-custom-category {
92
+ padding-top: 4px;
93
+
94
+ .iui-expandable-content > div {
95
+ padding: 0 4px 4px 4px;
96
+ }
97
+ }
98
+
99
+ .virtualized-grid-node-content {
100
+ height: 100%;
101
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"VirtualizedPropertyGridWithDataProvider.js","sourceRoot":"","sources":["../../../../../src/components-react/propertygrid/component/VirtualizedPropertyGridWithDataProvider.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;;;;;;AAE/F;;GAEG;AAEH,kDAA0B;AAC1B,gEAA6D;AAC7D,qEAA8H;AAI9H,uEAAoE;AAkBpE;;;;GAIG;AACH,SAAgB,uCAAuC,CAAC,KAAmD;IACzG,MAAM,WAAW,GAAG,IAAA,8CAA0B,EAAC,EAAE,YAAY,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC,CAAC;IACrF,MAAM,KAAK,GAAG,IAAA,wCAAoB,EAAC,EAAE,WAAW,EAAE,CAAC,CAAC;IACpD,MAAM,YAAY,GAAG,IAAA,+CAA2B,EAAC,EAAE,WAAW,EAAE,CAAC,CAAC;IAElE,IAAI,CAAC,KAAK,EAAE;QACV,OAAO,CACL,uCAAK,SAAS,EAAC,6CAA6C;YAC1D,8BAAC,+BAAc,IAAC,IAAI,EAAC,OAAO,GAAG,CAC3B,CACP,CAAC;KACH;IAED,OAAO,CAAC,8BAAC,iDAAuB,OAAK,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,YAAY,GAAI,CAAC,CAAC;AAC5F,CAAC;AAdD,0FAcC","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*--------------------------------------------------------------------------------------------*/\n\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport React from \"react\";\nimport { DelayedSpinner } from \"../../common/DelayedSpinner\";\nimport { usePropertyGridEventHandler, usePropertyGridModel, usePropertyGridModelSource } from \"../internal/PropertyGridHooks\";\nimport type { PropertyCategoryRendererManager } from \"../PropertyCategoryRendererManager\";\nimport type { IPropertyDataProvider } from \"../PropertyDataProvider\";\nimport type { CommonPropertyGridProps, PropertyGridContentHighlightProps } from \"./PropertyGridCommons\";\nimport { VirtualizedPropertyGrid } from \"./VirtualizedPropertyGrid\";\n\n/** Properties for [[VirtualizedPropertyGridWithDataProvider]] React component\n * @public\n */\nexport interface VirtualizedPropertyGridWithDataProviderProps extends CommonPropertyGridProps {\n /** Property data provider used by the property grid */\n dataProvider: IPropertyDataProvider;\n /** Properties for highlighting property data in the grid. */\n highlight?: PropertyGridContentHighlightProps;\n /** Custom property category renderer manager. Defaults to [[PropertyCategoryRendererManager.defaultManager]]. */\n propertyCategoryRendererManager?: PropertyCategoryRendererManager;\n /** Width of the property grid component. */\n width: number;\n /** Height of the property grid component. */\n height: number;\n}\n\n/**\n * [[VirtualizedPropertyGrid]] React Component which takes a data provider and\n * sets up default implementations for [[IPropertyGridModelSource]] and [[IPropertyGridEventHandler]]\n * @public\n */\nexport function VirtualizedPropertyGridWithDataProvider(props: VirtualizedPropertyGridWithDataProviderProps) {\n const modelSource = usePropertyGridModelSource({ dataProvider: props.dataProvider });\n const model = usePropertyGridModel({ modelSource });\n const eventHandler = usePropertyGridEventHandler({ modelSource });\n\n if (!model) {\n return (\n <div className=\"components-virtualized-property-grid-loader\">\n <DelayedSpinner size=\"large\" />\n </div>\n );\n }\n\n return (<VirtualizedPropertyGrid {...props} model={model} eventHandler={eventHandler} />);\n}\n"]}
1
+ {"version":3,"file":"VirtualizedPropertyGridWithDataProvider.js","sourceRoot":"","sources":["../../../../../src/components-react/propertygrid/component/VirtualizedPropertyGridWithDataProvider.tsx"],"names":[],"mappings":";AAAA;;;+FAG+F;;;;;;AAE/F;;GAEG;AAEH,kDAA0B;AAC1B,gEAA6D;AAC7D,qEAA8H;AAI9H,uEAAoE;AAkBpE;;;;GAIG;AACH,SAAgB,uCAAuC,CAAC,KAAmD;IACzG,MAAM,WAAW,GAAG,IAAA,8CAA0B,EAAC,EAAE,YAAY,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC,CAAC;IACrF,MAAM,KAAK,GAAG,IAAA,wCAAoB,EAAC,EAAE,WAAW,EAAE,CAAC,CAAC;IACpD,MAAM,YAAY,GAAG,IAAA,+CAA2B,EAAC,EAAE,WAAW,EAAE,CAAC,CAAC;IAElE,IAAI,CAAC,KAAK,EAAE;QACV,OAAO,CACL,uCAAK,SAAS,EAAC,6CAA6C;YAC1D,8BAAC,+BAAc,IAAC,IAAI,EAAC,OAAO,GAAG,CAC3B,CACP,CAAC;KACH;IAED,OAAO,CAAC,8BAAC,iDAAuB,OAAK,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,YAAY,EAAE,YAAY,GAAI,CAAC,CAAC;AAC5F,CAAC;AAdD,0FAcC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport React from \"react\";\r\nimport { DelayedSpinner } from \"../../common/DelayedSpinner\";\r\nimport { usePropertyGridEventHandler, usePropertyGridModel, usePropertyGridModelSource } from \"../internal/PropertyGridHooks\";\r\nimport type { PropertyCategoryRendererManager } from \"../PropertyCategoryRendererManager\";\r\nimport type { IPropertyDataProvider } from \"../PropertyDataProvider\";\r\nimport type { CommonPropertyGridProps, PropertyGridContentHighlightProps } from \"./PropertyGridCommons\";\r\nimport { VirtualizedPropertyGrid } from \"./VirtualizedPropertyGrid\";\r\n\r\n/** Properties for [[VirtualizedPropertyGridWithDataProvider]] React component\r\n * @public\r\n */\r\nexport interface VirtualizedPropertyGridWithDataProviderProps extends CommonPropertyGridProps {\r\n /** Property data provider used by the property grid */\r\n dataProvider: IPropertyDataProvider;\r\n /** Properties for highlighting property data in the grid. */\r\n highlight?: PropertyGridContentHighlightProps;\r\n /** Custom property category renderer manager. Defaults to [[PropertyCategoryRendererManager.defaultManager]]. */\r\n propertyCategoryRendererManager?: PropertyCategoryRendererManager;\r\n /** Width of the property grid component. */\r\n width: number;\r\n /** Height of the property grid component. */\r\n height: number;\r\n}\r\n\r\n/**\r\n * [[VirtualizedPropertyGrid]] React Component which takes a data provider and\r\n * sets up default implementations for [[IPropertyGridModelSource]] and [[IPropertyGridEventHandler]]\r\n * @public\r\n */\r\nexport function VirtualizedPropertyGridWithDataProvider(props: VirtualizedPropertyGridWithDataProviderProps) {\r\n const modelSource = usePropertyGridModelSource({ dataProvider: props.dataProvider });\r\n const model = usePropertyGridModel({ modelSource });\r\n const eventHandler = usePropertyGridEventHandler({ modelSource });\r\n\r\n if (!model) {\r\n return (\r\n <div className=\"components-virtualized-property-grid-loader\">\r\n <DelayedSpinner size=\"large\" />\r\n </div>\r\n );\r\n }\r\n\r\n return (<VirtualizedPropertyGrid {...props} model={model} eventHandler={eventHandler} />);\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"FilteringDataProvider.js","sourceRoot":"","sources":["../../../../../src/components-react/propertygrid/dataproviders/FilteringDataProvider.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,0DAA4D;AAK5D,kEAAkE;AAiClE;;;GAGG;AACH,MAAa,6BAA6B;IAMxC,YAA2B,aAAoC,EAAU,SAAgC;QAA9E,kBAAa,GAAb,aAAa,CAAuB;QAAU,cAAS,GAAT,SAAS,CAAuB;QALlG,kBAAa,GAAG,IAAI,8CAAuB,EAAE,CAAC;QAC7C,0BAAqB,GAA8C,SAAS,CAAC;QAKnF,IAAI,CAAC,6BAA6B,GAAG,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC,WAAW,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC,qBAAqB,GAAG,SAAS,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;QACpK,IAAI,CAAC,2BAA2B,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,WAAW,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC,qBAAqB,GAAG,SAAS,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;IACtK,CAAC;IAEM,OAAO;QACZ,IAAI,CAAC,2BAA2B,EAAE,CAAC;QACnC,IAAI,CAAC,6BAA6B,EAAE,CAAC;IACvC,CAAC;IAEM,KAAK,CAAC,OAAO;QAClB,IAAI,IAA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C","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*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport type { PropertyRecord, PropertyValue} from \"@itwin/appui-abstract\";\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\nimport type { IDisposable } from \"@itwin/core-bentley\";\nimport type { HighlightInfo } from \"../../common/HighlightingComponentProps\";\nimport type { CategoryRecordsDict } from \"../internal/flat-items/MutableGridCategory\";\nimport type { IPropertyDataProvider, PropertyCategory, PropertyData} from \"../PropertyDataProvider\";\nimport { PropertyDataChangeEvent } from \"../PropertyDataProvider\";\nimport type { FilteredType, IPropertyDataFilterer, PropertyDataFilterResult } from \"./filterers/PropertyDataFiltererBase\";\n\ninterface FilteredRecords {\n filteredRecords: PropertyRecord[];\n shouldExpandNodeParents: boolean;\n matchesCount: number;\n activeMatch?: HighlightInfo;\n filteredResultMatches: { id: string, matchesCount: number }[];\n filteredTypes: FilteredType[];\n}\n\n/**\n * Data returned by [[FilteringPropertyDataProvider]]\n * @public\n */\nexport interface FilteredPropertyData extends PropertyData {\n /**\n * Shows how many matches were found when filtering data.\n * `undefined` when filterer is not active\n */\n matchesCount?: number;\n\n /**\n * Function used for getting [[HighlightInfo]] by index from all the filtered matches.\n * `undefined` when filterer is not active\n */\n getMatchByIndex?: (index: number) => HighlightInfo | undefined;\n\n /** Types of objects that were used for filtering. */\n filteredTypes?: FilteredType[];\n}\n\n/**\n * [[IPropertyDataProvider]] implementation which filters wrapped provider [[PropertyData]] using passed [[IPropertyDataFilterer]].\n * @public\n */\nexport class FilteringPropertyDataProvider implements IPropertyDataProvider, IDisposable {\n public onDataChanged = new PropertyDataChangeEvent();\n private _filteredPropertyData: Promise<FilteredPropertyData> | undefined = undefined;\n private _disposeFilterChangedListener: Function;\n private _disposeDataChangedListener: Function;\n\n public constructor(private _dataProvider: IPropertyDataProvider, private _filterer: IPropertyDataFilterer) {\n this._disposeFilterChangedListener = this._filterer.onFilterChanged.addListener(() => { this._filteredPropertyData = undefined; this.onDataChanged.raiseEvent(); });\n this._disposeDataChangedListener = this._dataProvider.onDataChanged.addListener(() => { this._filteredPropertyData = undefined; this.onDataChanged.raiseEvent(); });\n }\n\n public dispose(): void {\n this._disposeDataChangedListener();\n this._disposeFilterChangedListener();\n }\n\n public async getData(): Promise<FilteredPropertyData> {\n if (this._filteredPropertyData) {\n return this._filteredPropertyData;\n }\n\n this._filteredPropertyData = this._dataProvider.getData().then(async (propertyData) => {\n return ((this._filterer.isActive) ?\n this.filterPropertyData(propertyData) : propertyData);\n });\n\n return this._filteredPropertyData;\n }\n\n private async filterPropertyData(propertyData: PropertyData) {\n const { categories, records, label, description } = { ...propertyData };\n const { filteredCategories, filteredRecords, matchesCount, filteredResultMatches, filteredTypes } = await matchHierarchy(this._filterer, categories, records, undefined);\n\n const uniqueTypes = [...new Set(filteredTypes)];\n const getMatchByIndex = (index: number) => {\n let activeMatch: HighlightInfo | undefined;\n if (index <= 0)\n return undefined;\n\n let i = 1;\n for (const record of filteredResultMatches) {\n const fullMatchesCount = record.matchesCount;\n if (index < i + fullMatchesCount) {\n activeMatch = {\n highlightedItemIdentifier: record.id,\n highlightIndex: index - i,\n };\n break;\n }\n\n i += fullMatchesCount;\n }\n return activeMatch;\n };\n\n return {\n label,\n description,\n categories: filteredCategories,\n records: filteredRecords,\n reusePropertyDataState: false,\n matchesCount,\n getMatchByIndex,\n filteredTypes: uniqueTypes,\n };\n }\n}\n\nasync function matchHierarchy(filterer: IPropertyDataFilterer, categories: PropertyCategory[], records: CategoryRecordsDict, newRecords?: CategoryRecordsDict, parentMatchInfo?: PropertyDataFilterResult) {\n const newCategories: PropertyCategory[] = [];\n newRecords = newRecords ?? {};\n let matchesCount = 0;\n let allFilteredResultMatches: { id: string, matchesCount: number }[] = [];\n let allFilteredTypes: FilteredType[] = [];\n\n for (const category of categories) {\n const matchInfo = await filterer.categoryMatchesFilter(category, []);\n\n if (matchInfo.matchesFilter) {\n allFilteredResultMatches.push({ id: category.name, matchesCount: matchInfo.matchesCount ?? 0 });\n allFilteredTypes = allFilteredTypes.concat(matchInfo.filteredTypes ?? []);\n matchesCount += matchInfo.matchesCount ?? 0;\n }\n\n const childRecords = records[category.name] ?? [];\n const { filteredRecords, matchesCount: count, filteredResultMatches, filteredTypes } = await matchRecordHierarchy(filterer, childRecords, []);\n allFilteredResultMatches = allFilteredResultMatches.concat(filteredResultMatches);\n allFilteredTypes = allFilteredTypes.concat(filteredTypes);\n matchesCount += count;\n\n const parentInfo = parentMatchInfo?.matchesFilter ? parentMatchInfo : matchInfo;\n\n const childCategories = category.childCategories ?? [];\n const { filteredCategories, matchesCount: childCount, filteredResultMatches: childFilteredResultMatches, filteredTypes: childFilteredTypes } = await matchHierarchy(filterer, childCategories, records, newRecords, parentInfo);\n allFilteredResultMatches = allFilteredResultMatches.concat(childFilteredResultMatches);\n allFilteredTypes = allFilteredTypes.concat(childFilteredTypes);\n matchesCount += childCount;\n\n let expand = !(count === 0 && childCount === 0);\n if (matchInfo.matchesFilter || (parentMatchInfo?.matchesFilter && parentMatchInfo.shouldForceIncludeDescendants)) {\n newRecords[category.name] = records[category.name];\n if (matchInfo.matchesFilter) {\n expand = true;\n }\n const newCategory = copyPropertyCategory(category, filteredCategories, expand);\n newCategories.push(newCategory);\n }\n\n if ((filteredRecords.length !== 0 || filteredCategories.length !== 0) && !matchInfo.matchesFilter && !(parentMatchInfo?.shouldExpandNodeParents && parentMatchInfo.matchesFilter)) {\n const newCategory = copyPropertyCategory(category, filteredCategories, expand);\n newRecords[newCategory.name] = filteredRecords;\n newCategories.push(newCategory);\n }\n }\n\n return { filteredCategories: newCategories, filteredRecords: newRecords, matchesCount, filteredResultMatches: allFilteredResultMatches, filteredTypes: allFilteredTypes };\n}\n\nasync function matchRecordHierarchy(filterer: IPropertyDataFilterer, records: PropertyRecord[], parents: PropertyRecord[], forceIncludeItem: boolean = false): Promise<FilteredRecords> {\n const newMatchedRecords: PropertyRecord[] = [];\n let expandParent = false; // property passed back to parent to indicate whether it should be expanded\n let matchesCount = 0;\n let filteredResultMatches: { id: string, matchesCount: number }[] = [];\n let filteredTypes: FilteredType[] = [];\n\n for (const record of records) {\n const matchInfo = await filterer.recordMatchesFilter(record, parents);\n const shouldForceIncludeDescendants = forceIncludeItem || matchInfo.shouldForceIncludeDescendants;\n const { filteredRecords: filteredChildren, shouldExpandNodeParents, matchesCount: childrenMatchesCount, filteredResultMatches: childrenResultMatches, filteredTypes: childrenFilteredTypes } = await matchRecordHierarchy(filterer, record.getChildrenRecords(), [...parents, record], shouldForceIncludeDescendants);\n filteredResultMatches = filteredResultMatches.concat(childrenResultMatches);\n filteredTypes = [...filteredTypes, ...childrenFilteredTypes];\n matchesCount += childrenMatchesCount;\n // if child hierarchy indicates parents should be expanded, then it should be passed back up to the top parent\n expandParent = expandParent || shouldExpandNodeParents;\n\n let newRecord: PropertyRecord | undefined;\n if (matchInfo.matchesFilter) {\n filteredTypes = [...filteredTypes, ...(matchInfo.filteredTypes ?? [])];\n const recordMatchesCount = matchInfo.matchesCount ?? 0;\n matchesCount += recordMatchesCount;\n // Item is included if it matches filter\n // If at least one matched record from records list needs its parent expanded,\n // then `expandParent` should be set to true\n expandParent = expandParent || !!matchInfo.shouldExpandNodeParents;\n newRecord = copyPropertyRecord(record, filteredChildren, shouldExpandNodeParents);\n filteredResultMatches.push({ id: newRecord.property.name, matchesCount: recordMatchesCount });\n } else if (filteredChildren.length !== 0 || forceIncludeItem) {\n // Item is also included if it has at least one matched child or is forcefully included by its parent\n newRecord = copyPropertyRecord(record, filteredChildren, shouldExpandNodeParents);\n }\n\n if (newRecord)\n newMatchedRecords.push(newRecord);\n }\n\n return { filteredRecords: newMatchedRecords, shouldExpandNodeParents: expandParent, matchesCount, filteredResultMatches, filteredTypes };\n}\n\nfunction copyPropertyCategory(\n propertyCategory: PropertyCategory,\n newChildren: PropertyCategory[],\n expand: boolean,\n): PropertyCategory {\n return {\n ...propertyCategory,\n childCategories: newChildren,\n expand,\n };\n}\n\nfunction copyPropertyRecord(record: PropertyRecord, newChildren: PropertyRecord[], autoExpand: boolean) {\n const r = record.copyWithNewValue(createNewPropertyValue(record.value, newChildren));\n r.autoExpand = autoExpand;\n return r;\n}\n\nfunction createNewPropertyValue(value: PropertyValue, newChildren: PropertyRecord[]): PropertyValue {\n switch (value.valueFormat) {\n case PropertyValueFormat.Primitive:\n return { ...value };\n case PropertyValueFormat.Array:\n return {\n valueFormat: PropertyValueFormat.Array,\n itemsTypeName: value.itemsTypeName,\n items: newChildren,\n };\n case PropertyValueFormat.Struct:\n const members: { [name: string]: PropertyRecord } = {};\n newChildren.forEach((child) => members[child.property.name] = child);\n return {\n valueFormat: PropertyValueFormat.Struct,\n members,\n };\n }\n}\n"]}
1
+ {"version":3,"file":"FilteringDataProvider.js","sourceRoot":"","sources":["../../../../../src/components-react/propertygrid/dataproviders/FilteringDataProvider.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,0DAA4D;AAK5D,kEAAkE;AAiClE;;;GAGG;AACH,MAAa,6BAA6B;IAMxC,YAA2B,aAAoC,EAAU,SAAgC;QAA9E,kBAAa,GAAb,aAAa,CAAuB;QAAU,cAAS,GAAT,SAAS,CAAuB;QALlG,kBAAa,GAAG,IAAI,8CAAuB,EAAE,CAAC;QAC7C,0BAAqB,GAA8C,SAAS,CAAC;QAKnF,IAAI,CAAC,6BAA6B,GAAG,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC,WAAW,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC,qBAAqB,GAAG,SAAS,CAAC,CAAC,IAAI,CAAC,aAAa,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;QACpK,IAAI,CAAC,2BAA2B,GAAG,IAAI,CAAC,aAAa,CAAC,aAAa,CAAC,WAAW,CAAC,GAAG,EAAE,GAAG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AAM;YAC7B,MAAM,OAAO,GAAuC,EAAE,CAAC;YACvD,WAAW,CAAC,OAAO,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,CAAC;YACrE,OAAO;gBACL,WAAW,EAAE,oCAAmB,CAAC,MAAM;gBACvC,OAAO;aACR,CAAC;KACL;AACH,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport type { PropertyRecord, PropertyValue} from \"@itwin/appui-abstract\";\r\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\r\nimport type { IDisposable } from \"@itwin/core-bentley\";\r\nimport type { HighlightInfo } from \"../../common/HighlightingComponentProps\";\r\nimport type { CategoryRecordsDict } from \"../internal/flat-items/MutableGridCategory\";\r\nimport type { IPropertyDataProvider, PropertyCategory, PropertyData} from \"../PropertyDataProvider\";\r\nimport { PropertyDataChangeEvent } from \"../PropertyDataProvider\";\r\nimport type { FilteredType, IPropertyDataFilterer, PropertyDataFilterResult } from \"./filterers/PropertyDataFiltererBase\";\r\n\r\ninterface FilteredRecords {\r\n filteredRecords: PropertyRecord[];\r\n shouldExpandNodeParents: boolean;\r\n matchesCount: number;\r\n activeMatch?: HighlightInfo;\r\n filteredResultMatches: { id: string, matchesCount: number }[];\r\n filteredTypes: FilteredType[];\r\n}\r\n\r\n/**\r\n * Data returned by [[FilteringPropertyDataProvider]]\r\n * @public\r\n */\r\nexport interface FilteredPropertyData extends PropertyData {\r\n /**\r\n * Shows how many matches were found when filtering data.\r\n * `undefined` when filterer is not active\r\n */\r\n matchesCount?: number;\r\n\r\n /**\r\n * Function used for getting [[HighlightInfo]] by index from all the filtered matches.\r\n * `undefined` when filterer is not active\r\n */\r\n getMatchByIndex?: (index: number) => HighlightInfo | undefined;\r\n\r\n /** Types of objects that were used for filtering. */\r\n filteredTypes?: FilteredType[];\r\n}\r\n\r\n/**\r\n * [[IPropertyDataProvider]] implementation which filters wrapped provider [[PropertyData]] using passed [[IPropertyDataFilterer]].\r\n * @public\r\n */\r\nexport class FilteringPropertyDataProvider implements IPropertyDataProvider, IDisposable {\r\n public onDataChanged = new PropertyDataChangeEvent();\r\n private _filteredPropertyData: Promise<FilteredPropertyData> | undefined = undefined;\r\n private _disposeFilterChangedListener: Function;\r\n private _disposeDataChangedListener: Function;\r\n\r\n public constructor(private _dataProvider: IPropertyDataProvider, private _filterer: IPropertyDataFilterer) {\r\n this._disposeFilterChangedListener = this._filterer.onFilterChanged.addListener(() => { this._filteredPropertyData = undefined; this.onDataChanged.raiseEvent(); });\r\n this._disposeDataChangedListener = this._dataProvider.onDataChanged.addListener(() => { this._filteredPropertyData = undefined; this.onDataChanged.raiseEvent(); });\r\n }\r\n\r\n public dispose(): void {\r\n this._disposeDataChangedListener();\r\n this._disposeFilterChangedListener();\r\n }\r\n\r\n public async getData(): Promise<FilteredPropertyData> {\r\n if (this._filteredPropertyData) {\r\n return this._filteredPropertyData;\r\n }\r\n\r\n this._filteredPropertyData = this._dataProvider.getData().then(async (propertyData) => {\r\n return ((this._filterer.isActive) ?\r\n this.filterPropertyData(propertyData) : propertyData);\r\n });\r\n\r\n return this._filteredPropertyData;\r\n }\r\n\r\n private async filterPropertyData(propertyData: PropertyData) {\r\n const { categories, records, label, description } = { ...propertyData };\r\n const { filteredCategories, filteredRecords, matchesCount, filteredResultMatches, filteredTypes } = await matchHierarchy(this._filterer, categories, records, undefined);\r\n\r\n const uniqueTypes = [...new Set(filteredTypes)];\r\n const getMatchByIndex = (index: number) => {\r\n let activeMatch: HighlightInfo | undefined;\r\n if (index <= 0)\r\n return undefined;\r\n\r\n let i = 1;\r\n for (const record of filteredResultMatches) {\r\n const fullMatchesCount = record.matchesCount;\r\n if (index < i + fullMatchesCount) {\r\n activeMatch = {\r\n highlightedItemIdentifier: record.id,\r\n highlightIndex: index - i,\r\n };\r\n break;\r\n }\r\n\r\n i += fullMatchesCount;\r\n }\r\n return activeMatch;\r\n };\r\n\r\n return {\r\n label,\r\n description,\r\n categories: filteredCategories,\r\n records: filteredRecords,\r\n reusePropertyDataState: false,\r\n matchesCount,\r\n getMatchByIndex,\r\n filteredTypes: uniqueTypes,\r\n };\r\n }\r\n}\r\n\r\nasync function matchHierarchy(filterer: IPropertyDataFilterer, categories: PropertyCategory[], records: CategoryRecordsDict, newRecords?: CategoryRecordsDict, parentMatchInfo?: PropertyDataFilterResult) {\r\n const newCategories: PropertyCategory[] = [];\r\n newRecords = newRecords ?? {};\r\n let matchesCount = 0;\r\n let allFilteredResultMatches: { id: string, matchesCount: number }[] = [];\r\n let allFilteredTypes: FilteredType[] = [];\r\n\r\n for (const category of categories) {\r\n const matchInfo = await filterer.categoryMatchesFilter(category, []);\r\n\r\n if (matchInfo.matchesFilter) {\r\n allFilteredResultMatches.push({ id: category.name, matchesCount: matchInfo.matchesCount ?? 0 });\r\n allFilteredTypes = allFilteredTypes.concat(matchInfo.filteredTypes ?? []);\r\n matchesCount += matchInfo.matchesCount ?? 0;\r\n }\r\n\r\n const childRecords = records[category.name] ?? [];\r\n const { filteredRecords, matchesCount: count, filteredResultMatches, filteredTypes } = await matchRecordHierarchy(filterer, childRecords, []);\r\n allFilteredResultMatches = allFilteredResultMatches.concat(filteredResultMatches);\r\n allFilteredTypes = allFilteredTypes.concat(filteredTypes);\r\n matchesCount += count;\r\n\r\n const parentInfo = parentMatchInfo?.matchesFilter ? parentMatchInfo : matchInfo;\r\n\r\n const childCategories = category.childCategories ?? [];\r\n const { filteredCategories, matchesCount: childCount, filteredResultMatches: childFilteredResultMatches, filteredTypes: childFilteredTypes } = await matchHierarchy(filterer, childCategories, records, newRecords, parentInfo);\r\n allFilteredResultMatches = allFilteredResultMatches.concat(childFilteredResultMatches);\r\n allFilteredTypes = allFilteredTypes.concat(childFilteredTypes);\r\n matchesCount += childCount;\r\n\r\n let expand = !(count === 0 && childCount === 0);\r\n if (matchInfo.matchesFilter || (parentMatchInfo?.matchesFilter && parentMatchInfo.shouldForceIncludeDescendants)) {\r\n newRecords[category.name] = records[category.name];\r\n if (matchInfo.matchesFilter) {\r\n expand = true;\r\n }\r\n const newCategory = copyPropertyCategory(category, filteredCategories, expand);\r\n newCategories.push(newCategory);\r\n }\r\n\r\n if ((filteredRecords.length !== 0 || filteredCategories.length !== 0) && !matchInfo.matchesFilter && !(parentMatchInfo?.shouldExpandNodeParents && parentMatchInfo.matchesFilter)) {\r\n const newCategory = copyPropertyCategory(category, filteredCategories, expand);\r\n newRecords[newCategory.name] = filteredRecords;\r\n newCategories.push(newCategory);\r\n }\r\n }\r\n\r\n return { filteredCategories: newCategories, filteredRecords: newRecords, matchesCount, filteredResultMatches: allFilteredResultMatches, filteredTypes: allFilteredTypes };\r\n}\r\n\r\nasync function matchRecordHierarchy(filterer: IPropertyDataFilterer, records: PropertyRecord[], parents: PropertyRecord[], forceIncludeItem: boolean = false): Promise<FilteredRecords> {\r\n const newMatchedRecords: PropertyRecord[] = [];\r\n let expandParent = false; // property passed back to parent to indicate whether it should be expanded\r\n let matchesCount = 0;\r\n let filteredResultMatches: { id: string, matchesCount: number }[] = [];\r\n let filteredTypes: FilteredType[] = [];\r\n\r\n for (const record of records) {\r\n const matchInfo = await filterer.recordMatchesFilter(record, parents);\r\n const shouldForceIncludeDescendants = forceIncludeItem || matchInfo.shouldForceIncludeDescendants;\r\n const { filteredRecords: filteredChildren, shouldExpandNodeParents, matchesCount: childrenMatchesCount, filteredResultMatches: childrenResultMatches, filteredTypes: childrenFilteredTypes } = await matchRecordHierarchy(filterer, record.getChildrenRecords(), [...parents, record], shouldForceIncludeDescendants);\r\n filteredResultMatches = filteredResultMatches.concat(childrenResultMatches);\r\n filteredTypes = [...filteredTypes, ...childrenFilteredTypes];\r\n matchesCount += childrenMatchesCount;\r\n // if child hierarchy indicates parents should be expanded, then it should be passed back up to the top parent\r\n expandParent = expandParent || shouldExpandNodeParents;\r\n\r\n let newRecord: PropertyRecord | undefined;\r\n if (matchInfo.matchesFilter) {\r\n filteredTypes = [...filteredTypes, ...(matchInfo.filteredTypes ?? [])];\r\n const recordMatchesCount = matchInfo.matchesCount ?? 0;\r\n matchesCount += recordMatchesCount;\r\n // Item is included if it matches filter\r\n // If at least one matched record from records list needs its parent expanded,\r\n // then `expandParent` should be set to true\r\n expandParent = expandParent || !!matchInfo.shouldExpandNodeParents;\r\n newRecord = copyPropertyRecord(record, filteredChildren, shouldExpandNodeParents);\r\n filteredResultMatches.push({ id: newRecord.property.name, matchesCount: recordMatchesCount });\r\n } else if (filteredChildren.length !== 0 || forceIncludeItem) {\r\n // Item is also included if it has at least one matched child or is forcefully included by its parent\r\n newRecord = copyPropertyRecord(record, filteredChildren, shouldExpandNodeParents);\r\n }\r\n\r\n if (newRecord)\r\n newMatchedRecords.push(newRecord);\r\n }\r\n\r\n return { filteredRecords: newMatchedRecords, shouldExpandNodeParents: expandParent, matchesCount, filteredResultMatches, filteredTypes };\r\n}\r\n\r\nfunction copyPropertyCategory(\r\n propertyCategory: PropertyCategory,\r\n newChildren: PropertyCategory[],\r\n expand: boolean,\r\n): PropertyCategory {\r\n return {\r\n ...propertyCategory,\r\n childCategories: newChildren,\r\n expand,\r\n };\r\n}\r\n\r\nfunction copyPropertyRecord(record: PropertyRecord, newChildren: PropertyRecord[], autoExpand: boolean) {\r\n const r = record.copyWithNewValue(createNewPropertyValue(record.value, newChildren));\r\n r.autoExpand = autoExpand;\r\n return r;\r\n}\r\n\r\nfunction createNewPropertyValue(value: PropertyValue, newChildren: PropertyRecord[]): PropertyValue {\r\n switch (value.valueFormat) {\r\n case PropertyValueFormat.Primitive:\r\n return { ...value };\r\n case PropertyValueFormat.Array:\r\n return {\r\n valueFormat: PropertyValueFormat.Array,\r\n itemsTypeName: value.itemsTypeName,\r\n items: newChildren,\r\n };\r\n case PropertyValueFormat.Struct:\r\n const members: { [name: string]: PropertyRecord } = {};\r\n newChildren.forEach((child) => members[child.property.name] = child);\r\n return {\r\n valueFormat: PropertyValueFormat.Struct,\r\n members,\r\n };\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"CompositePropertyDataFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/CompositePropertyDataFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAKH,yEAAsE;AAEtE;;;GAGG;AACH,IAAY,mBAGX;AAHD,WAAY,mBAAmB;IAC7B,2DAAG,CAAA;IACH,yDAAE,CAAA;AACJ,CAAC,EAHW,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAG9B;AAED;;;GAGG;AACH,MAAa,6BAA8B,SAAQ,mDAAwB;IACzE,YAA2B,aAAoC,EAAU,SAA8B,EAAU,cAAqC;QACpJ,KAAK,EAAE,CAAC;QADiB,kBAAa,GAAb,aAAa,CAAuB;QAAU,cAAS,GAAT,SAAS,CAAqB;QAAU,mBAAc,GAAd,cAAc,CAAuB;QAEpJ,IAAI,CAAC,aAAa,CAAC,eAAe,CAAC,WAAW,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC,CAAC;QACxF,IAAI,CAAC,cAAc,CAAC,eAAe,CAAC,WAAW,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC,CAAC;IAC3F,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,aAAa,CAAC,QAAQ,IAAI,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,CAAC,CAAC;IAEtF,KAAK,CAAC,mBAAmB,CAAC,IAAoB,EAAE,OAAyB;QAC9E,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;YACnC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uB,IAAI,GAAG,CAAC,uBAAuB;YACnF,6BAA6B,EAAE,GAAG,CAAC,6BAA6B,IAAI,GAAG,CAAC,6BAA6B;YACrG,YAAY,EAAE,CAAC,kBAAkB,CAAC,GAAG,CAAC,YAAY,EAAE,GAAG,CAAC,YAAY,CAAC,CAAC;YACtE,aAAa;SACd,CAAC;IACJ,CAAC;CACF;AA1CD,sEA0CC;AAED,SAAS,kBAAkB,CAAC,GAAuB,EAAE,GAAuB;IAC1E,IAAI,SAAS,KAAK,GAAG,IAAI,SAAS,KAAK,GAAG;QACxC,OAAO,SAAS,CAAC;IACnB,OAAO,CAAC,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,CAAC,CAAC,GAAG,CAAC,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,CAAC,CAAC,CAAC;AACjC,CAAC;AAED,SAAS,kBAAkB,CAAC,GAA+B,EAAE,GAA+B;IAC1F,IAAI,SAAS,KAAK,GAAG,IAAI,SAAS,KAAK,GAAG;QACxC,OAAO,SAAS,CAAC;IACnB,OAAO,CAAC,GAAG,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,EAAE,EAAE,GAAG,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,EAAE,CAAC,CAAC;AACtC,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*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\nimport type { PropertyCategory } from \"../../PropertyDataProvider\";\nimport type { FilteredType, IPropertyDataFilterer, PropertyDataFilterResult } from \"./PropertyDataFiltererBase\";\nimport { PropertyDataFiltererBase } from \"./PropertyDataFiltererBase\";\n\n/**\n * Logical operator for composite filterer.\n * @public\n */\nexport enum CompositeFilterType {\n And,\n Or,\n}\n\n/**\n * Composite PropertyData filter which can join two filters using logic operators\n * @public\n */\nexport class CompositePropertyDataFilterer extends PropertyDataFiltererBase {\n public constructor(private _leftFilterer: IPropertyDataFilterer, private _operator: CompositeFilterType, private _rightFilterer: IPropertyDataFilterer) {\n super();\n this._leftFilterer.onFilterChanged.addListener(() => this.onFilterChanged.raiseEvent());\n this._rightFilterer.onFilterChanged.addListener(() => this.onFilterChanged.raiseEvent());\n }\n\n public get isActive() { return this._leftFilterer.isActive || this._rightFilterer.isActive; }\n\n public async recordMatchesFilter(node: PropertyRecord, parents: PropertyRecord[]): Promise<PropertyDataFilterResult> {\n const [lhs, rhs] = await Promise.all([\n this._leftFilterer.recordMatchesFilter(node, parents),\n this._rightFilterer.recordMatchesFilter(node, parents),\n ]);\n\n return this.getFiltererResult(lhs, rhs);\n }\n\n public async categoryMatchesFilter(node: PropertyCategory, parents: PropertyCategory[]): Promise<PropertyDataFilterResult> {\n const [lhs, rhs] = await Promise.all([\n this._leftFilterer.categoryMatchesFilter(node, parents),\n this._rightFilterer.categoryMatchesFilter(node, parents),\n ]);\n\n return this.getFiltererResult(lhs, rhs);\n }\n\n private getFiltererResult(lhs: PropertyDataFilterResult, rhs: PropertyDataFilterResult) {\n const matchesFilter = (this._operator === CompositeFilterType.And) ? (lhs.matchesFilter && rhs.matchesFilter) : (lhs.matchesFilter || rhs.matchesFilter);\n if (!matchesFilter)\n return { matchesFilter: false };\n\n const filteredTypes = joinNullableArrays(lhs.matchesFilter ? lhs.filteredTypes : undefined, rhs.matchesFilter ? rhs.filteredTypes : undefined);\n\n return {\n matchesFilter: true,\n shouldExpandNodeParents: lhs.shouldExpandNodeParents || rhs.shouldExpandNodeParents,\n shouldForceIncludeDescendants: lhs.shouldForceIncludeDescendants || rhs.shouldForceIncludeDescendants,\n matchesCount: (sumNullableNumbers(lhs.matchesCount, rhs.matchesCount)),\n filteredTypes,\n };\n }\n}\n\nfunction sumNullableNumbers(lhs: number | undefined, rhs: number | undefined) {\n if (undefined === lhs && undefined === rhs)\n return undefined;\n return (lhs ?? 0) + (rhs ?? 0);\n}\n\nfunction joinNullableArrays(lhs: FilteredType[] | undefined, rhs: FilteredType[] | undefined) {\n if (undefined === lhs && undefined === rhs)\n return undefined;\n return [...lhs ?? [], ...rhs ?? []];\n}\n"]}
1
+ {"version":3,"file":"CompositePropertyDataFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/CompositePropertyDataFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAKH,yEAAsE;AAEtE;;;GAGG;AACH,IAAY,mBAGX;AAHD,WAAY,mBAAmB;IAC7B,2DAAG,CAAA;IACH,yDAAE,CAAA;AACJ,CAAC,EAHW,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAG9B;AAED;;;GAGG;AACH,MAAa,6BAA8B,SAAQ,mDAAwB;IACzE,YAA2B,aAAoC,EAAU,SAA8B,EAAU,cAAqC;QACpJ,KAAK,EAAE,CAAC;QADiB,kBAAa,GAAb,aAAa,CAAuB;QAAU,cAAS,GAAT,SAAS,CAAqB;QAAU,mBAAc,GAAd,cAAc,CAAuB;QAEpJ,IAAI,CAAC,aAAa,CAAC,eAAe,CAAC,WAAW,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC,CAAC;QACxF,IAAI,CAAC,cAAc,CAAC,eAAe,CAAC,WAAW,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC,CAAC;IAC3F,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,aAAa,CAAC,QAAQ,IAAI,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,CAAC,CAAC;IAEtF,KAAK,CAAC,mBAAmB,CAAC,IAAoB,EAAE,OAAyB;QAC9E,MAAM,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;YACnC,IAAI,CAAC,aAAa,CAAC,mB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B;YACnF,6BAA6B,EAAE,GAAG,CAAC,6BAA6B,IAAI,GAAG,CAAC,6BAA6B;YACrG,YAAY,EAAE,CAAC,kBAAkB,CAAC,GAAG,CAAC,YAAY,EAAE,GAAG,CAAC,YAAY,CAAC,CAAC;YACtE,aAAa;SACd,CAAC;IACJ,CAAC;CACF;AA1CD,sEA0CC;AAED,SAAS,kBAAkB,CAAC,GAAuB,EAAE,GAAuB;IAC1E,IAAI,SAAS,KAAK,GAAG,IAAI,SAAS,KAAK,GAAG;QACxC,OAAO,SAAS,CAAC;IACnB,OAAO,CAAC,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,CAAC,CAAC,GAAG,CAAC,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,CAAC,CAAC,CAAC;AACjC,CAAC;AAED,SAAS,kBAAkB,CAAC,GAA+B,EAAE,GAA+B;IAC1F,IAAI,SAAS,KAAK,GAAG,IAAI,SAAS,KAAK,GAAG;QACxC,OAAO,SAAS,CAAC;IACnB,OAAO,CAAC,GAAG,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,EAAE,EAAE,GAAG,GAAG,aAAH,GAAG,cAAH,GAAG,GAAI,EAAE,CAAC,CAAC;AACtC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\r\nimport type { PropertyCategory } from \"../../PropertyDataProvider\";\r\nimport type { FilteredType, IPropertyDataFilterer, PropertyDataFilterResult } from \"./PropertyDataFiltererBase\";\r\nimport { PropertyDataFiltererBase } from \"./PropertyDataFiltererBase\";\r\n\r\n/**\r\n * Logical operator for composite filterer.\r\n * @public\r\n */\r\nexport enum CompositeFilterType {\r\n And,\r\n Or,\r\n}\r\n\r\n/**\r\n * Composite PropertyData filter which can join two filters using logic operators\r\n * @public\r\n */\r\nexport class CompositePropertyDataFilterer extends PropertyDataFiltererBase {\r\n public constructor(private _leftFilterer: IPropertyDataFilterer, private _operator: CompositeFilterType, private _rightFilterer: IPropertyDataFilterer) {\r\n super();\r\n this._leftFilterer.onFilterChanged.addListener(() => this.onFilterChanged.raiseEvent());\r\n this._rightFilterer.onFilterChanged.addListener(() => this.onFilterChanged.raiseEvent());\r\n }\r\n\r\n public get isActive() { return this._leftFilterer.isActive || this._rightFilterer.isActive; }\r\n\r\n public async recordMatchesFilter(node: PropertyRecord, parents: PropertyRecord[]): Promise<PropertyDataFilterResult> {\r\n const [lhs, rhs] = await Promise.all([\r\n this._leftFilterer.recordMatchesFilter(node, parents),\r\n this._rightFilterer.recordMatchesFilter(node, parents),\r\n ]);\r\n\r\n return this.getFiltererResult(lhs, rhs);\r\n }\r\n\r\n public async categoryMatchesFilter(node: PropertyCategory, parents: PropertyCategory[]): Promise<PropertyDataFilterResult> {\r\n const [lhs, rhs] = await Promise.all([\r\n this._leftFilterer.categoryMatchesFilter(node, parents),\r\n this._rightFilterer.categoryMatchesFilter(node, parents),\r\n ]);\r\n\r\n return this.getFiltererResult(lhs, rhs);\r\n }\r\n\r\n private getFiltererResult(lhs: PropertyDataFilterResult, rhs: PropertyDataFilterResult) {\r\n const matchesFilter = (this._operator === CompositeFilterType.And) ? (lhs.matchesFilter && rhs.matchesFilter) : (lhs.matchesFilter || rhs.matchesFilter);\r\n if (!matchesFilter)\r\n return { matchesFilter: false };\r\n\r\n const filteredTypes = joinNullableArrays(lhs.matchesFilter ? lhs.filteredTypes : undefined, rhs.matchesFilter ? rhs.filteredTypes : undefined);\r\n\r\n return {\r\n matchesFilter: true,\r\n shouldExpandNodeParents: lhs.shouldExpandNodeParents || rhs.shouldExpandNodeParents,\r\n shouldForceIncludeDescendants: lhs.shouldForceIncludeDescendants || rhs.shouldForceIncludeDescendants,\r\n matchesCount: (sumNullableNumbers(lhs.matchesCount, rhs.matchesCount)),\r\n filteredTypes,\r\n };\r\n }\r\n}\r\n\r\nfunction sumNullableNumbers(lhs: number | undefined, rhs: number | undefined) {\r\n if (undefined === lhs && undefined === rhs)\r\n return undefined;\r\n return (lhs ?? 0) + (rhs ?? 0);\r\n}\r\n\r\nfunction joinNullableArrays(lhs: FilteredType[] | undefined, rhs: FilteredType[] | undefined) {\r\n if (undefined === lhs && undefined === rhs)\r\n return undefined;\r\n return [...lhs ?? [], ...rhs ?? []];\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"DisplayValuePropertyDataFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/DisplayValuePropertyDataFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,0DAA4D;AAC5D,+EAA4E;AAE5E,yEAA0F;AAE1F;;;GAGG;AACH,MAAa,gCAAiC,SAAQ,yDAA8B;IAGlF,YAAmB,aAAqB,EAAE;QACxC,KAAK,EAAE,CAAC;QAHF,gBAAW,GAAW,EAAE,CAAC;QAI/B,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;IAChC,CAAC;IAED,IAAW,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5D,IAAW,UAAU,CAAC,KAAa;QACjC,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE;YAClC,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;YAC9B,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;SACnC;IACH,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC;IAEjD,KAAK,CAAC,mBAAmB,CAAC,IAAoB;;QACnD,IAAI,CAAC,IAAI,CAAC,QAAQ;YAChB,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;QAEjC,IAAI,IAAI,CAAC,KAAK,CAAC,WAAW,KAAK,oCAAmB,CAAC,SAAS;YAC1D,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,MAAM,YAAY,GAAG,MAAA,MAAA,IAAI,CAAC,KAAK,CAAC,YAAY,0CAAE,WAAW,EAAE,mCAAI,EAAE,CAAC;QAClE,MAAM,YAAY,GAAG,IAAA,2CAAoB,EAAC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QAEzE,IAAI,YAAY,KAAK,CAAC;YACpB,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,OAAO;YACL,aAAa,EAAE,IAAI;YACnB,uBAAuB,EAAE,IAAI;YAC7B,YAAY;YACZ,aAAa,EAAE,CAAC,uCAAY,CAAC,KAAK,CAAC;SACpC,CAAC;IACJ,CAAC;CACF;AAvCD,4EAuCC","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*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport type { PropertyRecord} from \"@itwin/appui-abstract\";\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\nimport { countMatchesInString } from \"../../../common/countMatchesInString\";\nimport type { PropertyDataFilterResult} from \"./PropertyDataFiltererBase\";\nimport { FilteredType, PropertyRecordDataFiltererBase } from \"./PropertyDataFiltererBase\";\n\n/**\n * Property data filterer which matches on Primitive Property Record display value text.\n * @public\n */\nexport class DisplayValuePropertyDataFilterer extends PropertyRecordDataFiltererBase {\n private _filterText: string = \"\";\n\n public constructor(filterText: string = \"\") {\n super();\n this._filterText = filterText;\n }\n\n public get filterText(): string { return this._filterText; }\n public set filterText(value: string) {\n const lowerValue = value.toLowerCase().trim();\n if (lowerValue !== this.filterText) {\n this._filterText = lowerValue;\n this.onFilterChanged.raiseEvent();\n }\n }\n\n public get isActive() { return this.filterText !== \"\"; }\n\n public async recordMatchesFilter(node: PropertyRecord): Promise<PropertyDataFilterResult> {\n if (!this.isActive)\n return { matchesFilter: true };\n\n if (node.value.valueFormat !== PropertyValueFormat.Primitive)\n return { matchesFilter: false };\n\n const displayValue = node.value.displayValue?.toLowerCase() ?? \"\";\n const matchesCount = countMatchesInString(displayValue, this.filterText);\n\n if (matchesCount === 0)\n return { matchesFilter: false };\n\n return {\n matchesFilter: true,\n shouldExpandNodeParents: true,\n matchesCount,\n filteredTypes: [FilteredType.Value],\n };\n }\n}\n"]}
1
+ {"version":3,"file":"DisplayValuePropertyDataFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/DisplayValuePropertyDataFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,0DAA4D;AAC5D,+EAA4E;AAE5E,yEAA0F;AAE1F;;;GAGG;AACH,MAAa,gCAAiC,SAAQ,yDAA8B;IAGlF,YAAmB,aAAqB,EAAE;QACxC,KAAK,EAAE,CAAC;QAHF,gBAAW,GAAW,EAAE,CAAC;QAI/B,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;IAChC,CAAC;IAED,IAAW,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5D,IAAW,UAAU,CAAC,KAAa;QACjC,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE;YAClC,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;YAC9B,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;SACnC;IACH,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC;IAEjD,KAAK,CAAC,mBAAmB,CAAC,IAAoB;;QACnD,IAAI,CAAC,IAAI,CAAC,QAAQ;YAChB,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;QAEjC,IAAI,IAAI,CAAC,KAAK,CAAC,WAAW,KAAK,oCAAmB,CAAC,SAAS;YAC1D,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,MAAM,YAAY,GAAG,MAAA,MAAA,IAAI,CAAC,KAAK,CAAC,YAAY,0CAAE,WAAW,EAAE,mCAAI,EAAE,CAAC;QAClE,MAAM,YAAY,GAAG,IAAA,2CAAoB,EAAC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QAEzE,IAAI,YAAY,KAAK,CAAC;YACpB,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,OAAO;YACL,aAAa,EAAE,IAAI;YACnB,uBAAuB,EAAE,IAAI;YAC7B,YAAY;YACZ,aAAa,EAAE,CAAC,uCAAY,CAAC,KAAK,CAAC;SACpC,CAAC;IACJ,CAAC;CACF;AAvCD,4EAuCC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport type { PropertyRecord} from \"@itwin/appui-abstract\";\r\nimport { PropertyValueFormat } from \"@itwin/appui-abstract\";\r\nimport { countMatchesInString } from \"../../../common/countMatchesInString\";\r\nimport type { PropertyDataFilterResult} from \"./PropertyDataFiltererBase\";\r\nimport { FilteredType, PropertyRecordDataFiltererBase } from \"./PropertyDataFiltererBase\";\r\n\r\n/**\r\n * Property data filterer which matches on Primitive Property Record display value text.\r\n * @public\r\n */\r\nexport class DisplayValuePropertyDataFilterer extends PropertyRecordDataFiltererBase {\r\n private _filterText: string = \"\";\r\n\r\n public constructor(filterText: string = \"\") {\r\n super();\r\n this._filterText = filterText;\r\n }\r\n\r\n public get filterText(): string { return this._filterText; }\r\n public set filterText(value: string) {\r\n const lowerValue = value.toLowerCase().trim();\r\n if (lowerValue !== this.filterText) {\r\n this._filterText = lowerValue;\r\n this.onFilterChanged.raiseEvent();\r\n }\r\n }\r\n\r\n public get isActive() { return this.filterText !== \"\"; }\r\n\r\n public async recordMatchesFilter(node: PropertyRecord): Promise<PropertyDataFilterResult> {\r\n if (!this.isActive)\r\n return { matchesFilter: true };\r\n\r\n if (node.value.valueFormat !== PropertyValueFormat.Primitive)\r\n return { matchesFilter: false };\r\n\r\n const displayValue = node.value.displayValue?.toLowerCase() ?? \"\";\r\n const matchesCount = countMatchesInString(displayValue, this.filterText);\r\n\r\n if (matchesCount === 0)\r\n return { matchesFilter: false };\r\n\r\n return {\r\n matchesFilter: true,\r\n shouldExpandNodeParents: true,\r\n matchesCount,\r\n filteredTypes: [FilteredType.Value],\r\n };\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"LabelPropertyDataFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/LabelPropertyDataFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,+EAA4E;AAE5E,yEAA0F;AAE1F;;;GAGG;AACH,MAAa,yBAA0B,SAAQ,yDAA8B;IAG3E,YAAmB,aAAqB,EAAE;QACxC,KAAK,EAAE,CAAC;QAHF,gBAAW,GAAW,EAAE,CAAC;QAI/B,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;IAChC,CAAC;IAED,IAAW,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5D,IAAW,UAAU,CAAC,KAAa;QACjC,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE;YAClC,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;YAC9B,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;SACnC;IACH,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC;IAEjD,KAAK,CAAC,mBAAmB,CAAC,IAAoB;QACnD,IAAI,CAAC,IAAI,CAAC,QAAQ;YAChB,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;QAEjC,MAAM,YAAY,GAAG,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC;QAC9D,MAAM,YAAY,GAAG,IAAA,2CAAoB,EAAC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QACzE,IAAI,YAAY,KAAK,CAAC;YACpB,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,OAAO;YACL,aAAa,EAAE,IAAI;YACnB,uBAAuB,EAAE,IAAI;YAC7B,6BAA6B,EAAE,IAAI;YACnC,YAAY;YACZ,aAAa,EAAE,CAAC,uCAAY,CAAC,KAAK,CAAC;SACpC,CAAC;IACJ,CAAC;CACF;AApCD,8DAoCC","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*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\nimport { countMatchesInString } from \"../../../common/countMatchesInString\";\nimport type { PropertyDataFilterResult} from \"./PropertyDataFiltererBase\";\nimport { FilteredType, PropertyRecordDataFiltererBase } from \"./PropertyDataFiltererBase\";\n\n/**\n * PropertyData filter which matches on any record type label and includes descendant nodes on match\n * @public\n */\nexport class LabelPropertyDataFilterer extends PropertyRecordDataFiltererBase {\n private _filterText: string = \"\";\n\n public constructor(filterText: string = \"\") {\n super();\n this._filterText = filterText;\n }\n\n public get filterText(): string { return this._filterText; }\n public set filterText(value: string) {\n const lowerValue = value.toLowerCase().trim();\n if (lowerValue !== this.filterText) {\n this._filterText = lowerValue;\n this.onFilterChanged.raiseEvent();\n }\n }\n\n public get isActive() { return this.filterText !== \"\"; }\n\n public async recordMatchesFilter(node: PropertyRecord): Promise<PropertyDataFilterResult> {\n if (!this.isActive)\n return { matchesFilter: true };\n\n const displayLabel = node.property.displayLabel.toLowerCase();\n const matchesCount = countMatchesInString(displayLabel, this.filterText);\n if (matchesCount === 0)\n return { matchesFilter: false };\n\n return {\n matchesFilter: true,\n shouldExpandNodeParents: true,\n shouldForceIncludeDescendants: true,\n matchesCount,\n filteredTypes: [FilteredType.Label],\n };\n }\n}\n"]}
1
+ {"version":3,"file":"LabelPropertyDataFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/LabelPropertyDataFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,+EAA4E;AAE5E,yEAA0F;AAE1F;;;GAGG;AACH,MAAa,yBAA0B,SAAQ,yDAA8B;IAG3E,YAAmB,aAAqB,EAAE;QACxC,KAAK,EAAE,CAAC;QAHF,gBAAW,GAAW,EAAE,CAAC;QAI/B,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;IAChC,CAAC;IAED,IAAW,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5D,IAAW,UAAU,CAAC,KAAa;QACjC,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE;YAClC,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;YAC9B,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;SACnC;IACH,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC;IAEjD,KAAK,CAAC,mBAAmB,CAAC,IAAoB;QACnD,IAAI,CAAC,IAAI,CAAC,QAAQ;YAChB,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;QAEjC,MAAM,YAAY,GAAG,IAAI,CAAC,QAAQ,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC;QAC9D,MAAM,YAAY,GAAG,IAAA,2CAAoB,EAAC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QACzE,IAAI,YAAY,KAAK,CAAC;YACpB,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,OAAO;YACL,aAAa,EAAE,IAAI;YACnB,uBAAuB,EAAE,IAAI;YAC7B,6BAA6B,EAAE,IAAI;YACnC,YAAY;YACZ,aAAa,EAAE,CAAC,uCAAY,CAAC,KAAK,CAAC;SACpC,CAAC;IACJ,CAAC;CACF;AApCD,8DAoCC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\r\nimport { countMatchesInString } from \"../../../common/countMatchesInString\";\r\nimport type { PropertyDataFilterResult} from \"./PropertyDataFiltererBase\";\r\nimport { FilteredType, PropertyRecordDataFiltererBase } from \"./PropertyDataFiltererBase\";\r\n\r\n/**\r\n * PropertyData filter which matches on any record type label and includes descendant nodes on match\r\n * @public\r\n */\r\nexport class LabelPropertyDataFilterer extends PropertyRecordDataFiltererBase {\r\n private _filterText: string = \"\";\r\n\r\n public constructor(filterText: string = \"\") {\r\n super();\r\n this._filterText = filterText;\r\n }\r\n\r\n public get filterText(): string { return this._filterText; }\r\n public set filterText(value: string) {\r\n const lowerValue = value.toLowerCase().trim();\r\n if (lowerValue !== this.filterText) {\r\n this._filterText = lowerValue;\r\n this.onFilterChanged.raiseEvent();\r\n }\r\n }\r\n\r\n public get isActive() { return this.filterText !== \"\"; }\r\n\r\n public async recordMatchesFilter(node: PropertyRecord): Promise<PropertyDataFilterResult> {\r\n if (!this.isActive)\r\n return { matchesFilter: true };\r\n\r\n const displayLabel = node.property.displayLabel.toLowerCase();\r\n const matchesCount = countMatchesInString(displayLabel, this.filterText);\r\n if (matchesCount === 0)\r\n return { matchesFilter: false };\r\n\r\n return {\r\n matchesFilter: true,\r\n shouldExpandNodeParents: true,\r\n shouldForceIncludeDescendants: true,\r\n matchesCount,\r\n filteredTypes: [FilteredType.Label],\r\n };\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyCategoryLabelFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/PropertyCategoryLabelFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,+EAA4E;AAG5E,yEAA4F;AAE5F;;;GAGG;AACH,MAAa,6BAA8B,SAAQ,2DAAgC;IAGjF,YAAmB,aAAqB,EAAE;QACxC,KAAK,EAAE,CAAC;QAHF,gBAAW,GAAW,EAAE,CAAC;QAI/B,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;IAChC,CAAC;IAED,IAAW,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5D,IAAW,UAAU,CAAC,KAAa;QACjC,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE;YAClC,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;YAC9B,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;SACnC;IACH,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC;IAEjD,KAAK,CAAC,qBAAqB,CAAC,IAAsB;QACvD,IAAI,CAAC,IAAI,CAAC,QAAQ;YAChB,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;QAEjC,MAAM,YAAY,GAAG,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC;QAC9C,MAAM,YAAY,GAAG,IAAA,2CAAoB,EAAC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QAEzE,IAAI,YAAY,KAAK,CAAC;YACpB,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,OAAO;YACL,aAAa,EAAE,IAAI;YACnB,uBAAuB,EAAE,IAAI;YAC7B,6BAA6B,EAAE,IAAI;YACnC,YAAY;YACZ,aAAa,EAAE,CAAC,uCAAY,CAAC,QAAQ,CAAC;SACvC,CAAC;IACJ,CAAC;CACF;AArCD,sEAqCC","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*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport { countMatchesInString } from \"../../../common/countMatchesInString\";\nimport type { PropertyCategory } from \"../../PropertyDataProvider\";\nimport type { PropertyDataFilterResult } from \"./PropertyDataFiltererBase\";\nimport { FilteredType, PropertyCategoryDataFiltererBase } from \"./PropertyDataFiltererBase\";\n\n/**\n * PropertyData filterer which matches on PropertyCategory's label.\n * @public\n */\nexport class PropertyCategoryLabelFilterer extends PropertyCategoryDataFiltererBase {\n private _filterText: string = \"\";\n\n public constructor(filterText: string = \"\") {\n super();\n this._filterText = filterText;\n }\n\n public get filterText(): string { return this._filterText; }\n public set filterText(value: string) {\n const lowerValue = value.toLowerCase().trim();\n if (lowerValue !== this.filterText) {\n this._filterText = lowerValue;\n this.onFilterChanged.raiseEvent();\n }\n }\n\n public get isActive() { return this.filterText !== \"\"; }\n\n public async categoryMatchesFilter(node: PropertyCategory): Promise<PropertyDataFilterResult> {\n if (!this.isActive)\n return { matchesFilter: true };\n\n const displayLabel = node.label.toLowerCase();\n const matchesCount = countMatchesInString(displayLabel, this.filterText);\n\n if (matchesCount === 0)\n return { matchesFilter: false };\n\n return {\n matchesFilter: true,\n shouldExpandNodeParents: true,\n shouldForceIncludeDescendants: true,\n matchesCount,\n filteredTypes: [FilteredType.Category],\n };\n }\n}\n"]}
1
+ {"version":3,"file":"PropertyCategoryLabelFilterer.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/PropertyCategoryLabelFilterer.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,+EAA4E;AAG5E,yEAA4F;AAE5F;;;GAGG;AACH,MAAa,6BAA8B,SAAQ,2DAAgC;IAGjF,YAAmB,aAAqB,EAAE;QACxC,KAAK,EAAE,CAAC;QAHF,gBAAW,GAAW,EAAE,CAAC;QAI/B,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;IAChC,CAAC;IAED,IAAW,UAAU,KAAa,OAAO,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC;IAC5D,IAAW,UAAU,CAAC,KAAa;QACjC,MAAM,UAAU,GAAG,KAAK,CAAC,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE;YAClC,IAAI,CAAC,WAAW,GAAG,UAAU,CAAC;YAC9B,IAAI,CAAC,eAAe,CAAC,UAAU,EAAE,CAAC;SACnC;IACH,CAAC;IAED,IAAW,QAAQ,KAAK,OAAO,IAAI,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC;IAEjD,KAAK,CAAC,qBAAqB,CAAC,IAAsB;QACvD,IAAI,CAAC,IAAI,CAAC,QAAQ;YAChB,OAAO,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;QAEjC,MAAM,YAAY,GAAG,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,CAAC;QAC9C,MAAM,YAAY,GAAG,IAAA,2CAAoB,EAAC,YAAY,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QAEzE,IAAI,YAAY,KAAK,CAAC;YACpB,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,CAAC;QAElC,OAAO;YACL,aAAa,EAAE,IAAI;YACnB,uBAAuB,EAAE,IAAI;YAC7B,6BAA6B,EAAE,IAAI;YACnC,YAAY;YACZ,aAAa,EAAE,CAAC,uCAAY,CAAC,QAAQ,CAAC;SACvC,CAAC;IACJ,CAAC;CACF;AArCD,sEAqCC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport { countMatchesInString } from \"../../../common/countMatchesInString\";\r\nimport type { PropertyCategory } from \"../../PropertyDataProvider\";\r\nimport type { PropertyDataFilterResult } from \"./PropertyDataFiltererBase\";\r\nimport { FilteredType, PropertyCategoryDataFiltererBase } from \"./PropertyDataFiltererBase\";\r\n\r\n/**\r\n * PropertyData filterer which matches on PropertyCategory's label.\r\n * @public\r\n */\r\nexport class PropertyCategoryLabelFilterer extends PropertyCategoryDataFiltererBase {\r\n private _filterText: string = \"\";\r\n\r\n public constructor(filterText: string = \"\") {\r\n super();\r\n this._filterText = filterText;\r\n }\r\n\r\n public get filterText(): string { return this._filterText; }\r\n public set filterText(value: string) {\r\n const lowerValue = value.toLowerCase().trim();\r\n if (lowerValue !== this.filterText) {\r\n this._filterText = lowerValue;\r\n this.onFilterChanged.raiseEvent();\r\n }\r\n }\r\n\r\n public get isActive() { return this.filterText !== \"\"; }\r\n\r\n public async categoryMatchesFilter(node: PropertyCategory): Promise<PropertyDataFilterResult> {\r\n if (!this.isActive)\r\n return { matchesFilter: true };\r\n\r\n const displayLabel = node.label.toLowerCase();\r\n const matchesCount = countMatchesInString(displayLabel, this.filterText);\r\n\r\n if (matchesCount === 0)\r\n return { matchesFilter: false };\r\n\r\n return {\r\n matchesFilter: true,\r\n shouldExpandNodeParents: true,\r\n shouldForceIncludeDescendants: true,\r\n matchesCount,\r\n filteredTypes: [FilteredType.Category],\r\n };\r\n }\r\n}\r\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"PropertyDataFiltererBase.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/PropertyDataFiltererBase.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,sDAA8C;AAG9C;;;GAGG;AACH,IAAY,YAIX;AAJD,WAAY,YAAY;IACtB,uDAAQ,CAAA;IACR,iDAAK,CAAA;IACL,iDAAK,CAAA;AACP,CAAC,EAJW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAIvB;AAuCD;;;GAGG;AACH,MAAa,yBAA0B,SAAQ,sBAAsC;CAAI;AAAzF,8DAAyF;AAczF;;;GAGG;AACH,MAAsB,wBAAwB;IAA9C;QACS,oBAAe,GAA8B,IAAI,yBAAyB,EAAE,CAAC;IAItF,CAAC;CAAA;AALD,4DAKC;AAED;;;;GAIG;AACH,MAAsB,gCAAiC,SAAQ,wBAAwB;IAC9E,KAAK,CAAC,mBAAmB;QAC9B,OAAO,EAAE,aAAa,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC3C,CAAC;CACF;AAJD,4EAIC;AAED;;;;GAIG;AACH,MAAsB,8BAA+B,SAAQ,wBAAwB;IAC5E,KAAK,CAAC,qBAAqB;QAChC,OAAO,EAAE,aAAa,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC3C,CAAC;CACF;AAJD,wEAIC","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*--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PropertyGrid\n */\n\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\nimport { BeEvent } from \"@itwin/core-bentley\";\nimport type { PropertyCategory } from \"../../PropertyDataProvider\";\n\n/**\n * Enumeration of possible component filtered types\n * @public\n */\nexport enum FilteredType {\n Category,\n Label,\n Value\n}\n\n/**\n * Data structure for storing [[IPropertyDataFilterer]] matching results\n * @public\n */\nexport interface PropertyDataFilterResult {\n /** Indicates whether provided item matched filter */\n matchesFilter: boolean;\n\n /**\n * Indicates whether descendants nodes should be forcefully included in filtered results.\n * Can only be true for nodes that have `matchesFilter` set to true.\n */\n shouldForceIncludeDescendants?: boolean;\n\n /**\n * Indicates whether parents of node should be expanded up to this match node.\n * Can only be true for nodes that have `matchesFilter` set to true.\n */\n shouldExpandNodeParents?: boolean;\n\n /**\n * Indicates how many times filter was matched in the provided item.\n */\n matchesCount?: number;\n\n /**\n * Indicates what item types were matched.\n */\n filteredTypes?: FilteredType[];\n}\n\n/**\n * A signature for property data change listeners\n * @public\n */\nexport declare type PropertyFilterChangesListener = () => void;\n\n/**\n * An event broadcasted when property filter changes\n * @public\n */\nexport class PropertyFilterChangeEvent extends BeEvent<PropertyFilterChangesListener> { }\n\n/**\n * An interface for a filterer that filters [[PropertyData]] based on content of [[PropertyRecord]]\n * and [[PropertyCategory]] objects.\n * @public\n */\nexport interface IPropertyDataFilterer {\n readonly isActive: boolean;\n recordMatchesFilter: (node: PropertyRecord, parents: PropertyRecord[]) => Promise<PropertyDataFilterResult>;\n categoryMatchesFilter: (node: PropertyCategory, parents: PropertyCategory[]) => Promise<PropertyDataFilterResult>;\n onFilterChanged: PropertyFilterChangeEvent;\n}\n\n/**\n * An abstract implementation of [[IPropertyDataFilterer]] to share common behavior between different implementations.\n * @public\n */\nexport abstract class PropertyDataFiltererBase implements IPropertyDataFilterer {\n public onFilterChanged: PropertyFilterChangeEvent = new PropertyFilterChangeEvent();\n public abstract get isActive(): boolean;\n public abstract recordMatchesFilter(node: PropertyRecord, parents: PropertyRecord[]): Promise<PropertyDataFilterResult>;\n public abstract categoryMatchesFilter(node: PropertyCategory, parents: PropertyCategory[]): Promise<PropertyDataFilterResult>;\n}\n\n/**\n * An abstract implementation of [[IPropertyDataFilterer]] that can be used as base for all\n * filterers that filter based on [[PropertyCategory]] content.\n * @public\n */\nexport abstract class PropertyCategoryDataFiltererBase extends PropertyDataFiltererBase {\n public async recordMatchesFilter(): Promise<PropertyDataFilterResult> {\n return { matchesFilter: !this.isActive };\n }\n}\n\n/**\n * An abstract implementation of [[IPropertyDataFilterer]] that can be used as base for all\n * filterers that filter based on [[PropertyRecord]] content.\n * @public\n */\nexport abstract class PropertyRecordDataFiltererBase extends PropertyDataFiltererBase {\n public async categoryMatchesFilter(): Promise<PropertyDataFilterResult> {\n return { matchesFilter: !this.isActive };\n }\n}\n"]}
1
+ {"version":3,"file":"PropertyDataFiltererBase.js","sourceRoot":"","sources":["../../../../../../src/components-react/propertygrid/dataproviders/filterers/PropertyDataFiltererBase.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAGH,sDAA8C;AAG9C;;;GAGG;AACH,IAAY,YAIX;AAJD,WAAY,YAAY;IACtB,uDAAQ,CAAA;IACR,iDAAK,CAAA;IACL,iDAAK,CAAA;AACP,CAAC,EAJW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAIvB;AAuCD;;;GAGG;AACH,MAAa,yBAA0B,SAAQ,sBAAsC;CAAI;AAAzF,8DAAyF;AAczF;;;GAGG;AACH,MAAsB,wBAAwB;IAA9C;QACS,oBAAe,GAA8B,IAAI,yBAAyB,EAAE,CAAC;IAItF,CAAC;CAAA;AALD,4DAKC;AAED;;;;GAIG;AACH,MAAsB,gCAAiC,SAAQ,wBAAwB;IAC9E,KAAK,CAAC,mBAAmB;QAC9B,OAAO,EAAE,aAAa,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC3C,CAAC;CACF;AAJD,4EAIC;AAED;;;;GAIG;AACH,MAAsB,8BAA+B,SAAQ,wBAAwB;IAC5E,KAAK,CAAC,qBAAqB;QAChC,OAAO,EAAE,aAAa,EAAE,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC;IAC3C,CAAC;CACF;AAJD,wEAIC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module PropertyGrid\r\n */\r\n\r\nimport type { PropertyRecord } from \"@itwin/appui-abstract\";\r\nimport { BeEvent } from \"@itwin/core-bentley\";\r\nimport type { PropertyCategory } from \"../../PropertyDataProvider\";\r\n\r\n/**\r\n * Enumeration of possible component filtered types\r\n * @public\r\n */\r\nexport enum FilteredType {\r\n Category,\r\n Label,\r\n Value\r\n}\r\n\r\n/**\r\n * Data structure for storing [[IPropertyDataFilterer]] matching results\r\n * @public\r\n */\r\nexport interface PropertyDataFilterResult {\r\n /** Indicates whether provided item matched filter */\r\n matchesFilter: boolean;\r\n\r\n /**\r\n * Indicates whether descendants nodes should be forcefully included in filtered results.\r\n * Can only be true for nodes that have `matchesFilter` set to true.\r\n */\r\n shouldForceIncludeDescendants?: boolean;\r\n\r\n /**\r\n * Indicates whether parents of node should be expanded up to this match node.\r\n * Can only be true for nodes that have `matchesFilter` set to true.\r\n */\r\n shouldExpandNodeParents?: boolean;\r\n\r\n /**\r\n * Indicates how many times filter was matched in the provided item.\r\n */\r\n matchesCount?: number;\r\n\r\n /**\r\n * Indicates what item types were matched.\r\n */\r\n filteredTypes?: FilteredType[];\r\n}\r\n\r\n/**\r\n * A signature for property data change listeners\r\n * @public\r\n */\r\nexport declare type PropertyFilterChangesListener = () => void;\r\n\r\n/**\r\n * An event broadcasted when property filter changes\r\n * @public\r\n */\r\nexport class PropertyFilterChangeEvent extends BeEvent<PropertyFilterChangesListener> { }\r\n\r\n/**\r\n * An interface for a filterer that filters [[PropertyData]] based on content of [[PropertyRecord]]\r\n * and [[PropertyCategory]] objects.\r\n * @public\r\n */\r\nexport interface IPropertyDataFilterer {\r\n readonly isActive: boolean;\r\n recordMatchesFilter: (node: PropertyRecord, parents: PropertyRecord[]) => Promise<PropertyDataFilterResult>;\r\n categoryMatchesFilter: (node: PropertyCategory, parents: PropertyCategory[]) => Promise<PropertyDataFilterResult>;\r\n onFilterChanged: PropertyFilterChangeEvent;\r\n}\r\n\r\n/**\r\n * An abstract implementation of [[IPropertyDataFilterer]] to share common behavior between different implementations.\r\n * @public\r\n */\r\nexport abstract class PropertyDataFiltererBase implements IPropertyDataFilterer {\r\n public onFilterChanged: PropertyFilterChangeEvent = new PropertyFilterChangeEvent();\r\n public abstract get isActive(): boolean;\r\n public abstract recordMatchesFilter(node: PropertyRecord, parents: PropertyRecord[]): Promise<PropertyDataFilterResult>;\r\n public abstract categoryMatchesFilter(node: PropertyCategory, parents: PropertyCategory[]): Promise<PropertyDataFilterResult>;\r\n}\r\n\r\n/**\r\n * An abstract implementation of [[IPropertyDataFilterer]] that can be used as base for all\r\n * filterers that filter based on [[PropertyCategory]] content.\r\n * @public\r\n */\r\nexport abstract class PropertyCategoryDataFiltererBase extends PropertyDataFiltererBase {\r\n public async recordMatchesFilter(): Promise<PropertyDataFilterResult> {\r\n return { matchesFilter: !this.isActive };\r\n }\r\n}\r\n\r\n/**\r\n * An abstract implementation of [[IPropertyDataFilterer]] that can be used as base for all\r\n * filterers that filter based on [[PropertyRecord]] content.\r\n * @public\r\n */\r\nexport abstract class PropertyRecordDataFiltererBase extends PropertyDataFiltererBase {\r\n public async categoryMatchesFilter(): Promise<PropertyDataFilterResult> {\r\n return { matchesFilter: !this.isActive };\r\n }\r\n}\r\n"]}