title | description | api_reference | slug |
---|---|---|---|
TreeView API |
API Index | TreeView |
true |
api_treeviewcomponent_wrapper |
kendo-treeview
- [
kendo-treeview-item
]({% slug api_treeviewitemcomponent_wrapper %})
A collection of visual animations that are displayed when TreeView items are expanded or collapsed through user interaction (animation
in Kendo UI for jQuery). Setting animation
to false
disables all animations. The supported composite props are available in [AnimationProps
]({% slug api_treeview_animationprops_wrapper %}).
If auto-bind
is set to false
, the TreeView will not bind to the data source during initialization (autoBind
in Kendo UI for jQuery). In such scenarios data binding will occur when the change
event of the dataSource
instance is fired. By default, auto-bind
is set to true
and the TreeView will bind to the data source that is specified in the configuration.
If auto-scroll
is set to true
, the TreeView will automatically scroll the containing element when the mouse or user finger is close to its top or bottom (autoScroll
in Kendo UI for jQuery).
If checkboxes
is set to true
or to an object, the TreeView renders checkboxes next to each node (checkboxes
in Kendo UI for jQuery). The supported composite props are available in [CheckboxesProps
]({% slug api_treeview_checkboxesprops_wrapper %}).
The field of the data item that provides the image URL of the TreeView nodes (dataImageUrlField
in Kendo UI for jQuery).
The data source of the TreeView for rendering the nodes (dataSource
in Kendo UI for jQuery).
You can set data-source
to:
- A JavaScript object which represents any valid data source configuration.
- A JavaScript array.
- An existing
kendo.data.HierarchicalDataSource
instance.
If the dataSource
option is set to a JavaScript object or an array, the TreeView will initialize a new kendo.data.HierarchicalDataSource
instance by using that value as a data source configuration. If the dataSource
option is an existing kendo.data.HierarchicalDataSource
instance, the TreeView will use that instance and will not initialize a new one.
The field of the data item that provides the sprite CSS class of the nodes (dataSpriteCssClassField
in Kendo UI for jQuery). If data-sprite-css-class-field
is set to an array, each level uses either the field which is at the same index in the array or the last item in the array.
The field of the data item that provides the textual content of the nodes (dataTextField
in Kendo UI for jQuery). If data-text-field
is set to an array, each level either uses the field which is at the same index in the array or the last item in the array.
The field of the data item that provides the URL of the node links (dataUrlField
in Kendo UI for jQuery).
If drag-and-drop
is set to false
, the dragging and dropping of the nodes is disabled (dragAndDrop
in Kendo UI for jQuery).
Indicates whether the child DataSources will be fetched lazily when the parent groups are expanded (loadOnDemand
in Kendo UI for jQuery). Setting load-on-demand
to false
loads all child DataSources at the time of initialization.
The text messages that are displayed in the TreeView (messages
in Kendo UI for jQuery). Used for customization or localization of messages. The supported composite props are available in [MessagesProps
]({% slug api_treeview_messagesprops_wrapper %}).
The template for rendering each node (template
in Kendo UI for jQuery).
Fires when the selection was changed either by the user or through the select
method (change
in Kendo UI for jQuery).
(Available in internal builds as of 2014.2.828) Fires after the user checked or unchecked a checkbox (check
in Kendo UI for jQuery). If checkChildren
is set to true
, the check
event is triggered after all checked states are updated.
Fires before a subgroup gets collapsed (collapse
in Kendo UI for jQuery). Can be cancelled.
Fires after the change
event of the data source was processed by adding or removing items (dataBound
in Kendo UI for jQuery).
Fires while a node is being dragged (drag
in Kendo UI for jQuery).
Fires after a node was dropped (dragEnd
in Kendo UI for jQuery).
Fires before the dragging of a node starts (dragStart
in Kendo UI for jQuery)
Fires while a node is being dropped (drop
in Kendo UI for jQuery).
Fires before a subgroup is expanded (expand
in Kendo UI for jQuery).
Fires when the user moves the focus to another node (navigate
in Kendo UI for jQuery).
Fires when a node is being selected by the user (select
in Kendo UI for jQuery). Can be cancelled.
For more details about the methods available in the component's API please check its Kendo UI for jQuery API documentation.
Returns the Kendo UI TreeView instance.