HtmlForgeX

API Reference

Class

TablerIconFont

Namespace HtmlForgeX
Assembly HtmlForgeX
Base Element

Tabler icon component using webfont (class: ti ti-{icon-name}) Provides an alternative to SVG-based icons for better performance with many icons

Inheritance

Constructors

TablerIconFont 2 overloads
public TablerIconFont(TablerIconType icon) #

Creates a new Tabler font icon component

Parameters

iconName System.String requiredposition: 0
TablerIconFont(HtmlForgeX.TablerIconType icon) #

Creates a new Tabler font icon component from enum

Parameters

icon HtmlForgeX.TablerIconType required

Methods

public static String GetIconName(TablerIconType icon) #
Returns: String

Gets the icon name from the enum

Parameters

icon HtmlForgeX.TablerIconType requiredposition: 0
RegisterLibraries() #

Registers the required Tabler Icons font library with the current document.

public override String ToString() #
Returns: String

Generates the HTML markup for the Tabler font icon

public TablerIconFont WithClass(String className) #
Returns: TablerIconFont

Adds custom CSS class to the icon

Parameters

className System.String requiredposition: 0
WithColor 2 overloads
public TablerIconFont WithColor(RGBColor color) #
Returns: TablerIconFont

Sets the icon color

Parameters

color HtmlForgeX.RGBColor requiredposition: 0
public TablerIconFont WithColor(String color) #
Returns: TablerIconFont

Sets the icon color using hex string

Parameters

color System.String requiredposition: 0
public TablerIconFont WithSize(String size) #
Returns: TablerIconFont

Sets the icon size

Parameters

size System.String requiredposition: 0
public TablerIconFont WithStyle(String property, String value) #
Returns: TablerIconFont

Adds custom CSS style

Parameters

property System.String requiredposition: 0
value System.String requiredposition: 1