Example of Expand And Collapse in Blazor Diagram Component

Diagram / Interactive Features / Expand and Collapse

This example demonstrates how to toggle the visibility of child nodes in a diagram by clicking the icon of the associated parent node.

The Diagram component supports managing the state of nodes, such as whether they are expanded or collapsed. The IsExpanded property controls the expansion or collapse of child nodes. This feature helps condense the hierarchical view by displaying only root elements. The ExpandIcon and CollapseIcon properties visually indicate a node’s expanded or collapsed state.

Transform your Blazor web apps today with Syncfusion® Blazor components
100+ high-performance and responsive UI components
Dedicated support
Hassle-free licensing
TRY IT FOR FREE