Table of Contents

Class BOBTreeNodeBase<TRegistration>

Namespace
BlazOrbit.Components
Assembly
BlazOrbit.dll

Registration-only base for tree nodes (BOBTreeMenuItem, BOBTreeSelectorItem). Intentionally inherits Microsoft.AspNetCore.Components.ComponentBase (not BOBComponentBase) because the node registers itself with the enclosing tree container via cascading parameters and the container renders the flattened structure. The node does not emit its own <bob-component> root.

public abstract class BOBTreeNodeBase<TRegistration> : ComponentBase where TRegistration : TreeNodeRegistration

Type Parameters

TRegistration
Inheritance
object
ComponentBase
BOBTreeNodeBase<TRegistration>
Derived

Constructors

BOBTreeNodeBase()

protected BOBTreeNodeBase()

Properties

ChildContent

Child nodes nested inside this node. Each child registers itself recursively against the same tree.

[Parameter]
public RenderFragment? ChildContent { get; set; }

Property Value

RenderFragment

Data

Arbitrary payload associated with the node and surfaced through the registration to consumers.

[Parameter]
public object? Data { get; set; }

Property Value

object

Disabled

When true, the node is rendered in a disabled state and ignores activation.

[Parameter]
public bool Disabled { get; set; }

Property Value

bool

Icon

Material icon name displayed alongside the node text.

[Parameter]
public IconKey? Icon { get; set; }

Property Value

IconKey?

InitiallyExpanded

When true, the node is expanded the first time the tree renders.

[Parameter]
public bool InitiallyExpanded { get; set; }

Property Value

bool

Key

Stable identifier for the node. When omitted, a key is derived from the node's position in the tree.

[Parameter]
public string? Key { get; set; }

Property Value

string

NodeContent

Optional render fragment that replaces the default text/icon layout for this node.

[Parameter]
public RenderFragment? NodeContent { get; set; }

Property Value

RenderFragment

ResolvedKey

protected string ResolvedKey { get; }

Property Value

string

Text

Visible label of the node.

[Parameter]
public string? Text { get; set; }

Property Value

string

Methods

BuildRenderTree(RenderTreeBuilder)

Renders the component to the supplied Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder.

protected override void BuildRenderTree(RenderTreeBuilder builder)

Parameters

builder RenderTreeBuilder

A Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder that will receive the render output.

CreateRegistration()

protected abstract TRegistration CreateRegistration()

Returns

TRegistration

GenerateDefaultKey()

protected abstract string GenerateDefaultKey()

Returns

string

OnInitialized()

Method invoked when the component is ready to start, having received its initial parameters from its parent in the render tree.

protected override void OnInitialized()

OnParametersSet()

Method invoked when the component has received parameters from its parent in the render tree, and the incoming values have been assigned to properties.

protected override void OnParametersSet()