HtmlForgeX

API Reference

Class

TablerStatCard

Namespace HtmlForgeX
Assembly HtmlForgeX
Base Element

Tabler stat card component for displaying metrics with icon and change indicator

Inheritance

Constructors

public TablerStatCard() #

Initializes a new instance of the TablerStatCard class

Methods

public TablerStatCard Change(String change, Nullable<TablerChangeType> type = null) #
Returns: TablerStatCard

Set change percentage

Parameters

change System.String requiredposition: 0
type System.Nullable{HtmlForgeX.TablerChangeType} = null optionalposition: 1
public TablerStatCard ChangeType(TablerChangeType type) #
Returns: TablerStatCard

Set change type explicitly

Parameters

type HtmlForgeX.TablerChangeType requiredposition: 0
public TablerStatCard Color(TablerColor color) #
Returns: TablerStatCard

Set card color theme

Parameters

color HtmlForgeX.TablerColor requiredposition: 0
GetColorClass(HtmlForgeX.TablerColor color) #

Gets the CSS color class for a TablerColor

Parameters

color HtmlForgeX.TablerColor required
The color enum value

Returns

CSS color class string

public TablerStatCard Loading(Boolean loading = true) #
Returns: TablerStatCard

Show loading state

Parameters

loading System.Boolean = true optionalposition: 0
RegisterLibraries() #

Registers the required libraries for this component

public TablerStatCard Title(String title) #
Returns: TablerStatCard

Set card title

Parameters

title System.String requiredposition: 0
public override String ToString() #
Returns: String

Renders the stat card to HTML string

Returns

HTML representation of the stat card

public TablerStatCard Value(String value) #
Returns: TablerStatCard

Set card value

Parameters

value System.String requiredposition: 0