feat(icon): 新增 color 与 size 属性
This commit is contained in:
parent
edde6ed813
commit
2ae491f64c
@ -18,6 +18,32 @@ export default {
|
||||
|
||||
:::
|
||||
|
||||
::: demo
|
||||
|
||||
<template>
|
||||
<lay-icon type="layui-icon-face-smile" color="red"></lay-icon>
|
||||
<lay-icon type="layui-icon-face-smile" color="orange"></lay-icon>
|
||||
<lay-icon type="layui-icon-face-smile" color="green"></lay-icon>
|
||||
<lay-icon type="layui-icon-face-smile" color="cyan"></lay-icon>
|
||||
<lay-icon type="layui-icon-face-smile" color="blue"></lay-icon>
|
||||
<lay-icon type="layui-icon-face-smile" color="black"></lay-icon>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { ref } from 'vue'
|
||||
|
||||
export default {
|
||||
setup() {
|
||||
|
||||
return {
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
:::
|
||||
|
||||
|
||||
::: demo
|
||||
|
||||
<template>
|
||||
@ -1051,3 +1077,5 @@ export default {
|
||||
| ---- | ---- | ----------------- |
|
||||
| type | 图标 | `layui-icon-home` |
|
||||
| prefix | 前缀 | `layui-icon` |
|
||||
| color | 颜色 | -- |
|
||||
| size | 尺寸 | -- |
|
@ -3,10 +3,9 @@
|
||||
<template>
|
||||
<lay-timeline>
|
||||
<lay-timeline-item title="0.1.1">
|
||||
[新增] tree 树,支持 node-click,selectKeys 等<br>
|
||||
[新增] table 表格,提供 columns datasource page 分页<br>
|
||||
[新增] menu 菜单 title 插槽,允许自定义菜单项<br>
|
||||
[调整] menu 菜单 child-item 行高 40 -> 46, 减少突兀感
|
||||
[新增] menu 菜单 title 插槽,允许自定义菜单项。<br>
|
||||
[新增] table 表格 toolbar 插槽, 用于自定义工具栏。<br>
|
||||
[调整] menu 菜单 child-item 行高, 由 40 调整为 46。<br>
|
||||
</lay-timeline-item>
|
||||
<lay-timeline-item title="0.1.0">
|
||||
[新增] tree 树,支持 node-click,selectKeys 等<br>
|
||||
|
@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<i :class="[prefix, type]" />
|
||||
<i :class="[prefix, type]" :style="{ color: color , fontSize: size}"/>
|
||||
</template>
|
||||
|
||||
<script setup name="LayIcon" lang="ts">
|
||||
@ -9,6 +9,8 @@ const props = withDefaults(
|
||||
defineProps<{
|
||||
type?: string
|
||||
prefix?: string
|
||||
color?: string
|
||||
size?: string
|
||||
}>(),
|
||||
{
|
||||
prefix: 'layui-icon',
|
||||
|
Loading…
Reference in New Issue
Block a user