Performs an API call that will collapse the node associated to the specified row or row index.
OptionalconfigAn object to configure the scene tree.
Sets the default environment for the viewer. This setting is used for auto-configuring network hosts.
Use the config property for manually setting hosts.
OptionalcontrollerPerforms an API call that will deselect the item associated to the given row or row index.
Performs an API call to expand all nodes in the tree.
Performs an API call that will expand the node associated to the specified row or row index.
Fetches the metadata keys that are available to the scene tree. Metadata keys can be assigned to the scene tree using the metadataKeys property. The scene tree will fetch this metadata and make these values available for data binding.
A promise that resolves with the names of available keys.
Performs an async request that will filter the displayed items in the tree that match the given term and options.
The filter term.
Optionaloptions: FilterTreeOptions
The options to apply to the filter.
A promise that completes when the request has completed. Note, items are displayed asynchronously. So the displayed items may not reflect the result of this filter when the promise completes.
Returns the row data from the given vertical client position.
Returns a row at the given index. If the row data has not been loaded, returns undefined.
Returns the row data from the given mouse or pointer event. The event must originate from a vertex-scene-tree-table-cell contained by this element, otherwise undefined is returned.
Returns the row with the given id. If there is not a row matching the id, returns undefined.
Performs an API call that will hide the item associated to the given row or row index.
Schedules a render of the rows in the scene tree. Useful if any custom data in your scene tree has changed, and you want to update the row's contents.
Note: This is an asynchronous operation. The update may happen on the next frame.
Performs an API call that will show only the item associated to the given row or row index and fit the camera to the item's bounding box.
A list of part metadata keys that will be made available to each row. This metadata can be used for data binding inside the scene tree's template.
Note: for the values of these metadata keys to be evaluated for search, they must be provided to the metadataSearchKeys specified in the searchOptions. Otherwise, the search will only be performed against the item name.
The duration of operations with animations, in milliseconds, when a user performs an action that results in an animation such as isolate. Defaults to 500ms.
The number of offscreen rows above and below the viewport to render. Having a higher number reduces the chance of the browser not displaying a row while scrolling.
OptionalrowA callback that is invoked immediately before a row is about to be rendered. This callback can return additional data that can be bound to in a template.
<script>
const table = document.querySelector('vertex-scene-tree-table');
table.rowData = (row) => {
return { func: () => console.log('row', row.node.name) };
};
</script>
<vertex-scene-tree>
<vertex-scene-tree-table>
<vertex-scene-tree-table-column>
<template> <button event:click="{{row.data.func}}">Hi</button> </template>
</vertex-scene-tree-table-column>
</vertex-scene-tree-table>
</vertex-scene-tree>
Scrolls the tree to the given row index.
An index of the row to scroll to.
Optionaloptions: ScrollToOptions
A set of options to configure the scrolling behavior.
Scrolls the tree to an item with the given ID. If the node for the item is not expanded, the tree will expand each of its parent nodes.
An ID of an item to scroll to.
Optionaloptions: ScrollToOptions
A set of options to configure the scrolling behavior.
A promise that resolves when the operation is finished.
A set of options to configure scene tree searching behavior.
Performs an async request that will select the filtered items in the tree that match the given term.
The filter term.
Optionaloptions: SceneTreeOperationOptionsA promise that completes when the request has completed.
Performs an API call that will select the item associated to the given row or row index.
This method supports a recurseParent option that allows for recursively selecting the next unselected parent node. This behavior is considered stateful. Each call to selectItem will track the ancestry of the passed in rowArg. If calling selectItem with a row not belonging to the ancestry of a previous selection, then this method will perform a standard selection.
The row, row index or node to select.
Optionaloptions: SelectItemOptions
A set of options to configure selection behavior.
Performs an API call that will show the item associated to the given row or row index.
Performs an API call that will either expand or collapse the node associated to the given row or row index.
Performs an API call that will either hide or show the item associated to the given row or row index.
OptionalviewerAn instance of a <vertex-viewer> element. Either this property or viewerSelector must be set.
OptionalviewerA CSS selector that points to a <vertex-viewer> element. Either this property or viewer must be set.
Performs an API call to collapse all nodes in the tree.