Skip to main content

TreeView

interface
interface TreeView<TElement extends object = object, TContextValue extends string = string>

Import

import { TreeView } from '@modular/sdk';

Members13

densityoptional
TreeDensity

Controls the vertical density of host-rendered tree rows. The host owns the concrete metrics so trees remain accessible and virtualized correctly.

iconoptional
string

The view's nav icon — shown on its activity-bar / panel entry. A design system icon name (the icon's export name), e.g. `'IconSparkle2Outline24'`, `'IconStarOutline24'`, or a codicon like `'CodiconAccount'`. Rendered monochrome, tinted to the active foreground — distinct from the mod's full-color `metadata.icon`. Omit and the view falls back to a placeholder.

id
string
inlineActionsoptional
readonly TreeInlineAction<TElement, TContextValue>[]
kind
'tree'
presentation
DeskPresentation
provider
TreeDataProvider<TElement, TContextValue>
rowHeightoptional
number

Exact row height in pixels. The host constrains this to its safe range.

title
string
whenoptional
Condition
windowoptional
ViewWindowOptions
onDidChangeTreeData()
(listener: (change: TreeDataChange<TElement>) => void) => Disposable
onSelect()optional
(element: TElement, ctx: TreeContext<TElement>) => void | Promise<void>