tree-widget question
Hi ,When I open a file that doesn't contain any geometric elements, the tree doesn't display any models, even though the file does contain models. After I create a geometric element, the tree still doesn't update. I have to reopen the file for the model to appear in the tree. Is this a bug or expected behavior? Is there a way to make the tree show models even when opening a file without geometry?
Reopen the file
Hi. You can configure Models tree to show empty models by passing in this prop to ModelsTreeComponent:
<ModelsTreeComponent
hierarchyConfig={{
showEmptyModels: true,
}}
/>
Models tree should update when elements are inserted into an iModel. Can you show the snippet of code adding elements to iModel?
Thank you ! What about category ? The CategoriesTreeComponent componet doesn't have the hierarchyConfig prop.
I use a tool , CreateLineStringTool , to insert elements
What about category ? The
CategoriesTreeComponentcomponet doesn't have thehierarchyConfigprop.
https://github.com/iTwin/viewer-components-react/issues/1383
I use a tool ,
CreateLineStringTool, to insert elements
Am I right to think this is an Electron app? What are the resolved versions of these packages?
-
@itwin/presentation-backend -
@itwin/presentation-frontend -
@itwin/presentation-components
Yes, this is an Electron app. The versions as follows:
"@itwin/presentation-backend": "^5.0.0",
"@itwin/presentation-common": "^5.0.0",
"@itwin/presentation-components": "^5.12.0",
"@itwin/presentation-frontend": "^5.0.0",