eo-icon
<eo-icon>
Alias:
<icons.general-icon>
Your favorite icons, including Ant Design Icons, Font Awesome, and EasyOps Icons.
Examples
Ant Design
Font Awesome
View all Font Awesome free icons.
Lucide
EasyOps
Image
Colors
Spinning
Fallback
Lucide stroke width
Lucide icons support setting strokeWidth
which defaults to 2
(and restrict to range [0.5, 3]
).
Properties
Name | Description | Type | Default | Required |
---|---|---|---|---|
lib | 图标库 | "antd" | "easyops" | "fa" | "lucide" | ||
theme | Ant Design 图标主题 | string | "outlined" | |
icon | 图标名 | string | ||
category | EasyOps 图标分类 | string | "default" | |
prefix | FontAwesome 图标前缀 | string | "fas" | |
strokeWidth | Lucide 图标描线粗线,限制在区间 | number | 2 | |
fallback | 设置当图标未找到时的回退图标 | GeneralIconProps | ||
startColor | 渐变色起始颜色(不适用于 EasyOps 图标) | string | ||
endColor | 渐变色终止颜色(不适用于 EasyOps 图标) | string | ||
gradientDirection | 渐变色方向(不适用于 EasyOps 图标) | GradientDirection | ||
spinning | 是否自动旋转 | boolean | ||
imgSrc | 图片地址 | string | ||
imgStyle | 图片样式 | CSSProperties | ||
imgLoading | 加载方式 | "lazy" | "eager" | ||
noPublicRoot | boolean | |||
keepSvgOriginalColor | 如果是 svg 图片,默认将转换该图标颜色为自动跟随文本色,设置 | boolean |
Type references
GeneralIconPropsOfAntd
extends AntdIconProps, GeneralIconBaseProps
Name | Description | Type | Default | Required |
---|---|---|---|---|
lib | "antd" | ✅ |
GeneralIconBaseProps
Name | Description | Type | Default | Required |
---|---|---|---|---|
spinning | boolean | |||
fallback | GeneralIconProps |
GeneralIconPropsOfEasyOps
extends EasyOpsIconProps, GeneralIconBaseProps
Name | Description | Type | Default | Required |
---|---|---|---|---|
lib | "easyops" | ✅ |
GeneralIconPropsOfFa
extends FaIconProps, GeneralIconBaseProps
Name | Description | Type | Default | Required |
---|---|---|---|---|
lib | "fa" | ✅ |
GeneralIconPropsOfLucide
extends LucideIconProps, GeneralIconBaseProps
Name | Description | Type | Default | Required |
---|---|---|---|---|
lib | "lucide" | ✅ |
ImgIconProps
extends EoImgIconProps, GeneralIconBaseProps
Name | Description | Type | Default | Required |
---|---|---|---|---|
keepSvgOriginalColor | boolean |
GeneralIconProps
LibIconProps | ImgIconProps
LibIconProps
GeneralIconPropsOfAntd | GeneralIconPropsOfEasyOps | GeneralIconPropsOfFa | GeneralIconPropsOfLucide
GradientDirection
"left-to-right" | "top-to-bottom"