@itwin/tree-widget-react 3.0.0-dev.0 → 3.0.0-dev.2
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.
- package/CHANGELOG.md +9 -1
- package/README.md +232 -147
- package/lib/cjs/TreeWidget.d.ts +0 -1
- package/lib/cjs/TreeWidget.js +0 -6
- package/lib/cjs/TreeWidget.js.map +1 -1
- package/lib/cjs/components/SelectableTree.d.ts +3 -9
- package/lib/cjs/components/SelectableTree.js +1 -1
- package/lib/cjs/components/SelectableTree.js.map +1 -1
- package/lib/cjs/components/TreeSelector.d.ts +2 -2
- package/lib/cjs/components/TreeSelector.js.map +1 -1
- package/lib/cjs/components/TreeWidgetUiItemsProvider.d.ts +14 -25
- package/lib/cjs/components/TreeWidgetUiItemsProvider.js +43 -45
- package/lib/cjs/components/TreeWidgetUiItemsProvider.js.map +1 -1
- package/lib/cjs/components/tree-header/TreeHeader.js +10 -10
- package/lib/cjs/components/tree-header/TreeHeader.js.map +1 -1
- package/lib/cjs/components/tree-header/TreeHeader.scss +7 -41
- package/lib/cjs/components/trees/Tree.scss +23 -0
- package/lib/cjs/components/trees/categories-tree/CategoriesTree.d.ts +22 -0
- package/lib/cjs/components/trees/categories-tree/CategoriesTree.js +78 -0
- package/lib/cjs/components/trees/categories-tree/CategoriesTree.js.map +1 -0
- package/lib/{esm/components/trees/category-tree → cjs/components/trees/categories-tree}/CategoriesTreeButtons.d.ts +2 -9
- package/lib/cjs/components/trees/{category-tree → categories-tree}/CategoriesTreeButtons.js +10 -11
- package/lib/cjs/components/trees/categories-tree/CategoriesTreeButtons.js.map +1 -0
- package/lib/{esm/components/trees/category-tree → cjs/components/trees/categories-tree}/CategoriesTreeComponent.d.ts +11 -12
- package/lib/cjs/components/trees/categories-tree/CategoriesTreeComponent.js +75 -0
- package/lib/cjs/components/trees/categories-tree/CategoriesTreeComponent.js.map +1 -0
- package/lib/cjs/components/trees/{stateless/categories-tree → categories-tree}/CategoriesTreeDefinition.js +7 -2
- package/lib/cjs/components/trees/categories-tree/CategoriesTreeDefinition.js.map +1 -0
- package/lib/cjs/components/trees/{stateless/categories-tree → categories-tree}/CategoriesVisibilityHandler.d.ts +6 -6
- package/lib/cjs/components/trees/{stateless/categories-tree → categories-tree}/CategoriesVisibilityHandler.js +10 -10
- package/lib/cjs/components/trees/categories-tree/CategoriesVisibilityHandler.js.map +1 -0
- package/lib/cjs/components/trees/categories-tree/UseCategories.d.ts +8 -0
- package/lib/cjs/components/trees/categories-tree/UseCategories.js +22 -0
- package/lib/cjs/components/trees/categories-tree/UseCategories.js.map +1 -0
- package/lib/cjs/components/trees/common/CategoriesVisibilityUtils.d.ts +46 -0
- package/lib/cjs/components/trees/{CategoriesVisibilityUtils.js → common/CategoriesVisibilityUtils.js} +56 -8
- package/lib/cjs/components/trees/common/CategoriesVisibilityUtils.js.map +1 -0
- package/lib/{esm/components/trees/stateless → cjs/components/trees}/common/FocusedInstancesContext.d.ts +2 -1
- package/lib/cjs/components/trees/common/FocusedInstancesContext.js.map +1 -0
- package/lib/{esm/components/trees/stateless → cjs/components/trees}/common/FocusedInstancesContextProvider.d.ts +1 -1
- package/lib/cjs/components/trees/{stateless/common → common}/FocusedInstancesContextProvider.js +30 -6
- package/lib/cjs/components/trees/common/FocusedInstancesContextProvider.js.map +1 -0
- package/lib/cjs/components/trees/common/Rxjs.d.ts +10 -0
- package/lib/cjs/components/trees/common/Rxjs.js +46 -0
- package/lib/cjs/components/trees/common/Rxjs.js.map +1 -0
- package/lib/cjs/components/trees/common/UseFeatureReporting.d.ts +11 -0
- package/lib/cjs/components/trees/common/UseFeatureReporting.js +10 -1
- package/lib/cjs/components/trees/common/UseFeatureReporting.js.map +1 -1
- package/lib/cjs/components/trees/common/UseFiltering.d.ts +12 -0
- package/lib/cjs/components/trees/common/UseFiltering.js +29 -0
- package/lib/cjs/components/trees/common/UseFiltering.js.map +1 -0
- package/lib/{esm/components/trees/stateless → cjs/components/trees}/common/UseHierarchiesLocalization.d.ts +2 -2
- package/lib/cjs/components/trees/{stateless/common → common}/UseHierarchiesLocalization.js +12 -11
- package/lib/cjs/components/trees/common/UseHierarchiesLocalization.js.map +1 -0
- package/lib/cjs/components/trees/common/UseHierarchyFiltering.d.ts +19 -0
- package/lib/cjs/components/trees/{stateless/common → common}/UseHierarchyFiltering.js +44 -26
- package/lib/cjs/components/trees/common/UseHierarchyFiltering.js.map +1 -0
- package/lib/cjs/components/trees/common/UseHierarchyVisibility.d.ts +30 -0
- package/lib/cjs/components/trees/{stateless/common → common}/UseHierarchyVisibility.js +45 -29
- package/lib/cjs/components/trees/common/UseHierarchyVisibility.js.map +1 -0
- package/lib/cjs/components/trees/common/UseIModelChangeListener.d.ts +9 -0
- package/lib/cjs/components/trees/common/UseIModelChangeListener.js +20 -0
- package/lib/cjs/components/trees/common/UseIModelChangeListener.js.map +1 -0
- package/lib/cjs/components/trees/common/UseMultiCheckboxHandler.js +35 -0
- package/lib/cjs/components/trees/common/UseMultiCheckboxHandler.js.map +1 -0
- package/lib/cjs/components/trees/common/UseNodeHighlighting.d.ts +16 -0
- package/lib/cjs/components/trees/common/UseNodeHighlighting.js +140 -0
- package/lib/cjs/components/trees/common/UseNodeHighlighting.js.map +1 -0
- package/lib/cjs/components/trees/common/Utils.d.ts +16 -6
- package/lib/cjs/components/trees/common/Utils.js +38 -34
- package/lib/cjs/components/trees/common/Utils.js.map +1 -1
- package/lib/cjs/components/trees/common/components/BaseTree.d.ts +34 -0
- package/lib/cjs/components/trees/common/components/BaseTree.js +78 -0
- package/lib/cjs/components/trees/common/components/BaseTree.js.map +1 -0
- package/lib/cjs/components/trees/common/components/Delayed.js.map +1 -0
- package/lib/cjs/components/trees/common/components/ProgressOverlay.js.map +1 -0
- package/lib/cjs/components/trees/common/components/TreeNodeCheckbox.d.ts +20 -0
- package/lib/cjs/components/trees/{stateless/common/components/VisibilityTreeNodeCheckbox.js → common/components/TreeNodeCheckbox.js} +11 -7
- package/lib/cjs/components/trees/common/components/TreeNodeCheckbox.js.map +1 -0
- package/lib/cjs/components/trees/common/components/TreeNodeRenderer.d.ts +13 -0
- package/lib/cjs/components/trees/{stateless/common/components/VisibilityTreeNodeRenderer.js → common/components/TreeNodeRenderer.js} +6 -6
- package/lib/cjs/components/trees/common/components/TreeNodeRenderer.js.map +1 -0
- package/lib/cjs/components/trees/common/components/TreeRenderer.d.ts +17 -0
- package/lib/cjs/components/trees/common/components/TreeRenderer.js +44 -0
- package/lib/cjs/components/trees/common/components/TreeRenderer.js.map +1 -0
- package/lib/cjs/components/trees/common/components/TreeRenderer.scss +62 -0
- package/lib/cjs/components/trees/common/components/VisibilityTree.d.ts +14 -0
- package/lib/cjs/components/trees/common/components/VisibilityTree.js +41 -0
- package/lib/cjs/components/trees/common/components/VisibilityTree.js.map +1 -0
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTree.d.ts +11 -35
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTree.js +29 -83
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTree.js.map +1 -1
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTreeComponent.d.ts +14 -14
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTreeComponent.js +12 -12
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTreeComponent.js.map +1 -1
- package/lib/{esm/components/trees/stateless → cjs/components/trees}/external-sources-tree/ExternalSourcesTreeDefinition.d.ts +6 -2
- package/lib/cjs/components/trees/{stateless/external-sources-tree → external-sources-tree}/ExternalSourcesTreeDefinition.js +55 -37
- package/lib/cjs/components/trees/external-sources-tree/ExternalSourcesTreeDefinition.js.map +1 -0
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTree.d.ts +11 -35
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTree.js +41 -55
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTree.js.map +1 -1
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTreeComponent.d.ts +14 -14
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTreeComponent.js +12 -12
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTreeComponent.js.map +1 -1
- package/lib/cjs/components/trees/{stateless/imodel-content-tree → imodel-content-tree}/IModelContentTreeDefinition.d.ts +3 -0
- package/lib/cjs/components/trees/{stateless/imodel-content-tree → imodel-content-tree}/IModelContentTreeDefinition.js +248 -268
- package/lib/cjs/components/trees/imodel-content-tree/IModelContentTreeDefinition.js.map +1 -0
- package/lib/cjs/components/trees/imodel-content-tree/internal/IModelContentTreeIdsCache.d.ts +26 -0
- package/lib/cjs/components/trees/imodel-content-tree/internal/IModelContentTreeIdsCache.js +203 -0
- package/lib/cjs/components/trees/imodel-content-tree/internal/IModelContentTreeIdsCache.js.map +1 -0
- package/lib/cjs/components/trees/index.d.ts +4 -19
- package/lib/cjs/components/trees/index.js +9 -31
- package/lib/cjs/components/trees/index.js.map +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTree.d.ts +17 -72
- package/lib/cjs/components/trees/models-tree/ModelsTree.js +196 -135
- package/lib/cjs/components/trees/models-tree/ModelsTree.js.map +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTreeButtons.d.ts +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTreeButtons.js +40 -25
- package/lib/cjs/components/trees/models-tree/ModelsTreeButtons.js.map +1 -1
- package/lib/cjs/components/trees/models-tree/ModelsTreeComponent.d.ts +13 -12
- package/lib/cjs/components/trees/models-tree/ModelsTreeComponent.js +35 -26
- package/lib/cjs/components/trees/models-tree/ModelsTreeComponent.js.map +1 -1
- package/lib/{esm/components/trees/stateless → cjs/components/trees}/models-tree/ModelsTreeDefinition.d.ts +36 -4
- package/lib/cjs/components/trees/models-tree/ModelsTreeDefinition.js +617 -0
- package/lib/cjs/components/trees/models-tree/ModelsTreeDefinition.js.map +1 -0
- package/lib/cjs/components/trees/models-tree/internal/AlwaysAndNeverDrawnElementInfo.d.ts +24 -0
- package/lib/cjs/components/trees/models-tree/internal/AlwaysAndNeverDrawnElementInfo.js +121 -0
- package/lib/cjs/components/trees/models-tree/internal/AlwaysAndNeverDrawnElementInfo.js.map +1 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeIdsCache.d.ts +44 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeIdsCache.js +325 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeIdsCache.js.map +1 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeNode.d.ts +31 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeNode.js +40 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeNode.js.map +1 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeVisibilityHandler.d.ts +122 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeVisibilityHandler.js +757 -0
- package/lib/cjs/components/trees/models-tree/internal/ModelsTreeVisibilityHandler.js.map +1 -0
- package/lib/cjs/components/trees/models-tree/internal/Tooltip.d.ts +13 -0
- package/lib/cjs/components/trees/models-tree/internal/Tooltip.js +29 -0
- package/lib/cjs/components/trees/models-tree/internal/Tooltip.js.map +1 -0
- package/lib/cjs/components/trees/models-tree/internal/VisibilityChangeEventListener.d.ts +10 -0
- package/lib/cjs/components/trees/models-tree/internal/VisibilityChangeEventListener.js +43 -0
- package/lib/cjs/components/trees/models-tree/internal/VisibilityChangeEventListener.js.map +1 -0
- package/lib/cjs/tree-widget-react.d.ts +3 -4
- package/lib/cjs/tree-widget-react.js +8 -4
- package/lib/cjs/tree-widget-react.js.map +1 -1
- package/lib/esm/TreeWidget.d.ts +0 -1
- package/lib/esm/TreeWidget.js +0 -6
- package/lib/esm/TreeWidget.js.map +1 -1
- package/lib/esm/components/SelectableTree.d.ts +3 -9
- package/lib/esm/components/SelectableTree.js +1 -1
- package/lib/esm/components/SelectableTree.js.map +1 -1
- package/lib/esm/components/TreeSelector.d.ts +2 -2
- package/lib/esm/components/TreeSelector.js.map +1 -1
- package/lib/esm/components/TreeWidgetUiItemsProvider.d.ts +14 -25
- package/lib/esm/components/TreeWidgetUiItemsProvider.js +42 -44
- package/lib/esm/components/TreeWidgetUiItemsProvider.js.map +1 -1
- package/lib/esm/components/tree-header/TreeHeader.js +10 -10
- package/lib/esm/components/tree-header/TreeHeader.js.map +1 -1
- package/lib/esm/components/tree-header/TreeHeader.scss +7 -41
- package/lib/esm/components/trees/Tree.scss +23 -0
- package/lib/esm/components/trees/categories-tree/CategoriesTree.d.ts +22 -0
- package/lib/esm/components/trees/categories-tree/CategoriesTree.js +74 -0
- package/lib/esm/components/trees/categories-tree/CategoriesTree.js.map +1 -0
- package/lib/{cjs/components/trees/category-tree → esm/components/trees/categories-tree}/CategoriesTreeButtons.d.ts +2 -9
- package/lib/esm/components/trees/{category-tree → categories-tree}/CategoriesTreeButtons.js +7 -8
- package/lib/esm/components/trees/categories-tree/CategoriesTreeButtons.js.map +1 -0
- package/lib/{cjs/components/trees/category-tree → esm/components/trees/categories-tree}/CategoriesTreeComponent.d.ts +11 -12
- package/lib/esm/components/trees/categories-tree/CategoriesTreeComponent.js +68 -0
- package/lib/esm/components/trees/categories-tree/CategoriesTreeComponent.js.map +1 -0
- package/lib/esm/components/trees/{stateless/categories-tree → categories-tree}/CategoriesTreeDefinition.js +7 -2
- package/lib/esm/components/trees/categories-tree/CategoriesTreeDefinition.js.map +1 -0
- package/lib/esm/components/trees/{stateless/categories-tree → categories-tree}/CategoriesVisibilityHandler.d.ts +6 -6
- package/lib/esm/components/trees/{stateless/categories-tree → categories-tree}/CategoriesVisibilityHandler.js +8 -8
- package/lib/esm/components/trees/categories-tree/CategoriesVisibilityHandler.js.map +1 -0
- package/lib/esm/components/trees/categories-tree/UseCategories.d.ts +8 -0
- package/lib/esm/components/trees/categories-tree/UseCategories.js +18 -0
- package/lib/esm/components/trees/categories-tree/UseCategories.js.map +1 -0
- package/lib/esm/components/trees/common/CategoriesVisibilityUtils.d.ts +46 -0
- package/lib/esm/components/trees/{CategoriesVisibilityUtils.js → common/CategoriesVisibilityUtils.js} +51 -6
- package/lib/esm/components/trees/common/CategoriesVisibilityUtils.js.map +1 -0
- package/lib/{cjs/components/trees/stateless → esm/components/trees}/common/FocusedInstancesContext.d.ts +2 -1
- package/lib/esm/components/trees/common/FocusedInstancesContext.js.map +1 -0
- package/lib/{cjs/components/trees/stateless → esm/components/trees}/common/FocusedInstancesContextProvider.d.ts +1 -1
- package/lib/esm/components/trees/{stateless/common → common}/FocusedInstancesContextProvider.js +30 -6
- package/lib/esm/components/trees/common/FocusedInstancesContextProvider.js.map +1 -0
- package/lib/esm/components/trees/common/Rxjs.d.ts +10 -0
- package/lib/esm/components/trees/common/Rxjs.js +40 -0
- package/lib/esm/components/trees/common/Rxjs.js.map +1 -0
- package/lib/esm/components/trees/common/UseFeatureReporting.d.ts +11 -0
- package/lib/esm/components/trees/common/UseFeatureReporting.js +8 -0
- package/lib/esm/components/trees/common/UseFeatureReporting.js.map +1 -1
- package/lib/esm/components/trees/common/UseFiltering.d.ts +12 -0
- package/lib/esm/components/trees/common/UseFiltering.js +25 -0
- package/lib/esm/components/trees/common/UseFiltering.js.map +1 -0
- package/lib/{cjs/components/trees/stateless → esm/components/trees}/common/UseHierarchiesLocalization.d.ts +2 -2
- package/lib/esm/components/trees/common/UseHierarchiesLocalization.js +30 -0
- package/lib/esm/components/trees/common/UseHierarchiesLocalization.js.map +1 -0
- package/lib/esm/components/trees/common/UseHierarchyFiltering.d.ts +19 -0
- package/lib/esm/components/trees/{stateless/common → common}/UseHierarchyFiltering.js +45 -27
- package/lib/esm/components/trees/common/UseHierarchyFiltering.js.map +1 -0
- package/lib/esm/components/trees/common/UseHierarchyVisibility.d.ts +30 -0
- package/lib/esm/components/trees/{stateless/common → common}/UseHierarchyVisibility.js +45 -29
- package/lib/esm/components/trees/common/UseHierarchyVisibility.js.map +1 -0
- package/lib/esm/components/trees/common/UseIModelChangeListener.d.ts +9 -0
- package/lib/esm/components/trees/common/UseIModelChangeListener.js +16 -0
- package/lib/esm/components/trees/common/UseIModelChangeListener.js.map +1 -0
- package/lib/esm/components/trees/common/UseMultiCheckboxHandler.js +31 -0
- package/lib/esm/components/trees/common/UseMultiCheckboxHandler.js.map +1 -0
- package/lib/esm/components/trees/common/UseNodeHighlighting.d.ts +16 -0
- package/lib/esm/components/trees/common/UseNodeHighlighting.js +136 -0
- package/lib/esm/components/trees/common/UseNodeHighlighting.js.map +1 -0
- package/lib/esm/components/trees/common/Utils.d.ts +16 -6
- package/lib/esm/components/trees/common/Utils.js +33 -29
- package/lib/esm/components/trees/common/Utils.js.map +1 -1
- package/lib/esm/components/trees/common/components/BaseTree.d.ts +34 -0
- package/lib/esm/components/trees/common/components/BaseTree.js +74 -0
- package/lib/esm/components/trees/common/components/BaseTree.js.map +1 -0
- package/lib/esm/components/trees/common/components/Delayed.js.map +1 -0
- package/lib/esm/components/trees/common/components/ProgressOverlay.js.map +1 -0
- package/lib/esm/components/trees/common/components/TreeNodeCheckbox.d.ts +20 -0
- package/lib/esm/components/trees/{stateless/common/components/VisibilityTreeNodeCheckbox.js → common/components/TreeNodeCheckbox.js} +6 -5
- package/lib/esm/components/trees/common/components/TreeNodeCheckbox.js.map +1 -0
- package/lib/esm/components/trees/common/components/TreeNodeRenderer.d.ts +13 -0
- package/lib/esm/components/trees/common/components/TreeNodeRenderer.js +13 -0
- package/lib/esm/components/trees/common/components/TreeNodeRenderer.js.map +1 -0
- package/lib/esm/components/trees/common/components/TreeRenderer.d.ts +17 -0
- package/lib/esm/components/trees/common/components/TreeRenderer.js +40 -0
- package/lib/esm/components/trees/common/components/TreeRenderer.js.map +1 -0
- package/lib/esm/components/trees/common/components/TreeRenderer.scss +62 -0
- package/lib/esm/components/trees/common/components/VisibilityTree.d.ts +14 -0
- package/lib/esm/components/trees/common/components/VisibilityTree.js +37 -0
- package/lib/esm/components/trees/common/components/VisibilityTree.js.map +1 -0
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTree.d.ts +11 -35
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTree.js +27 -58
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTree.js.map +1 -1
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTreeComponent.d.ts +14 -14
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTreeComponent.js +12 -12
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTreeComponent.js.map +1 -1
- package/lib/{cjs/components/trees/stateless → esm/components/trees}/external-sources-tree/ExternalSourcesTreeDefinition.d.ts +6 -2
- package/lib/esm/components/trees/{stateless/external-sources-tree → external-sources-tree}/ExternalSourcesTreeDefinition.js +55 -37
- package/lib/esm/components/trees/external-sources-tree/ExternalSourcesTreeDefinition.js.map +1 -0
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTree.d.ts +11 -35
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTree.js +39 -53
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTree.js.map +1 -1
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTreeComponent.d.ts +14 -14
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTreeComponent.js +12 -12
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTreeComponent.js.map +1 -1
- package/lib/esm/components/trees/{stateless/imodel-content-tree → imodel-content-tree}/IModelContentTreeDefinition.d.ts +3 -0
- package/lib/esm/components/trees/{stateless/imodel-content-tree → imodel-content-tree}/IModelContentTreeDefinition.js +249 -269
- package/lib/esm/components/trees/imodel-content-tree/IModelContentTreeDefinition.js.map +1 -0
- package/lib/esm/components/trees/imodel-content-tree/internal/IModelContentTreeIdsCache.d.ts +26 -0
- package/lib/esm/components/trees/imodel-content-tree/internal/IModelContentTreeIdsCache.js +199 -0
- package/lib/esm/components/trees/imodel-content-tree/internal/IModelContentTreeIdsCache.js.map +1 -0
- package/lib/esm/components/trees/index.d.ts +4 -19
- package/lib/esm/components/trees/index.js +4 -17
- package/lib/esm/components/trees/index.js.map +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTree.d.ts +17 -72
- package/lib/esm/components/trees/models-tree/ModelsTree.js +196 -132
- package/lib/esm/components/trees/models-tree/ModelsTree.js.map +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTreeButtons.d.ts +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTreeButtons.js +30 -15
- package/lib/esm/components/trees/models-tree/ModelsTreeButtons.js.map +1 -1
- package/lib/esm/components/trees/models-tree/ModelsTreeComponent.d.ts +13 -12
- package/lib/esm/components/trees/models-tree/ModelsTreeComponent.js +36 -27
- package/lib/esm/components/trees/models-tree/ModelsTreeComponent.js.map +1 -1
- package/lib/{cjs/components/trees/stateless → esm/components/trees}/models-tree/ModelsTreeDefinition.d.ts +36 -4
- package/lib/esm/components/trees/models-tree/ModelsTreeDefinition.js +613 -0
- package/lib/esm/components/trees/models-tree/ModelsTreeDefinition.js.map +1 -0
- package/lib/esm/components/trees/models-tree/internal/AlwaysAndNeverDrawnElementInfo.d.ts +24 -0
- package/lib/esm/components/trees/models-tree/internal/AlwaysAndNeverDrawnElementInfo.js +117 -0
- package/lib/esm/components/trees/models-tree/internal/AlwaysAndNeverDrawnElementInfo.js.map +1 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeIdsCache.d.ts +44 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeIdsCache.js +321 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeIdsCache.js.map +1 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeNode.d.ts +31 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeNode.js +37 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeNode.js.map +1 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeVisibilityHandler.d.ts +122 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeVisibilityHandler.js +748 -0
- package/lib/esm/components/trees/models-tree/internal/ModelsTreeVisibilityHandler.js.map +1 -0
- package/lib/esm/components/trees/models-tree/internal/Tooltip.d.ts +13 -0
- package/lib/esm/components/trees/models-tree/internal/Tooltip.js +24 -0
- package/lib/esm/components/trees/models-tree/internal/Tooltip.js.map +1 -0
- package/lib/esm/components/trees/models-tree/internal/VisibilityChangeEventListener.d.ts +10 -0
- package/lib/esm/components/trees/models-tree/internal/VisibilityChangeEventListener.js +39 -0
- package/lib/esm/components/trees/models-tree/internal/VisibilityChangeEventListener.js.map +1 -0
- package/lib/esm/tree-widget-react.d.ts +3 -4
- package/lib/esm/tree-widget-react.js +3 -4
- package/lib/esm/tree-widget-react.js.map +1 -1
- package/lib/public/locales/en/TreeWidget.json +126 -62
- package/package.json +18 -11
- package/lib/cjs/components/TreeFilteringState.d.ts +0 -18
- package/lib/cjs/components/TreeFilteringState.js +0 -46
- package/lib/cjs/components/TreeFilteringState.js.map +0 -1
- package/lib/cjs/components/trees/CategoriesVisibilityUtils.d.ts +0 -25
- package/lib/cjs/components/trees/CategoriesVisibilityUtils.js.map +0 -1
- package/lib/cjs/components/trees/VisibilityTreeBase.scss +0 -82
- package/lib/cjs/components/trees/VisibilityTreeEventHandler.d.ts +0 -67
- package/lib/cjs/components/trees/VisibilityTreeEventHandler.js +0 -158
- package/lib/cjs/components/trees/VisibilityTreeEventHandler.js.map +0 -1
- package/lib/cjs/components/trees/VisibilityTreeRenderer.d.ts +0 -100
- package/lib/cjs/components/trees/VisibilityTreeRenderer.js +0 -98
- package/lib/cjs/components/trees/VisibilityTreeRenderer.js.map +0 -1
- package/lib/cjs/components/trees/category-tree/Categories.json +0 -99
- package/lib/cjs/components/trees/category-tree/CategoriesTree.d.ts +0 -60
- package/lib/cjs/components/trees/category-tree/CategoriesTree.js +0 -117
- package/lib/cjs/components/trees/category-tree/CategoriesTree.js.map +0 -1
- package/lib/cjs/components/trees/category-tree/CategoriesTreeButtons.js.map +0 -1
- package/lib/cjs/components/trees/category-tree/CategoriesTreeComponent.js +0 -104
- package/lib/cjs/components/trees/category-tree/CategoriesTreeComponent.js.map +0 -1
- package/lib/cjs/components/trees/category-tree/CategoryVisibilityHandler.d.ts +0 -65
- package/lib/cjs/components/trees/category-tree/CategoryVisibilityHandler.js +0 -172
- package/lib/cjs/components/trees/category-tree/CategoryVisibilityHandler.js.map +0 -1
- package/lib/cjs/components/trees/common/ContextMenu.d.ts +0 -39
- package/lib/cjs/components/trees/common/ContextMenu.js +0 -44
- package/lib/cjs/components/trees/common/ContextMenu.js.map +0 -1
- package/lib/cjs/components/trees/common/ReportingTreeEventHandler.d.ts +0 -27
- package/lib/cjs/components/trees/common/ReportingTreeEventHandler.js +0 -51
- package/lib/cjs/components/trees/common/ReportingTreeEventHandler.js.map +0 -1
- package/lib/cjs/components/trees/common/TreeNodeRenderer.d.ts +0 -61
- package/lib/cjs/components/trees/common/TreeNodeRenderer.js +0 -50
- package/lib/cjs/components/trees/common/TreeNodeRenderer.js.map +0 -1
- package/lib/cjs/components/trees/common/TreeRenderer.d.ts +0 -55
- package/lib/cjs/components/trees/common/TreeRenderer.js +0 -67
- package/lib/cjs/components/trees/common/TreeRenderer.js.map +0 -1
- package/lib/cjs/components/trees/common/TreeRenderer.scss +0 -149
- package/lib/cjs/components/trees/common/Types.d.ts +0 -57
- package/lib/cjs/components/trees/common/Types.js +0 -21
- package/lib/cjs/components/trees/common/Types.js.map +0 -1
- package/lib/cjs/components/trees/common/UseVisibilityTreeState.d.ts +0 -43
- package/lib/cjs/components/trees/common/UseVisibilityTreeState.js +0 -49
- package/lib/cjs/components/trees/common/UseVisibilityTreeState.js.map +0 -1
- package/lib/cjs/components/trees/external-sources-tree/ExternalSources.json +0 -228
- package/lib/cjs/components/trees/imodel-content-tree/IModelContent.json +0 -443
- package/lib/cjs/components/trees/models-tree/ModelsTreeEventHandler.d.ts +0 -19
- package/lib/cjs/components/trees/models-tree/ModelsTreeEventHandler.js +0 -36
- package/lib/cjs/components/trees/models-tree/ModelsTreeEventHandler.js.map +0 -1
- package/lib/cjs/components/trees/models-tree/ModelsVisibilityHandler.d.ts +0 -130
- package/lib/cjs/components/trees/models-tree/ModelsVisibilityHandler.js +0 -651
- package/lib/cjs/components/trees/models-tree/ModelsVisibilityHandler.js.map +0 -1
- package/lib/cjs/components/trees/models-tree/Utils.d.ts +0 -29
- package/lib/cjs/components/trees/models-tree/Utils.js +0 -556
- package/lib/cjs/components/trees/models-tree/Utils.js.map +0 -1
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTree.d.ts +0 -20
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTree.js +0 -61
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTree.js.map +0 -1
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTreeComponent.d.ts +0 -16
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTreeComponent.js +0 -43
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTreeComponent.js.map +0 -1
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesTreeDefinition.js.map +0 -1
- package/lib/cjs/components/trees/stateless/categories-tree/CategoriesVisibilityHandler.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/FocusedInstancesContext.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/FocusedInstancesContextProvider.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/UseHierarchiesLocalization.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/UseHierarchyFiltering.d.ts +0 -16
- package/lib/cjs/components/trees/stateless/common/UseHierarchyFiltering.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/UseHierarchyVisibility.d.ts +0 -21
- package/lib/cjs/components/trees/stateless/common/UseHierarchyVisibility.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/UseMultiCheckboxHandler.js +0 -34
- package/lib/cjs/components/trees/stateless/common/UseMultiCheckboxHandler.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/Utils.d.ts +0 -3
- package/lib/cjs/components/trees/stateless/common/Utils.js +0 -23
- package/lib/cjs/components/trees/stateless/common/Utils.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/Delayed.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/FilterableTree.d.ts +0 -23
- package/lib/cjs/components/trees/stateless/common/components/FilterableTree.js +0 -66
- package/lib/cjs/components/trees/stateless/common/components/FilterableTree.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/ProgressOverlay.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTree.d.ts +0 -26
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTree.js +0 -68
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTree.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeNodeCheckbox.d.ts +0 -12
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeNodeCheckbox.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeNodeRenderer.d.ts +0 -10
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeNodeRenderer.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeRenderer.d.ts +0 -16
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeRenderer.js +0 -23
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeRenderer.js.map +0 -1
- package/lib/cjs/components/trees/stateless/common/components/VisibilityTreeRenderer.scss +0 -41
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTree.d.ts +0 -13
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTree.js +0 -40
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTree.js.map +0 -1
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTreeComponent.d.ts +0 -14
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTreeComponent.js +0 -25
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTreeComponent.js.map +0 -1
- package/lib/cjs/components/trees/stateless/external-sources-tree/ExternalSourcesTreeDefinition.js.map +0 -1
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTree.d.ts +0 -13
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTree.js +0 -48
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTree.js.map +0 -1
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTreeComponent.d.ts +0 -14
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTreeComponent.js +0 -25
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTreeComponent.js.map +0 -1
- package/lib/cjs/components/trees/stateless/imodel-content-tree/IModelContentTreeDefinition.js.map +0 -1
- package/lib/cjs/components/trees/stateless/index.d.ts +0 -5
- package/lib/cjs/components/trees/stateless/index.js +0 -16
- package/lib/cjs/components/trees/stateless/index.js.map +0 -1
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTree.d.ts +0 -16
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTree.js +0 -77
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTree.js.map +0 -1
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTreeComponent.d.ts +0 -17
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTreeComponent.js +0 -55
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTreeComponent.js.map +0 -1
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTreeDefinition.js +0 -856
- package/lib/cjs/components/trees/stateless/models-tree/ModelsTreeDefinition.js.map +0 -1
- package/lib/cjs/components/trees/stateless/models-tree/ModelsVisibilityHandler.d.ts +0 -48
- package/lib/cjs/components/trees/stateless/models-tree/ModelsVisibilityHandler.js +0 -470
- package/lib/cjs/components/trees/stateless/models-tree/ModelsVisibilityHandler.js.map +0 -1
- package/lib/cjs/components/utils/UseTreeTransientState.d.ts +0 -19
- package/lib/cjs/components/utils/UseTreeTransientState.js +0 -33
- package/lib/cjs/components/utils/UseTreeTransientState.js.map +0 -1
- package/lib/esm/components/TreeFilteringState.d.ts +0 -18
- package/lib/esm/components/TreeFilteringState.js +0 -42
- package/lib/esm/components/TreeFilteringState.js.map +0 -1
- package/lib/esm/components/trees/CategoriesVisibilityUtils.d.ts +0 -25
- package/lib/esm/components/trees/CategoriesVisibilityUtils.js.map +0 -1
- package/lib/esm/components/trees/VisibilityTreeBase.scss +0 -82
- package/lib/esm/components/trees/VisibilityTreeEventHandler.d.ts +0 -67
- package/lib/esm/components/trees/VisibilityTreeEventHandler.js +0 -154
- package/lib/esm/components/trees/VisibilityTreeEventHandler.js.map +0 -1
- package/lib/esm/components/trees/VisibilityTreeRenderer.d.ts +0 -100
- package/lib/esm/components/trees/VisibilityTreeRenderer.js +0 -86
- package/lib/esm/components/trees/VisibilityTreeRenderer.js.map +0 -1
- package/lib/esm/components/trees/category-tree/Categories.json +0 -99
- package/lib/esm/components/trees/category-tree/CategoriesTree.d.ts +0 -60
- package/lib/esm/components/trees/category-tree/CategoriesTree.js +0 -110
- package/lib/esm/components/trees/category-tree/CategoriesTree.js.map +0 -1
- package/lib/esm/components/trees/category-tree/CategoriesTreeButtons.js.map +0 -1
- package/lib/esm/components/trees/category-tree/CategoriesTreeComponent.js +0 -97
- package/lib/esm/components/trees/category-tree/CategoriesTreeComponent.js.map +0 -1
- package/lib/esm/components/trees/category-tree/CategoryVisibilityHandler.d.ts +0 -65
- package/lib/esm/components/trees/category-tree/CategoryVisibilityHandler.js +0 -164
- package/lib/esm/components/trees/category-tree/CategoryVisibilityHandler.js.map +0 -1
- package/lib/esm/components/trees/common/ContextMenu.d.ts +0 -39
- package/lib/esm/components/trees/common/ContextMenu.js +0 -39
- package/lib/esm/components/trees/common/ContextMenu.js.map +0 -1
- package/lib/esm/components/trees/common/ReportingTreeEventHandler.d.ts +0 -27
- package/lib/esm/components/trees/common/ReportingTreeEventHandler.js +0 -47
- package/lib/esm/components/trees/common/ReportingTreeEventHandler.js.map +0 -1
- package/lib/esm/components/trees/common/TreeNodeRenderer.d.ts +0 -61
- package/lib/esm/components/trees/common/TreeNodeRenderer.js +0 -44
- package/lib/esm/components/trees/common/TreeNodeRenderer.js.map +0 -1
- package/lib/esm/components/trees/common/TreeRenderer.d.ts +0 -55
- package/lib/esm/components/trees/common/TreeRenderer.js +0 -59
- package/lib/esm/components/trees/common/TreeRenderer.js.map +0 -1
- package/lib/esm/components/trees/common/TreeRenderer.scss +0 -149
- package/lib/esm/components/trees/common/Types.d.ts +0 -57
- package/lib/esm/components/trees/common/Types.js +0 -18
- package/lib/esm/components/trees/common/Types.js.map +0 -1
- package/lib/esm/components/trees/common/UseVisibilityTreeState.d.ts +0 -43
- package/lib/esm/components/trees/common/UseVisibilityTreeState.js +0 -45
- package/lib/esm/components/trees/common/UseVisibilityTreeState.js.map +0 -1
- package/lib/esm/components/trees/external-sources-tree/ExternalSources.json +0 -228
- package/lib/esm/components/trees/imodel-content-tree/IModelContent.json +0 -443
- package/lib/esm/components/trees/models-tree/ModelsTreeEventHandler.d.ts +0 -19
- package/lib/esm/components/trees/models-tree/ModelsTreeEventHandler.js +0 -32
- package/lib/esm/components/trees/models-tree/ModelsTreeEventHandler.js.map +0 -1
- package/lib/esm/components/trees/models-tree/ModelsVisibilityHandler.d.ts +0 -130
- package/lib/esm/components/trees/models-tree/ModelsVisibilityHandler.js +0 -641
- package/lib/esm/components/trees/models-tree/ModelsVisibilityHandler.js.map +0 -1
- package/lib/esm/components/trees/models-tree/Utils.d.ts +0 -29
- package/lib/esm/components/trees/models-tree/Utils.js +0 -548
- package/lib/esm/components/trees/models-tree/Utils.js.map +0 -1
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTree.d.ts +0 -20
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTree.js +0 -57
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTree.js.map +0 -1
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTreeComponent.d.ts +0 -16
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTreeComponent.js +0 -39
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTreeComponent.js.map +0 -1
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesTreeDefinition.js.map +0 -1
- package/lib/esm/components/trees/stateless/categories-tree/CategoriesVisibilityHandler.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/FocusedInstancesContext.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/FocusedInstancesContextProvider.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/UseHierarchiesLocalization.js +0 -29
- package/lib/esm/components/trees/stateless/common/UseHierarchiesLocalization.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/UseHierarchyFiltering.d.ts +0 -16
- package/lib/esm/components/trees/stateless/common/UseHierarchyFiltering.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/UseHierarchyVisibility.d.ts +0 -21
- package/lib/esm/components/trees/stateless/common/UseHierarchyVisibility.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/UseMultiCheckboxHandler.js +0 -30
- package/lib/esm/components/trees/stateless/common/UseMultiCheckboxHandler.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/Utils.d.ts +0 -3
- package/lib/esm/components/trees/stateless/common/Utils.js +0 -19
- package/lib/esm/components/trees/stateless/common/Utils.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/Delayed.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/FilterableTree.d.ts +0 -23
- package/lib/esm/components/trees/stateless/common/components/FilterableTree.js +0 -62
- package/lib/esm/components/trees/stateless/common/components/FilterableTree.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/ProgressOverlay.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/VisibilityTree.d.ts +0 -26
- package/lib/esm/components/trees/stateless/common/components/VisibilityTree.js +0 -64
- package/lib/esm/components/trees/stateless/common/components/VisibilityTree.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeNodeCheckbox.d.ts +0 -12
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeNodeCheckbox.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeNodeRenderer.d.ts +0 -10
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeNodeRenderer.js +0 -13
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeNodeRenderer.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeRenderer.d.ts +0 -16
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeRenderer.js +0 -19
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeRenderer.js.map +0 -1
- package/lib/esm/components/trees/stateless/common/components/VisibilityTreeRenderer.scss +0 -41
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTree.d.ts +0 -13
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTree.js +0 -36
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTree.js.map +0 -1
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTreeComponent.d.ts +0 -14
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTreeComponent.js +0 -21
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTreeComponent.js.map +0 -1
- package/lib/esm/components/trees/stateless/external-sources-tree/ExternalSourcesTreeDefinition.js.map +0 -1
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTree.d.ts +0 -13
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTree.js +0 -44
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTree.js.map +0 -1
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTreeComponent.d.ts +0 -14
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTreeComponent.js +0 -21
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTreeComponent.js.map +0 -1
- package/lib/esm/components/trees/stateless/imodel-content-tree/IModelContentTreeDefinition.js.map +0 -1
- package/lib/esm/components/trees/stateless/index.d.ts +0 -5
- package/lib/esm/components/trees/stateless/index.js +0 -9
- package/lib/esm/components/trees/stateless/index.js.map +0 -1
- package/lib/esm/components/trees/stateless/models-tree/ModelsTree.d.ts +0 -16
- package/lib/esm/components/trees/stateless/models-tree/ModelsTree.js +0 -73
- package/lib/esm/components/trees/stateless/models-tree/ModelsTree.js.map +0 -1
- package/lib/esm/components/trees/stateless/models-tree/ModelsTreeComponent.d.ts +0 -17
- package/lib/esm/components/trees/stateless/models-tree/ModelsTreeComponent.js +0 -51
- package/lib/esm/components/trees/stateless/models-tree/ModelsTreeComponent.js.map +0 -1
- package/lib/esm/components/trees/stateless/models-tree/ModelsTreeDefinition.js +0 -852
- package/lib/esm/components/trees/stateless/models-tree/ModelsTreeDefinition.js.map +0 -1
- package/lib/esm/components/trees/stateless/models-tree/ModelsVisibilityHandler.d.ts +0 -48
- package/lib/esm/components/trees/stateless/models-tree/ModelsVisibilityHandler.js +0 -466
- package/lib/esm/components/trees/stateless/models-tree/ModelsVisibilityHandler.js.map +0 -1
- package/lib/esm/components/utils/UseTreeTransientState.d.ts +0 -19
- package/lib/esm/components/utils/UseTreeTransientState.js +0 -29
- package/lib/esm/components/utils/UseTreeTransientState.js.map +0 -1
- /package/lib/cjs/components/trees/{stateless/categories-tree → categories-tree}/CategoriesTreeDefinition.d.ts +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/FocusedInstancesContext.js +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/UseMultiCheckboxHandler.d.ts +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/components/Delayed.d.ts +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/components/Delayed.js +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/components/ProgressOverlay.d.ts +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/components/ProgressOverlay.js +0 -0
- /package/lib/cjs/components/trees/{stateless/common → common}/components/ProgressOverlay.scss +0 -0
- /package/lib/esm/components/trees/{stateless/categories-tree → categories-tree}/CategoriesTreeDefinition.d.ts +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/FocusedInstancesContext.js +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/UseMultiCheckboxHandler.d.ts +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/components/Delayed.d.ts +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/components/Delayed.js +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/components/ProgressOverlay.d.ts +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/components/ProgressOverlay.js +0 -0
- /package/lib/esm/components/trees/{stateless/common → common}/components/ProgressOverlay.scss +0 -0
|
@@ -0,0 +1,321 @@
|
|
|
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 { assert } from "@itwin/core-bentley";
|
|
6
|
+
import { pushToMap } from "../../common/Utils";
|
|
7
|
+
/** @internal */
|
|
8
|
+
export class ModelsTreeIdsCache {
|
|
9
|
+
constructor(_queryExecutor, _hierarchyConfig) {
|
|
10
|
+
this._queryExecutor = _queryExecutor;
|
|
11
|
+
this._hierarchyConfig = _hierarchyConfig;
|
|
12
|
+
this._categoryElementCounts = new Map();
|
|
13
|
+
}
|
|
14
|
+
async *querySubjects() {
|
|
15
|
+
const subjectsQuery = `
|
|
16
|
+
SELECT
|
|
17
|
+
s.ECInstanceId id,
|
|
18
|
+
s.Parent.Id parentId,
|
|
19
|
+
(
|
|
20
|
+
SELECT m.ECInstanceId
|
|
21
|
+
FROM bis.GeometricModel3d m
|
|
22
|
+
WHERE m.ECInstanceId = HexToId(json_extract(s.JsonProperties, '$.Subject.Model.TargetPartition'))
|
|
23
|
+
AND NOT m.IsPrivate
|
|
24
|
+
AND EXISTS (SELECT 1 FROM ${this._hierarchyConfig.elementClassSpecification} WHERE Model.Id = m.ECInstanceId)
|
|
25
|
+
) targetPartitionId,
|
|
26
|
+
CASE
|
|
27
|
+
WHEN (
|
|
28
|
+
json_extract(s.JsonProperties, '$.Subject.Job.Bridge') IS NOT NULL
|
|
29
|
+
OR json_extract(s.JsonProperties, '$.Subject.Model.Type') = 'Hierarchy'
|
|
30
|
+
) THEN 1
|
|
31
|
+
ELSE 0
|
|
32
|
+
END hideInHierarchy
|
|
33
|
+
FROM bis.Subject s
|
|
34
|
+
`;
|
|
35
|
+
for await (const row of this._queryExecutor.createQueryReader({ ecsql: subjectsQuery }, { rowFormat: "ECSqlPropertyNames", limit: "unbounded" })) {
|
|
36
|
+
yield { id: row.id, parentId: row.parentId, targetPartitionId: row.targetPartitionId, hideInHierarchy: !!row.hideInHierarchy };
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
async *queryModels() {
|
|
40
|
+
const modelsQuery = `
|
|
41
|
+
SELECT p.ECInstanceId id, p.Parent.Id parentId
|
|
42
|
+
FROM bis.InformationPartitionElement p
|
|
43
|
+
INNER JOIN bis.GeometricModel3d m ON m.ModeledElement.Id = p.ECInstanceId
|
|
44
|
+
WHERE
|
|
45
|
+
NOT m.IsPrivate
|
|
46
|
+
${this._hierarchyConfig.showEmptyModels ? "" : `AND EXISTS (SELECT 1 FROM ${this._hierarchyConfig.elementClassSpecification} WHERE Model.Id = m.ECInstanceId)`}
|
|
47
|
+
`;
|
|
48
|
+
for await (const row of this._queryExecutor.createQueryReader({ ecsql: modelsQuery }, { rowFormat: "ECSqlPropertyNames", limit: "unbounded" })) {
|
|
49
|
+
yield { id: row.id, parentId: row.parentId };
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
async getSubjectInfos() {
|
|
53
|
+
this._subjectInfos ??= (async () => {
|
|
54
|
+
const [subjectInfos, targetPartitionSubjects] = await Promise.all([
|
|
55
|
+
(async () => {
|
|
56
|
+
const result = new Map();
|
|
57
|
+
for await (const subject of this.querySubjects()) {
|
|
58
|
+
const subjectInfo = {
|
|
59
|
+
parentSubject: subject.parentId,
|
|
60
|
+
hideInHierarchy: subject.hideInHierarchy,
|
|
61
|
+
childSubjects: new Set(),
|
|
62
|
+
childModels: new Set(),
|
|
63
|
+
};
|
|
64
|
+
if (subject.targetPartitionId) {
|
|
65
|
+
subjectInfo.childModels.add(subject.targetPartitionId);
|
|
66
|
+
}
|
|
67
|
+
result.set(subject.id, subjectInfo);
|
|
68
|
+
}
|
|
69
|
+
return result;
|
|
70
|
+
})(),
|
|
71
|
+
(async () => {
|
|
72
|
+
const result = new Map();
|
|
73
|
+
for await (const model of this.queryModels()) {
|
|
74
|
+
pushToMap(result, model.id, model.parentId);
|
|
75
|
+
}
|
|
76
|
+
return result;
|
|
77
|
+
})(),
|
|
78
|
+
]);
|
|
79
|
+
for (const [subjectId, { parentSubject: parentSubjectId }] of subjectInfos.entries()) {
|
|
80
|
+
if (parentSubjectId) {
|
|
81
|
+
const parentSubjectInfo = subjectInfos.get(parentSubjectId);
|
|
82
|
+
assert(!!parentSubjectInfo);
|
|
83
|
+
parentSubjectInfo.childSubjects.add(subjectId);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
for (const [partitionId, subjectIds] of targetPartitionSubjects) {
|
|
87
|
+
subjectIds.forEach((subjectId) => {
|
|
88
|
+
const subjectInfo = subjectInfos.get(subjectId);
|
|
89
|
+
assert(!!subjectInfo);
|
|
90
|
+
subjectInfo.childModels.add(partitionId);
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
return subjectInfos;
|
|
94
|
+
})();
|
|
95
|
+
return this._subjectInfos;
|
|
96
|
+
}
|
|
97
|
+
/** Returns ECInstanceIDs of Subjects that either have direct Model or at least one child Subject with a Model. */
|
|
98
|
+
async getParentSubjectIds() {
|
|
99
|
+
this._parentSubjectIds ??= (async () => {
|
|
100
|
+
const subjectInfos = await this.getSubjectInfos();
|
|
101
|
+
const parentSubjectIds = new Set();
|
|
102
|
+
subjectInfos.forEach((subjectInfo, subjectId) => {
|
|
103
|
+
if (subjectInfo.childModels.size > 0) {
|
|
104
|
+
parentSubjectIds.add(subjectId);
|
|
105
|
+
let currParentId = subjectInfo.parentSubject;
|
|
106
|
+
while (currParentId) {
|
|
107
|
+
parentSubjectIds.add(currParentId);
|
|
108
|
+
currParentId = subjectInfos.get(currParentId)?.parentSubject;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
});
|
|
112
|
+
return [...parentSubjectIds];
|
|
113
|
+
})();
|
|
114
|
+
return this._parentSubjectIds;
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Returns child subjects of the specified parent subjects as they're displayed in the hierarchy - taking into
|
|
118
|
+
* account `hideInHierarchy` flag.
|
|
119
|
+
*/
|
|
120
|
+
async getChildSubjectIds(parentSubjectIds) {
|
|
121
|
+
const childSubjectIds = new Array();
|
|
122
|
+
const subjectInfos = await this.getSubjectInfos();
|
|
123
|
+
parentSubjectIds.forEach((subjectId) => {
|
|
124
|
+
forEachChildSubject(subjectInfos, subjectId, (childSubjectId, childSubjectInfo) => {
|
|
125
|
+
if (!childSubjectInfo.hideInHierarchy) {
|
|
126
|
+
childSubjectIds.push(childSubjectId);
|
|
127
|
+
return "break";
|
|
128
|
+
}
|
|
129
|
+
return "continue";
|
|
130
|
+
});
|
|
131
|
+
});
|
|
132
|
+
return childSubjectIds;
|
|
133
|
+
}
|
|
134
|
+
/** Returns ECInstanceIDs of all Models under specific parent Subjects, including their child Subjects, etc. */
|
|
135
|
+
async getSubjectModelIds(subjectIds) {
|
|
136
|
+
const subjectInfos = await this.getSubjectInfos();
|
|
137
|
+
const subjectStack = [...subjectIds];
|
|
138
|
+
const result = new Array();
|
|
139
|
+
while (true) {
|
|
140
|
+
const subjectId = subjectStack.pop();
|
|
141
|
+
if (subjectId === undefined) {
|
|
142
|
+
break;
|
|
143
|
+
}
|
|
144
|
+
const subjectInfo = subjectInfos.get(subjectId);
|
|
145
|
+
if (!subjectInfo) {
|
|
146
|
+
continue;
|
|
147
|
+
}
|
|
148
|
+
result.push(...subjectInfo.childModels);
|
|
149
|
+
subjectStack.push(...subjectInfo.childSubjects);
|
|
150
|
+
}
|
|
151
|
+
return result;
|
|
152
|
+
}
|
|
153
|
+
/** Returns ECInstanceIDs of Models under specific parent Subjects as they are displayed in the hierarchy. */
|
|
154
|
+
async getChildSubjectModelIds(parentSubjectIds) {
|
|
155
|
+
const subjectInfos = await this.getSubjectInfos();
|
|
156
|
+
const hiddenSubjectIds = new Array();
|
|
157
|
+
parentSubjectIds.forEach((subjectId) => {
|
|
158
|
+
forEachChildSubject(subjectInfos, subjectId, (childSubjectId, childSubjectInfo) => {
|
|
159
|
+
if (childSubjectInfo.hideInHierarchy) {
|
|
160
|
+
hiddenSubjectIds.push(childSubjectId);
|
|
161
|
+
return "continue";
|
|
162
|
+
}
|
|
163
|
+
return "break";
|
|
164
|
+
});
|
|
165
|
+
});
|
|
166
|
+
const modelIds = new Array();
|
|
167
|
+
[...parentSubjectIds, ...hiddenSubjectIds].forEach((subjectId) => {
|
|
168
|
+
const subjectInfo = subjectInfos.get(subjectId);
|
|
169
|
+
subjectInfo && modelIds.push(...subjectInfo.childModels);
|
|
170
|
+
});
|
|
171
|
+
return modelIds;
|
|
172
|
+
}
|
|
173
|
+
/**
|
|
174
|
+
* Returns a list of Subject ancestor ECInstanceIds from root to target Subject as displayed in the
|
|
175
|
+
* hierarchy - taking into account `hideInHierarchy` flag.
|
|
176
|
+
*/
|
|
177
|
+
async getSubjectAncestorsPath(targetSubjectId) {
|
|
178
|
+
const subjectInfos = await this.getSubjectInfos();
|
|
179
|
+
const result = new Array();
|
|
180
|
+
let currParentId = targetSubjectId;
|
|
181
|
+
while (currParentId) {
|
|
182
|
+
const parentInfo = subjectInfos.get(currParentId);
|
|
183
|
+
if (!parentInfo?.hideInHierarchy) {
|
|
184
|
+
result.push(currParentId);
|
|
185
|
+
}
|
|
186
|
+
currParentId = parentInfo?.parentSubject;
|
|
187
|
+
}
|
|
188
|
+
return result.reverse();
|
|
189
|
+
}
|
|
190
|
+
async *queryModelElementCounts() {
|
|
191
|
+
const query = /* sql */ `
|
|
192
|
+
SELECT Model.Id modelId, COUNT(*) elementCount
|
|
193
|
+
FROM ${this._hierarchyConfig.elementClassSpecification}
|
|
194
|
+
GROUP BY Model.Id
|
|
195
|
+
`;
|
|
196
|
+
for await (const row of this._queryExecutor.createQueryReader({ ecsql: query }, { rowFormat: "ECSqlPropertyNames", limit: "unbounded" })) {
|
|
197
|
+
yield { modelId: row.modelId, elementCount: row.elementCount };
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
async *queryModelCategories() {
|
|
201
|
+
const query = /* sql */ `
|
|
202
|
+
SELECT Model.Id modelId, Category.Id categoryId
|
|
203
|
+
FROM ${this._hierarchyConfig.elementClassSpecification}
|
|
204
|
+
WHERE Parent IS NULL
|
|
205
|
+
GROUP BY modelId, categoryId
|
|
206
|
+
`;
|
|
207
|
+
for await (const row of this._queryExecutor.createQueryReader({ ecsql: query }, { rowFormat: "ECSqlPropertyNames", limit: "unbounded" })) {
|
|
208
|
+
yield { modelId: row.modelId, categoryId: row.categoryId };
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
async getModelInfos() {
|
|
212
|
+
this._modelInfos ??= (async () => {
|
|
213
|
+
const modelInfos = new Map();
|
|
214
|
+
await Promise.all([
|
|
215
|
+
(async () => {
|
|
216
|
+
for await (const { modelId, categoryId } of this.queryModelCategories()) {
|
|
217
|
+
const entry = modelInfos.get(modelId);
|
|
218
|
+
if (entry) {
|
|
219
|
+
entry.categories.add(categoryId);
|
|
220
|
+
}
|
|
221
|
+
else {
|
|
222
|
+
modelInfos.set(modelId, { categories: new Set([categoryId]), elementCount: 0 });
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
})(),
|
|
226
|
+
(async () => {
|
|
227
|
+
for await (const { modelId, elementCount } of this.queryModelElementCounts()) {
|
|
228
|
+
const entry = modelInfos.get(modelId);
|
|
229
|
+
if (entry) {
|
|
230
|
+
entry.elementCount = elementCount;
|
|
231
|
+
}
|
|
232
|
+
else {
|
|
233
|
+
modelInfos.set(modelId, { categories: new Set(), elementCount });
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
})(),
|
|
237
|
+
]);
|
|
238
|
+
return modelInfos;
|
|
239
|
+
})();
|
|
240
|
+
return this._modelInfos;
|
|
241
|
+
}
|
|
242
|
+
async getModelCategories(modelId) {
|
|
243
|
+
const modelInfos = await this.getModelInfos();
|
|
244
|
+
const categories = modelInfos.get(modelId)?.categories;
|
|
245
|
+
return categories ? [...categories] : [];
|
|
246
|
+
}
|
|
247
|
+
async getModelElementCount(modelId) {
|
|
248
|
+
const modelInfos = await this.getModelInfos();
|
|
249
|
+
return modelInfos.get(modelId)?.elementCount ?? 0;
|
|
250
|
+
}
|
|
251
|
+
async getModelSubjects(modelId) {
|
|
252
|
+
const result = new Array();
|
|
253
|
+
const subjectInfos = await this.getSubjectInfos();
|
|
254
|
+
subjectInfos.forEach((subjectInfo, subjectId) => {
|
|
255
|
+
if (subjectInfo.childModels.has(modelId)) {
|
|
256
|
+
result.push(subjectId);
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
return result;
|
|
260
|
+
}
|
|
261
|
+
async queryCategoryElementsCount(modelId, categoryId) {
|
|
262
|
+
const reader = this._queryExecutor.createQueryReader({
|
|
263
|
+
ctes: [
|
|
264
|
+
/* sql */ `
|
|
265
|
+
CategoryElements(id) AS (
|
|
266
|
+
SELECT ECInstanceId id
|
|
267
|
+
FROM ${this._hierarchyConfig.elementClassSpecification}
|
|
268
|
+
WHERE
|
|
269
|
+
Model.Id = ?
|
|
270
|
+
AND Category.Id = ?
|
|
271
|
+
AND Parent IS NULL
|
|
272
|
+
|
|
273
|
+
UNION ALL
|
|
274
|
+
|
|
275
|
+
SELECT c.ECInstanceId id
|
|
276
|
+
FROM ${this._hierarchyConfig.elementClassSpecification} c
|
|
277
|
+
JOIN CategoryElements p ON c.Parent.Id = p.id
|
|
278
|
+
)
|
|
279
|
+
`,
|
|
280
|
+
],
|
|
281
|
+
ecsql: `SELECT COUNT(*) FROM CategoryElements`,
|
|
282
|
+
bindings: [
|
|
283
|
+
{ type: "id", value: modelId },
|
|
284
|
+
{ type: "id", value: categoryId },
|
|
285
|
+
],
|
|
286
|
+
}, { rowFormat: "Indexes", limit: "unbounded" });
|
|
287
|
+
return (await reader.next()).value[0];
|
|
288
|
+
}
|
|
289
|
+
async getCategoryElementsCount(modelId, categoryId) {
|
|
290
|
+
const cacheKey = `${modelId}${categoryId}`;
|
|
291
|
+
let result = this._categoryElementCounts.get(cacheKey);
|
|
292
|
+
if (result !== undefined) {
|
|
293
|
+
return result;
|
|
294
|
+
}
|
|
295
|
+
result = await this.queryCategoryElementsCount(modelId, categoryId);
|
|
296
|
+
this._categoryElementCounts.set(cacheKey, result);
|
|
297
|
+
return result;
|
|
298
|
+
}
|
|
299
|
+
async getCategoryModels(categoryId) {
|
|
300
|
+
const result = new Set();
|
|
301
|
+
const modelInfos = await this.getModelInfos();
|
|
302
|
+
modelInfos?.forEach((modelInfo, modelId) => {
|
|
303
|
+
if (modelInfo.categories.has(categoryId)) {
|
|
304
|
+
result.add(modelId);
|
|
305
|
+
}
|
|
306
|
+
});
|
|
307
|
+
return [...result];
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
function forEachChildSubject(subjectInfos, parentSubject, cb) {
|
|
311
|
+
const parentSubjectInfo = typeof parentSubject === "string" ? subjectInfos.get(parentSubject) : parentSubject;
|
|
312
|
+
parentSubjectInfo &&
|
|
313
|
+
parentSubjectInfo.childSubjects.forEach((childSubjectId) => {
|
|
314
|
+
const childSubjectInfo = subjectInfos.get(childSubjectId);
|
|
315
|
+
if (cb(childSubjectId, childSubjectInfo) === "break") {
|
|
316
|
+
return;
|
|
317
|
+
}
|
|
318
|
+
forEachChildSubject(subjectInfos, childSubjectInfo, cb);
|
|
319
|
+
});
|
|
320
|
+
}
|
|
321
|
+
//# sourceMappingURL=ModelsTreeIdsCache.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModelsTreeIdsCache.js","sourceRoot":"","sources":["../../../../../../src/components/trees/models-tree/internal/ModelsTreeIdsCache.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAEhG,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAoB/C,gBAAgB;AAChB,MAAM,OAAO,kBAAkB;IAM7B,YACU,cAA0C,EAC1C,gBAAkD;QADlD,mBAAc,GAAd,cAAc,CAA4B;QAC1C,qBAAgB,GAAhB,gBAAgB,CAAkC;QAP3C,2BAAsB,GAAG,IAAI,GAAG,EAAsB,CAAC;IAQrE,CAAC;IAEI,KAAK,CAAC,CAAC,aAAa;QAC1B,MAAM,aAAa,GAAG;;;;;;;;;wCASc,IAAI,CAAC,gBAAgB,CAAC,yBAAyB;;;;;;;;;;KAUlF,CAAC;QACF,IAAI,KAAK,EAAE,MAAM,GAAG,IAAI,IAAI,CAAC,cAAc,CAAC,iBAAiB,CAAC,EAAE,KAAK,EAAE,aAAa,EAAE,EAAE,EAAE,SAAS,EAAE,oBAAoB,EAAE,KAAK,EAAE,WAAW,EAAE,CAAC,EAAE;YAChJ,MAAM,EAAE,EAAE,EAAE,GAAG,CAAC,EAAE,EAAE,QAAQ,EAAE,GAAG,CAAC,QAAQ,EAAE,iBAAiB,EAAE,GAAG,CAAC,iBAAiB,EAAE,eAAe,EAAE,CAAC,CAAC,GAAG,CAAC,eAAe,EAAE,CAAC;SAChI;IACH,CAAC;IAEO,KAAK,CAAC,CAAC,WAAW;QACxB,MAAM,WAAW,GAAG;;;;;;UAMd,IAAI,CAAC,gBAAgB,CAAC,eAAe,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,6BAA6B,IAAI,CAAC,gBAAgB,CAAC,yBAAyB,mCAAmC;KACjK,CAAC;QACF,IAAI,KAAK,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MAAM,iBAAiB,GAAG,OAAO,aAAa,KAAK,QAAQ,CAAC,CAAC,CAAC,YAAY,CAAC,GAAG,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC;IAC9G,iBAAiB;QACf,iBAAiB,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC,cAAc,EAAE,EAAE;YACzD,MAAM,gBAAgB,GAAG,YAAY,CAAC,GAAG,CAAC,cAAc,CAAE,CAAC;YAC3D,IAAI,EAAE,CAAC,cAAc,EAAE,gBAAgB,CAAC,KAAK,OAAO,EAAE;gBACpD,OAAO;aACR;YACD,mBAAmB,CAAC,YAAY,EAAE,gBAAgB,EAAE,EAAE,CAAC,CAAC;QAC1D,CAAC,CAAC,CAAC;AACP,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\nimport { assert } from \"@itwin/core-bentley\";\nimport { pushToMap } from \"../../common/Utils\";\n\nimport type { ModelsTreeDefinition } from \"../ModelsTreeDefinition\";\nimport type { Id64Array, Id64Set, Id64String } from \"@itwin/core-bentley\";\nimport type { LimitingECSqlQueryExecutor } from \"@itwin/presentation-hierarchies\";\n\ninterface SubjectInfo {\n parentSubject: Id64String | undefined;\n hideInHierarchy: boolean;\n childSubjects: Id64Set;\n childModels: Id64Set;\n}\n\ninterface ModelInfo {\n categories: Id64Set;\n elementCount: number;\n}\n\ntype ModelsTreeHierarchyConfiguration = ConstructorParameters<typeof ModelsTreeDefinition>[0][\"hierarchyConfig\"];\n\n/** @internal */\nexport class ModelsTreeIdsCache {\n private readonly _categoryElementCounts = new Map<Id64String, number>();\n private _subjectInfos: Promise<Map<Id64String, SubjectInfo>> | undefined;\n private _parentSubjectIds: Promise<Id64Array> | undefined; // the list should contain a subject id if its node should be shown as having children\n private _modelInfos: Promise<Map<Id64String, ModelInfo>> | undefined;\n\n constructor(\n private _queryExecutor: LimitingECSqlQueryExecutor,\n private _hierarchyConfig: ModelsTreeHierarchyConfiguration,\n ) {}\n\n private async *querySubjects(): AsyncIterableIterator<{ id: Id64String; parentId?: Id64String; targetPartitionId?: Id64String; hideInHierarchy: boolean }> {\n const subjectsQuery = `\n SELECT\n s.ECInstanceId id,\n s.Parent.Id parentId,\n (\n SELECT m.ECInstanceId\n FROM bis.GeometricModel3d m\n WHERE m.ECInstanceId = HexToId(json_extract(s.JsonProperties, '$.Subject.Model.TargetPartition'))\n AND NOT m.IsPrivate\n AND EXISTS (SELECT 1 FROM ${this._hierarchyConfig.elementClassSpecification} WHERE Model.Id = m.ECInstanceId)\n ) targetPartitionId,\n CASE\n WHEN (\n json_extract(s.JsonProperties, '$.Subject.Job.Bridge') IS NOT NULL\n OR json_extract(s.JsonProperties, '$.Subject.Model.Type') = 'Hierarchy'\n ) THEN 1\n ELSE 0\n END hideInHierarchy\n FROM bis.Subject s\n `;\n for await (const row of this._queryExecutor.createQueryReader({ ecsql: subjectsQuery }, { rowFormat: \"ECSqlPropertyNames\", limit: \"unbounded\" })) {\n yield { id: row.id, parentId: row.parentId, targetPartitionId: row.targetPartitionId, hideInHierarchy: !!row.hideInHierarchy };\n }\n }\n\n private async *queryModels(): AsyncIterableIterator<{ id: Id64String; parentId: Id64String }> {\n const modelsQuery = `\n SELECT p.ECInstanceId id, p.Parent.Id parentId\n FROM bis.InformationPartitionElement p\n INNER JOIN bis.GeometricModel3d m ON m.ModeledElement.Id = p.ECInstanceId\n WHERE\n NOT m.IsPrivate\n ${this._hierarchyConfig.showEmptyModels ? \"\" : `AND EXISTS (SELECT 1 FROM ${this._hierarchyConfig.elementClassSpecification} WHERE Model.Id = m.ECInstanceId)`}\n `;\n for await (const row of this._queryExecutor.createQueryReader({ ecsql: modelsQuery }, { rowFormat: \"ECSqlPropertyNames\", limit: \"unbounded\" })) {\n yield { id: row.id, parentId: row.parentId };\n }\n }\n\n private async getSubjectInfos() {\n this._subjectInfos ??= (async () => {\n const [subjectInfos, targetPartitionSubjects] = await Promise.all([\n (async () => {\n const result = new Map<Id64String, SubjectInfo>();\n for await (const subject of this.querySubjects()) {\n const subjectInfo: SubjectInfo = {\n parentSubject: subject.parentId,\n hideInHierarchy: subject.hideInHierarchy,\n childSubjects: new Set(),\n childModels: new Set(),\n };\n if (subject.targetPartitionId) {\n subjectInfo.childModels.add(subject.targetPartitionId);\n }\n result.set(subject.id, subjectInfo);\n }\n return result;\n })(),\n (async () => {\n const result = new Map<Id64String, Set<Id64String>>();\n for await (const model of this.queryModels()) {\n pushToMap(result, model.id, model.parentId);\n }\n return result;\n })(),\n ]);\n\n for (const [subjectId, { parentSubject: parentSubjectId }] of subjectInfos.entries()) {\n if (parentSubjectId) {\n const parentSubjectInfo = subjectInfos.get(parentSubjectId);\n assert(!!parentSubjectInfo);\n parentSubjectInfo.childSubjects.add(subjectId);\n }\n }\n\n for (const [partitionId, subjectIds] of targetPartitionSubjects) {\n subjectIds.forEach((subjectId) => {\n const subjectInfo = subjectInfos.get(subjectId);\n assert(!!subjectInfo);\n subjectInfo.childModels.add(partitionId);\n });\n }\n\n return subjectInfos;\n })();\n return this._subjectInfos;\n }\n\n /** Returns ECInstanceIDs of Subjects that either have direct Model or at least one child Subject with a Model. */\n public async getParentSubjectIds(): Promise<Id64String[]> {\n this._parentSubjectIds ??= (async () => {\n const subjectInfos = await this.getSubjectInfos();\n const parentSubjectIds = new Set<Id64String>();\n subjectInfos.forEach((subjectInfo, subjectId) => {\n if (subjectInfo.childModels.size > 0) {\n parentSubjectIds.add(subjectId);\n let currParentId = subjectInfo.parentSubject;\n while (currParentId) {\n parentSubjectIds.add(currParentId);\n currParentId = subjectInfos.get(currParentId)?.parentSubject;\n }\n }\n });\n return [...parentSubjectIds];\n })();\n return this._parentSubjectIds;\n }\n\n /**\n * Returns child subjects of the specified parent subjects as they're displayed in the hierarchy - taking into\n * account `hideInHierarchy` flag.\n */\n public async getChildSubjectIds(parentSubjectIds: Id64String[]): Promise<Id64String[]> {\n const childSubjectIds = new Array<Id64String>();\n const subjectInfos = await this.getSubjectInfos();\n parentSubjectIds.forEach((subjectId) => {\n forEachChildSubject(subjectInfos, subjectId, (childSubjectId, childSubjectInfo) => {\n if (!childSubjectInfo.hideInHierarchy) {\n childSubjectIds.push(childSubjectId);\n return \"break\";\n }\n return \"continue\";\n });\n });\n return childSubjectIds;\n }\n\n /** Returns ECInstanceIDs of all Models under specific parent Subjects, including their child Subjects, etc. */\n public async getSubjectModelIds(subjectIds: Id64Array): Promise<Id64Array> {\n const subjectInfos = await this.getSubjectInfos();\n const subjectStack = [...subjectIds];\n const result = new Array<Id64String>();\n while (true) {\n const subjectId = subjectStack.pop();\n if (subjectId === undefined) {\n break;\n }\n const subjectInfo = subjectInfos.get(subjectId);\n if (!subjectInfo) {\n continue;\n }\n result.push(...subjectInfo.childModels);\n subjectStack.push(...subjectInfo.childSubjects);\n }\n return result;\n }\n\n /** Returns ECInstanceIDs of Models under specific parent Subjects as they are displayed in the hierarchy. */\n public async getChildSubjectModelIds(parentSubjectIds: Id64String[]): Promise<Id64String[]> {\n const subjectInfos = await this.getSubjectInfos();\n\n const hiddenSubjectIds = new Array<Id64String>();\n parentSubjectIds.forEach((subjectId) => {\n forEachChildSubject(subjectInfos, subjectId, (childSubjectId, childSubjectInfo) => {\n if (childSubjectInfo.hideInHierarchy) {\n hiddenSubjectIds.push(childSubjectId);\n return \"continue\";\n }\n return \"break\";\n });\n });\n\n const modelIds = new Array<Id64String>();\n [...parentSubjectIds, ...hiddenSubjectIds].forEach((subjectId) => {\n const subjectInfo = subjectInfos.get(subjectId);\n subjectInfo && modelIds.push(...subjectInfo.childModels);\n });\n return modelIds;\n }\n\n /**\n * Returns a list of Subject ancestor ECInstanceIds from root to target Subject as displayed in the\n * hierarchy - taking into account `hideInHierarchy` flag.\n */\n public async getSubjectAncestorsPath(targetSubjectId: Id64String): Promise<Id64Array> {\n const subjectInfos = await this.getSubjectInfos();\n const result = new Array<Id64String>();\n let currParentId: Id64String | undefined = targetSubjectId;\n while (currParentId) {\n const parentInfo = subjectInfos.get(currParentId);\n if (!parentInfo?.hideInHierarchy) {\n result.push(currParentId);\n }\n currParentId = parentInfo?.parentSubject;\n }\n return result.reverse();\n }\n\n private async *queryModelElementCounts() {\n const query = /* sql */ `\n SELECT Model.Id modelId, COUNT(*) elementCount\n FROM ${this._hierarchyConfig.elementClassSpecification}\n GROUP BY Model.Id\n `;\n for await (const row of this._queryExecutor.createQueryReader({ ecsql: query }, { rowFormat: \"ECSqlPropertyNames\", limit: \"unbounded\" })) {\n yield { modelId: row.modelId, elementCount: row.elementCount };\n }\n }\n\n private async *queryModelCategories() {\n const query = /* sql */ `\n SELECT Model.Id modelId, Category.Id categoryId\n FROM ${this._hierarchyConfig.elementClassSpecification}\n WHERE Parent IS NULL\n GROUP BY modelId, categoryId\n `;\n for await (const row of this._queryExecutor.createQueryReader({ ecsql: query }, { rowFormat: \"ECSqlPropertyNames\", limit: \"unbounded\" })) {\n yield { modelId: row.modelId, categoryId: row.categoryId };\n }\n }\n\n private async getModelInfos() {\n this._modelInfos ??= (async () => {\n const modelInfos = new Map<Id64String, { categories: Id64Set; elementCount: number }>();\n await Promise.all([\n (async () => {\n for await (const { modelId, categoryId } of this.queryModelCategories()) {\n const entry = modelInfos.get(modelId);\n if (entry) {\n entry.categories.add(categoryId);\n } else {\n modelInfos.set(modelId, { categories: new Set([categoryId]), elementCount: 0 });\n }\n }\n })(),\n (async () => {\n for await (const { modelId, elementCount } of this.queryModelElementCounts()) {\n const entry = modelInfos.get(modelId);\n if (entry) {\n entry.elementCount = elementCount;\n } else {\n modelInfos.set(modelId, { categories: new Set(), elementCount });\n }\n }\n })(),\n ]);\n return modelInfos;\n })();\n return this._modelInfos;\n }\n\n public async getModelCategories(modelId: Id64String): Promise<Id64Array> {\n const modelInfos = await this.getModelInfos();\n const categories = modelInfos.get(modelId)?.categories;\n return categories ? [...categories] : [];\n }\n\n public async getModelElementCount(modelId: Id64String): Promise<number> {\n const modelInfos = await this.getModelInfos();\n return modelInfos.get(modelId)?.elementCount ?? 0;\n }\n\n public async getModelSubjects(modelId: Id64String): Promise<Id64Array> {\n const result = new Array<Id64String>();\n const subjectInfos = await this.getSubjectInfos();\n subjectInfos.forEach((subjectInfo, subjectId) => {\n if (subjectInfo.childModels.has(modelId)) {\n result.push(subjectId);\n }\n });\n return result;\n }\n\n private async queryCategoryElementsCount(modelId: Id64String, categoryId: Id64String): Promise<number> {\n const reader = this._queryExecutor.createQueryReader(\n {\n ctes: [\n /* sql */ `\n CategoryElements(id) AS (\n SELECT ECInstanceId id\n FROM ${this._hierarchyConfig.elementClassSpecification}\n WHERE\n Model.Id = ?\n AND Category.Id = ?\n AND Parent IS NULL\n\n UNION ALL\n\n SELECT c.ECInstanceId id\n FROM ${this._hierarchyConfig.elementClassSpecification} c\n JOIN CategoryElements p ON c.Parent.Id = p.id\n )\n `,\n ],\n ecsql: `SELECT COUNT(*) FROM CategoryElements`,\n bindings: [\n { type: \"id\", value: modelId },\n { type: \"id\", value: categoryId },\n ],\n },\n { rowFormat: \"Indexes\", limit: \"unbounded\" },\n );\n\n return (await reader.next()).value[0];\n }\n\n public async getCategoryElementsCount(modelId: Id64String, categoryId: Id64String): Promise<number> {\n const cacheKey = `${modelId}${categoryId}`;\n let result = this._categoryElementCounts.get(cacheKey);\n if (result !== undefined) {\n return result;\n }\n\n result = await this.queryCategoryElementsCount(modelId, categoryId);\n this._categoryElementCounts.set(cacheKey, result);\n return result;\n }\n\n public async getCategoryModels(categoryId: Id64String): Promise<Id64Array> {\n const result = new Set<Id64String>();\n const modelInfos = await this.getModelInfos();\n modelInfos?.forEach((modelInfo, modelId) => {\n if (modelInfo.categories.has(categoryId)) {\n result.add(modelId);\n }\n });\n return [...result];\n }\n}\n\nfunction forEachChildSubject(\n subjectInfos: Map<Id64String, SubjectInfo>,\n parentSubject: Id64String | SubjectInfo,\n cb: (childSubjectId: Id64String, childSubjectInfo: SubjectInfo) => \"break\" | \"continue\",\n) {\n const parentSubjectInfo = typeof parentSubject === \"string\" ? subjectInfos.get(parentSubject) : parentSubject;\n parentSubjectInfo &&\n parentSubjectInfo.childSubjects.forEach((childSubjectId) => {\n const childSubjectInfo = subjectInfos.get(childSubjectId)!;\n if (cb(childSubjectId, childSubjectInfo) === \"break\") {\n return;\n }\n forEachChildSubject(subjectInfos, childSubjectInfo, cb);\n });\n}\n"]}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { Id64String } from "@itwin/core-bentley";
|
|
2
|
+
interface ModelsTreeNode {
|
|
3
|
+
extendedData?: any;
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* @internal
|
|
7
|
+
*/
|
|
8
|
+
export declare namespace ModelsTreeNode {
|
|
9
|
+
/**
|
|
10
|
+
* Determines if a node represents a subject.
|
|
11
|
+
*/
|
|
12
|
+
const isSubjectNode: (node: ModelsTreeNode) => boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Determines if a node represents a model.
|
|
15
|
+
*/
|
|
16
|
+
const isModelNode: (node: ModelsTreeNode) => boolean;
|
|
17
|
+
/**
|
|
18
|
+
* Determines if a node represents a category.
|
|
19
|
+
*/
|
|
20
|
+
const isCategoryNode: (node: ModelsTreeNode) => boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Retrieves model ID from node's extended data.
|
|
23
|
+
*/
|
|
24
|
+
const getModelId: (node: ModelsTreeNode) => Id64String | undefined;
|
|
25
|
+
/**
|
|
26
|
+
* Retrieves category ID from node's extended data.
|
|
27
|
+
*/
|
|
28
|
+
const getCategoryId: (node: ModelsTreeNode) => Id64String | undefined;
|
|
29
|
+
}
|
|
30
|
+
export {};
|
|
31
|
+
//# sourceMappingURL=ModelsTreeNode.d.ts.map
|
|
@@ -0,0 +1,37 @@
|
|
|
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
|
+
/**
|
|
6
|
+
* @internal
|
|
7
|
+
*/
|
|
8
|
+
export var ModelsTreeNode;
|
|
9
|
+
(function (ModelsTreeNode) {
|
|
10
|
+
/**
|
|
11
|
+
* Determines if a node represents a subject.
|
|
12
|
+
*/
|
|
13
|
+
ModelsTreeNode.isSubjectNode = (node) => !!node.extendedData?.isSubject;
|
|
14
|
+
/**
|
|
15
|
+
* Determines if a node represents a model.
|
|
16
|
+
*/
|
|
17
|
+
ModelsTreeNode.isModelNode = (node) => !!node.extendedData?.isModel;
|
|
18
|
+
/**
|
|
19
|
+
* Determines if a node represents a category.
|
|
20
|
+
*/
|
|
21
|
+
ModelsTreeNode.isCategoryNode = (node) => !!node.extendedData?.isCategory;
|
|
22
|
+
/**
|
|
23
|
+
* Retrieves model ID from node's extended data.
|
|
24
|
+
*/
|
|
25
|
+
ModelsTreeNode.getModelId = (node) => {
|
|
26
|
+
if (node.extendedData?.modelId) {
|
|
27
|
+
return node.extendedData?.modelId;
|
|
28
|
+
}
|
|
29
|
+
const modelIds = node.extendedData?.modelIds?.[0];
|
|
30
|
+
return modelIds && (Array.isArray(modelIds) ? modelIds[0] : modelIds);
|
|
31
|
+
};
|
|
32
|
+
/**
|
|
33
|
+
* Retrieves category ID from node's extended data.
|
|
34
|
+
*/
|
|
35
|
+
ModelsTreeNode.getCategoryId = (node) => node.extendedData?.categoryId;
|
|
36
|
+
})(ModelsTreeNode || (ModelsTreeNode = {}));
|
|
37
|
+
//# sourceMappingURL=ModelsTreeNode.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModelsTreeNode.js","sourceRoot":"","sources":["../../../../../../src/components/trees/models-tree/internal/ModelsTreeNode.ts"],"names":[],"mappings":"AAAA;;;gGAGgG;AAQhG;;GAEG;AACH,MAAM,KAAW,cAAc,CAgC9B;AAhCD,WAAiB,cAAc;IAC7B;;OAEG;IACU,4BAAa,GAAG,CAAC,IAAoB,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,YAAY,EAAE,SAAS,CAAC;IAEtF;;OAEG;IACU,0BAAW,GAAG,CAAC,IAAoB,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC;IAElF;;OAEG;IACU,6BAAc,GAAG,CAAC,IAAoB,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC;IAExF;;OAEG;IACU,yBAAU,GAAG,CAAC,IAAoB,EAA0B,EAAE;QACzE,IAAI,IAAI,CAAC,YAAY,EAAE,OAAO,EAAE;YAC9B,OAAO,IAAI,CAAC,YAAY,EAAE,OAAO,CAAC;SACnC;QAED,MAAM,QAAQ,GAAG,IAAI,CAAC,YAAY,EAAE,QAAQ,EAAE,CAAC,CAAC,CAAC,CAAC;QAClD,OAAO,QAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC;IACxE,CAAC,CAAC;IAEF;;OAEG;IACU,4BAAa,GAAG,CAAC,IAAoB,EAA0B,EAAE,CAAC,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC;AAC/G,CAAC,EAhCgB,cAAc,KAAd,cAAc,QAgC9B","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\nimport type { Id64String } from \"@itwin/core-bentley\";\n\ninterface ModelsTreeNode {\n extendedData?: any;\n}\n\n/**\n * @internal\n */\nexport namespace ModelsTreeNode {\n /**\n * Determines if a node represents a subject.\n */\n export const isSubjectNode = (node: ModelsTreeNode) => !!node.extendedData?.isSubject;\n\n /**\n * Determines if a node represents a model.\n */\n export const isModelNode = (node: ModelsTreeNode) => !!node.extendedData?.isModel;\n\n /**\n * Determines if a node represents a category.\n */\n export const isCategoryNode = (node: ModelsTreeNode) => !!node.extendedData?.isCategory;\n\n /**\n * Retrieves model ID from node's extended data.\n */\n export const getModelId = (node: ModelsTreeNode): Id64String | undefined => {\n if (node.extendedData?.modelId) {\n return node.extendedData?.modelId;\n }\n\n const modelIds = node.extendedData?.modelIds?.[0];\n return modelIds && (Array.isArray(modelIds) ? modelIds[0] : modelIds);\n };\n\n /**\n * Retrieves category ID from node's extended data.\n */\n export const getCategoryId = (node: ModelsTreeNode): Id64String | undefined => node.extendedData?.categoryId;\n}\n"]}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import type { ModelsTreeIdsCache } from "./ModelsTreeIdsCache";
|
|
2
|
+
import type { Id64Arg, Id64Array, Id64String } from "@itwin/core-bentley";
|
|
3
|
+
import type { GroupingHierarchyNode } from "@itwin/presentation-hierarchies";
|
|
4
|
+
import type { Viewport } from "@itwin/core-frontend";
|
|
5
|
+
import type { HierarchyVisibilityHandler, VisibilityStatus } from "../../common/UseHierarchyVisibility";
|
|
6
|
+
import type { ECClassHierarchyInspector } from "@itwin/presentation-shared";
|
|
7
|
+
interface GetCategoryStatusProps {
|
|
8
|
+
categoryId: Id64String;
|
|
9
|
+
modelId: Id64String;
|
|
10
|
+
}
|
|
11
|
+
interface ChangeCategoryStateProps extends GetCategoryStatusProps {
|
|
12
|
+
on: boolean;
|
|
13
|
+
}
|
|
14
|
+
interface GetElementStateProps {
|
|
15
|
+
elementId: Id64String;
|
|
16
|
+
modelId: Id64String;
|
|
17
|
+
categoryId: Id64String;
|
|
18
|
+
}
|
|
19
|
+
interface ChangeElementStateProps extends GetElementStateProps {
|
|
20
|
+
on: boolean;
|
|
21
|
+
}
|
|
22
|
+
interface ChangeModelStateProps {
|
|
23
|
+
ids: Id64Arg;
|
|
24
|
+
on: boolean;
|
|
25
|
+
}
|
|
26
|
+
export declare const SUBJECT_CLASS_NAME: "BisCore.Subject";
|
|
27
|
+
export declare const MODEL_CLASS_NAME: "BisCore.GeometricModel3d";
|
|
28
|
+
export declare const CATEGORY_CLASS_NAME: "BisCore.SpatialCategory";
|
|
29
|
+
export declare const ELEMENT_CLASS_NAME: "BisCore.GeometricElement3d";
|
|
30
|
+
/**
|
|
31
|
+
* Properties for a method of `ModelsTreeVisibilityHandler` that can be overridden.
|
|
32
|
+
*/
|
|
33
|
+
type OverridableMethodProps<TFunc> = TFunc extends (props: infer TProps) => infer TResult ? TProps & {
|
|
34
|
+
/** A callback that produces the value from the original implementation. */
|
|
35
|
+
readonly originalImplementation: () => TResult;
|
|
36
|
+
/**
|
|
37
|
+
* Reference to the hierarchy based handler.
|
|
38
|
+
* @note Calling `getVisibility` or `changeVisibility` of this object invokes the overridden implementation as well.
|
|
39
|
+
*/
|
|
40
|
+
readonly handler: ModelsTreeVisibilityHandler;
|
|
41
|
+
} : never;
|
|
42
|
+
/**
|
|
43
|
+
* Function type for an overridden method of `ModelsTreeVisibilityHandler`.
|
|
44
|
+
*/
|
|
45
|
+
type OverridableMethod<TFunc> = TFunc extends (...args: any[]) => infer TResult ? (props: OverridableMethodProps<TFunc>) => TResult : never;
|
|
46
|
+
/**
|
|
47
|
+
* Functionality of `ModelsTreeVisibilityHandler` that can be overridden.
|
|
48
|
+
* Each callback will be provided original implementation and reference to a `HierarchyVisibilityHandler`.
|
|
49
|
+
*/
|
|
50
|
+
interface VisibilityHandlerOverrides {
|
|
51
|
+
getSubjectNodeVisibility?: OverridableMethod<(props: {
|
|
52
|
+
ids: Id64Array;
|
|
53
|
+
}) => Promise<VisibilityStatus>>;
|
|
54
|
+
getModelDisplayStatus?: OverridableMethod<(props: {
|
|
55
|
+
id: Id64String;
|
|
56
|
+
}) => Promise<VisibilityStatus>>;
|
|
57
|
+
getCategoryDisplayStatus?: OverridableMethod<(props: GetCategoryStatusProps) => Promise<VisibilityStatus>>;
|
|
58
|
+
getElementGroupingNodeDisplayStatus?: OverridableMethod<(props: {
|
|
59
|
+
node: GroupingHierarchyNode;
|
|
60
|
+
}) => Promise<VisibilityStatus>>;
|
|
61
|
+
getElementDisplayStatus?: OverridableMethod<(props: GetElementStateProps) => Promise<VisibilityStatus>>;
|
|
62
|
+
changeSubjectNodeState?: OverridableMethod<(props: {
|
|
63
|
+
ids: Id64Array;
|
|
64
|
+
on: boolean;
|
|
65
|
+
}) => Promise<void>>;
|
|
66
|
+
changeModelState?: OverridableMethod<(props: ChangeModelStateProps) => Promise<void>>;
|
|
67
|
+
changeCategoryState?: OverridableMethod<(props: ChangeCategoryStateProps) => Promise<void>>;
|
|
68
|
+
changeElementGroupingNodeState?: OverridableMethod<(props: {
|
|
69
|
+
node: GroupingHierarchyNode;
|
|
70
|
+
on: boolean;
|
|
71
|
+
}) => Promise<void>>;
|
|
72
|
+
changeElementState?: OverridableMethod<(props: ChangeElementStateProps) => Promise<void>>;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Properties for `ModelsTreeVisibilityHandler`.
|
|
76
|
+
* @internal
|
|
77
|
+
*/
|
|
78
|
+
export interface ModelsTreeVisibilityHandlerProps {
|
|
79
|
+
viewport: Viewport;
|
|
80
|
+
idsCache: ModelsTreeIdsCache;
|
|
81
|
+
imodelAccess: ECClassHierarchyInspector;
|
|
82
|
+
overrides?: VisibilityHandlerOverrides;
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Hierarchy based visibility handler.
|
|
86
|
+
* When determining visibility for nodes, it should take into account the visibility of their children.
|
|
87
|
+
* @internal
|
|
88
|
+
*/
|
|
89
|
+
export type ModelsTreeVisibilityHandler = HierarchyVisibilityHandler;
|
|
90
|
+
/**
|
|
91
|
+
* Creates an instance if `ModelsTreeVisibilityHandler`.
|
|
92
|
+
* @internal
|
|
93
|
+
*/
|
|
94
|
+
export declare function createModelsTreeVisibilityHandler(props: ModelsTreeVisibilityHandlerProps): ModelsTreeVisibilityHandler;
|
|
95
|
+
/**
|
|
96
|
+
* Enables display of all given models. Also enables display of all categories and clears always and
|
|
97
|
+
* never drawn lists in the viewport.
|
|
98
|
+
* @public
|
|
99
|
+
*/
|
|
100
|
+
export declare function showAllModels(models: string[], viewport: Viewport): Promise<void>;
|
|
101
|
+
/**
|
|
102
|
+
* Disables display of all given models.
|
|
103
|
+
* @public
|
|
104
|
+
*/
|
|
105
|
+
export declare function hideAllModels(models: string[], viewport: Viewport): Promise<void>;
|
|
106
|
+
/**
|
|
107
|
+
* Inverts display of all given models.
|
|
108
|
+
* @public
|
|
109
|
+
*/
|
|
110
|
+
export declare function invertAllModels(models: string[], viewport: Viewport): Promise<void>;
|
|
111
|
+
/**
|
|
112
|
+
* Based on the value of `enable` argument, either enables or disables display of given models.
|
|
113
|
+
* @public
|
|
114
|
+
*/
|
|
115
|
+
export declare function toggleModels(models: string[], enable: boolean, viewport: Viewport): Promise<void>;
|
|
116
|
+
/**
|
|
117
|
+
* Checks if all given models are displayed in given viewport.
|
|
118
|
+
* @public
|
|
119
|
+
*/
|
|
120
|
+
export declare function areAllModelsVisible(models: string[], viewport: Viewport): boolean;
|
|
121
|
+
export {};
|
|
122
|
+
//# sourceMappingURL=ModelsTreeVisibilityHandler.d.ts.map
|