Table of Contents

Class LinkButton

Namespace
The.Web.Controls
Assembly
Instagile.Web.Client.dll

A navigation link wearing the appearance of an ActionButton.

public class LinkButton : ComponentBase, IComponent, IHandleEvent, IHandleAfterRender
Inheritance
LinkButton
Implements
Inherited Members

Remarks

Use this to go somewhere and ActionButton to run something. Disabling drops the href, so a disabled link can be neither followed nor focused.

A primary one is followed by the Enter key, in the same way a primary ActionButton is activated by it: whichever comes first in the nearest enclosing scope wins.

Properties

ChildContent

Text or tags to be displayed inside the button.

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

Property Value

RenderFragment

Href

Navigation target. Without one the anchor is inert, which suits a splatted click handler.

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

Property Value

string

IsEnabled

True by default. If false, the link cannot be followed, activated or focused.

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

Property Value

bool

IsSmall

Alter styling for the shorter row height used in tables.

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

Property Value

bool

Level

Optional colour scheme.

[Parameter]
public MessageLevel? Level { get; set; }

Property Value

MessageLevel?

Splat

Extra attributes for the underlying <a> tag.

[Parameter(CaptureUnmatchedValues = true)]
public Dictionary<string, object>? Splat { get; set; }

Property Value

Dictionary<string, object>

Tier

Visual emphasis tier. Secondary (a neutral bordered button) by default.

[Parameter]
public ButtonTier Tier { get; set; }

Property Value

ButtonTier

Methods

BuildRenderTree(RenderTreeBuilder)

Renders the component to the supplied RenderTreeBuilder.

protected override void BuildRenderTree(RenderTreeBuilder __builder)

Parameters

__builder RenderTreeBuilder