Icon 图标
字体图标基于阿里巴巴矢量图标库,使用font-class 引用的方式,建议从项目生成代码文件下载到本地使用。
基本使用
ts
// 全局引入从iconfont.cn下载的CSS
import '/static/xxx/iconfont.css';
html
<be-icon name="plus-circle"></be-icon>
INFO
本质上就是文本,能够设置文本相关样式。
API
Props
属性名 | 说明 | 类型 | 默认值 |
---|---|---|---|
fontFamily | 阿里巴巴图标库项目配置的 FontFamily | string | iconfont |
prefix | 阿里巴巴图标库项目配置的 FontClass 前缀 | string | icon- |
name | 阿里巴巴图标库项目配置的 FontClass 名 | string | - |