Icon¶
The h-icon
webcomponent is used to render icons on a page. In order to use the h-icon
you must declare the source of the icon set of your choice in the script tag:
Note: h-
stands for headless
. This is naming convention used for every webcomponent as they must have a two-part name.
Attributes¶
Attribute name | Type | Default | Description |
---|---|---|---|
icon-name |
string | A name of the icon to render | |
size |
TIconSize |
An icon size modifier | |
filled |
boolean | false | decides whether a rendered icon should filled |
clickable |
boolean | false | decides whether a rendered icon should be clickable |
noStroke |
boolean | false | decides whether a rendered icon should have stroke property |
Basic Icon¶
Examples¶
Filled heart icon with the xl
size:
Clickable search icon without stroke:
Filled clickable check icon without stroke and xxl
size:
If you have read the icon styles documentation you probably noticed that those are the same classes that are used to style the icon components.