Table of Contents

Class BOBChip

Namespace
BlazOrbit.Components
Assembly
BlazOrbit.dll
[GenerateComponentInfo]
public class BOBChip : BOBComponentBase, IHasSize, IHasColor, IHasDisabled, IHasActive
Inheritance
object
ComponentBase
BOBChip
Implements
Inherited Members

Constructors

BOBChip()

public BOBChip()

Properties

Active

When true, forces the active state (independent of selection).

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

Property Value

bool

ChildContent

Custom content (overrides Label).

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

Property Value

RenderFragment

Clickable

When true, render the chip as a button without selection semantics (action chip pattern).

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

Property Value

bool

Color

Foreground / accent color. Accepts any valid CSS color value, PaletteColor or BOBColor.

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

Property Value

string

Count

Optional badge count rendered after the label.

[Parameter]
public int? Count { get; set; }

Property Value

int?

Disabled

When true, the chip is dimmed and non-interactive.

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

Property Value

bool

IsActive

Computed active state, combining Active with internal conditions.

public bool IsActive { get; }

Property Value

bool

IsDisabled

Computed disabled state, combining Disabled with internal conditions such as loading.

public bool IsDisabled { get; }

Property Value

bool

Label

Text rendered inside the chip. Ignored when ChildContent is set.

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

Property Value

string

LeadingIcon

Optional leading icon rendered before the label.

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

Property Value

IconKey?

OnClick

Raised when a clickable chip is clicked.

[Parameter]
public EventCallback OnClick { get; set; }

Property Value

EventCallback

OnRemoved

Raised when the X button is clicked.

[Parameter]
public EventCallback OnRemoved { get; set; }

Property Value

EventCallback

Removable

When true, render an X button that fires OnRemoved.

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

Property Value

bool

RemoveText

Aria-label for the remove button.

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

Property Value

string

Selectable

When true, the chip behaves like a toggle (filter chip pattern).

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

Property Value

bool

Selected

Selection state (only meaningful when Selectable is set and the chip is NOT inside a BOBChipGroup<TValue>).

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

Property Value

bool

SelectedChanged

Two-way binding companion for Selected.

[Parameter]
public EventCallback<bool> SelectedChanged { get; set; }

Property Value

EventCallback<bool>

Size

Visual size of the chip.

[Parameter]
public BOBSize Size { get; set; }

Property Value

BOBSize

Value

Identity for the chip when nested inside a BOBChipGroup<TValue>. The group matches against this value to track selection. Ignored for standalone chips.

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

Property Value

object

Methods

BuildRenderTree(RenderTreeBuilder)

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

protected override void BuildRenderTree(RenderTreeBuilder __builder)

Parameters

__builder RenderTreeBuilder