🎛️ Interactive Property Explorer

Experiment with different property combinations to see their effects

Live Tree Preview
Property Controls
Property Presets
Quick Presets:
Select a preset to quickly configure the tree with common property combinations.

🔧 Core Properties

Essential properties that define tree behavior and data structure

Property Details
PropertyTypeDefaultDescription
data*Array<object>[]Array of tree node objects. Each object must have properties specified by idMember, pathMember, and displayValueMember.
idMember*string-Property name that contains unique identifiers for each node. Must be unique across all nodes.
pathMember*string-Property name that contains the hierarchical path (e.g., "1", "1.1", "1.1.1") using LTree format.
displayValueMember*string-Property name that contains the text to display for each node.
expandLevelnumber2Initial expansion depth. Nodes at this level and above will be expanded by default.
shouldToggleOnNodeClickbooleanfalseWhen true, clicking on a node will expand/collapse it instead of just selecting.
* Required properties highlighted in yellow
Usage Examples
Data Structure & Usage
 
Implementation Notes
🏗️ Data Structure Requirements
  • Unique IDs: Each node must have a unique identifier
  • Path Hierarchy: Use dot notation like "1.2.3" for parent-child relationships
  • Flat Array: All nodes in a single array, not nested objects
📊 Path Format Examples
  • "1" - Root level node
  • "1.1" - Child of node "1"
  • "1.1.1" - Grandchild of node "1"
  • "2.5.3" - Third child of fifth child of second root
⚡ Performance Notes

The component efficiently handles large datasets using the LTree structure for fast hierarchy lookups.

🎨 Styling & Display Properties

Properties that control visual appearance and user interface elements

Styling Properties
PropertyTypeDefaultDescription
shouldUseBootstrapIconClassesbooleantrueUse Bootstrap's chevron-right/chevron-down for expand/collapse icons
treeClassstring""CSS class applied to the root tree container
nodeClassstring""CSS class applied to individual tree nodes
selectedNodeClassstring""CSS class applied to selected nodes
expandedNodeClassstring""CSS class applied to expanded parent nodes
dragHighlightClassstring""CSS class applied during drag operations for visual feedback
Styling Examples
Custom Styling
 
CSS Integration
🎯 Bootstrap Integration

Works seamlessly with Bootstrap classes out of the box. Set shouldUseBootstrapIconClasses to false for custom icon solutions.

🖌️ Custom Themes

Use the various class properties to implement custom themes, dark modes, or brand-specific styling.

✨ State Classes

Different classes for selected, expanded, and drag states allow for rich visual feedback and smooth animations.

📱 Responsive Design

All styling properties work with responsive design patterns and CSS frameworks.

🔄 Interaction Properties

Properties that control drag & drop, search, and user interactions

Interaction Properties
PropertyTypeDefaultDescription
isDragAndDropEnabledbooleanfalseEnable drag and drop functionality for reordering nodes
dragValidationCallbackfunctionnullFunction to validate drag operations: (draggedNode, targetNode, position) => boolean
searchTextstring""Search query string that filters and highlights matching nodes
getSearchValueCallbackfunctionnullCustom function to extract searchable text from nodes: (node) => string
sortCallbackfunctionnullCustom sorting function for tree nodes: (items) => sortedItems
shouldSelectOnClickbooleantrueWhether clicking a node should select it
Advanced Usage
Advanced Interactions
 
Interaction Guide
🤏 Drag & Drop Validation

Use dragValidationCallback to implement business rules like preventing files from being dropped into other files or checking permissions.

🔍 Flexible Search

The search system uses FlexSearch for performance. Customize what's searchable with getSearchValueCallback.

📊 Dynamic Sorting

Sort callbacks receive tree nodes with access to original data via node.data. Useful for sorting by dates, types, or custom criteria.

⚡ Performance Tips

Validation and search callbacks are called frequently - keep them lightweight and avoid expensive operations.