We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Syncfusion Feedback

Trusted by the world’s leading companies

Syncfusion Trusted Companies

Overview

The Dropdown Tree component allows users to select a single value or multiple values in an input box from hierarchical data in a tree-like structure. It has several out-of-the-box features, such as data binding, checkboxes, templates, UI customization, accessibility, and preselected values.

Blazor Dropdown Tree.


Blazor Dropdown Tree with data binding.

Data binding

Bind data to the Dropdown Tree component from different data sources, either self-referential data that contains a list of objects with ParentID mapping or heirarchical data that contains a nested list of objects. Data can be local or in any remote service and fetched using different kinds of adapters like OData, OData V4, URL, and web API.


Render modes

The Dropdown Tree component has different render modes to visualize selected items.

Box mode

The selected items are displayed as a chip (box) in the Dropdown Tree input box.

Blazor Dropdown Tree with chip mode.

Delimiter mode

The selected items are displayed with the delimiter character in the Dropdown Tree input box.

Blazor Dropdown Tree with delimiter mode.

Default mode

The default mode is a combination of both the box and delimiter modes. When the component is in focus, selected items will be displayed as chips similar to the box mode. Otherwise, they will be displayed with a delimiter character as in the delimiter mode.

Blazor Dropdown Tree with default rendering mode.


Blazor Dropdown Tree with checkboxes.

Checkboxes

The Blazor Dropdown Tree component provides built-in support for checkboxes, allowing users to select more than one item. Enabling the checkboxes and autocheck functionality makes the parent and child items dependent on each other.


Multiple selection

The Dropdown Tree component allows users to select more than one item in the pop-up using the multiselection functionality. Ctrl and Shift key combinations can be used for node selection.

Blazor Dropdown Tree with multiple selection.


UI customization with templates

Use templates to change the appearance of the selection pop-up for tree items,the header and footer of the pop-up tree.

Header template

Design your own header for the pop-up tree using the header template.

Blazor Dropdown Tree with header template.

Item template

Define the custom appearance of each tree item using the item template.

Blazor Dropdown Tree with item template.

Design your own custom footer for the pop-up tree using the footer template.

Blazor Dropdown Tree with footer template.


Filtering

The Blazor Dropdown Tree component supports in-built filtering through which users can filter the required items based on the characters searched in the search box.

Blazor Dropdown Tree with filtering.


Built-in and customizable themes

The Blazor Dropdown Tree component supports built-in themes: Material, Material 3, Bootstrap, Fabric (Office 365), Tailwind CSS, Fluent, and high contrast. Users can customize these built-in themes or create new themes to achieve their desired look and feel by either overriding Sass variables or using our Theme Studio application.


Web accessibility

  • Fully supports WAI-ARIA accessibility to make the Dropdown Tree accessible to screen readers and assistive devices.
  • Follows WAI-ARIA best practices for implementing keyboard interaction.
  • Uses WCAG 2.0-based design for UI visual elements such as foreground color, background color, line spacing, text, and images.
  • Supports right-to-left (RTL) direction for users working with RTL languages like Hebrew and Arabic.

Developer-friendly APIs

Developers can customize all UI elements and component their behaviors according to the end user’s requirements using the component’s rich set of client-side APIs.


Easily get started with the Blazor Dropdown Tree using a few simple lines of C# code, as demonstrated below. Also explore our Blazor Dropdown Tree example, which shows how to render and configure the Blazor Dropdown Tree.

@using Syncfusion.Blazor.Navigations
<SfDropDownTree TItem="ProductCategory" TValue="int?" ID="list" Placeholder="Select a Category" PopupHeight="200px">
    <DropDownTreeField TItem="ProductCategory" DataSource="@Categories" ID="Id" ParentID="ParentId" Text="Name" HasChildren="HasChild" Expanded="Expanded"></DropDownTreeField>
</SfDropDownTree>
@code{
    List<ProductCategory> Categories = new List<ProductCategory>
    {
        new ProductCategory { Id = 1, Name = "Electronics", HasChild=true, Expanded = true },
        new ProductCategory { Id = 2, Name = "Smartphones", ParentId = 1 },
        new ProductCategory { Id = 3, Name = "Laptops", ParentId = 1 },
        new ProductCategory { Id = 6, Name = "Clothing", HasChild=true  },
        new ProductCategory { Id = 7, Name = "Men's Clothing", ParentId = 6 },
        new ProductCategory { Id = 8, Name = "Women's Clothing", ParentId = 6 },
        new ProductCategory { Id = 11, Name = "Home & Furniture", HasChild=true },
        new ProductCategory { Id = 12, Name = "Living Room", ParentId = 11 },
        new ProductCategory { Id = 13, Name = "Bedroom", ParentId = 11 },
        new ProductCategory { Id = 16, Name = "Sports & Fitness", HasChild=true, Expanded=true },
        new ProductCategory { Id = 17, Name = "Exercise Equipment", ParentId = 16 },
        new ProductCategory { Id = 19, Name = "Team Sports", ParentId = 16 },
        new ProductCategory { Id = 20, Name = "Books & Media", HasChild=true },
        new ProductCategory { Id = 21, Name = "Books", ParentId = 20 },
        new ProductCategory { Id = 24, Name = "Toys & Games", HasChild = true },
        new ProductCategory { Id = 25, Name = "Board Games", ParentId = 24 },
        new ProductCategory { Id = 26, Name = "Outdoor Games", ParentId = 24 }
    };
    class ProductCategory
    {
        public int? Id { get; set; }
        public string Name { get; set; }
        public int? ParentId { get; set; }
        public bool HasChild { get; set; }
        public bool Expanded { get; set; }
    }
}

Struggling to decide on the right product?

Our comprehensive competitor comparison of Blazor components will guide you to the perfect choice.

tick-mark 85+ UI components
tick-mark 960+ interactive Blazor demos
tick-mark 2M+ downloads
competitive-banner-FT-image

Blazor Components – 85+ UI and DataViz Components

Our Customers Love Us

Having an excellent set of tools and a great support team, Syncfusion reduces customers’ development time.
Here are some of their experiences.

Rated by users across the globe

Transform your applications today by downloading our free evaluation version
Download Free Trial No credit card required.

Awards

Greatness—it’s one thing to say you have it, but it means more when others recognize it. Syncfusion is proud to hold the following industry awards.

Up arrow icon