重命名 docs 为 example

This commit is contained in:
就眠儀式
2021-11-23 11:08:40 +08:00
parent 97788e3a77
commit 4a4ee87b65
88 changed files with 14 additions and 7 deletions

View File

@@ -5,7 +5,7 @@ export default {
</script>
<script setup lang="ts">
import { defineProps } from "vue";
import { computed, defineProps } from "vue";
export interface LayIconProps {
prefix?: string;
@@ -17,8 +17,15 @@ export interface LayIconProps {
const props = withDefaults(defineProps<LayIconProps>(), {
prefix: "layui-icon",
});
const styles = computed(() => {
return {
color: props.color,
fontSize: props.size,
};
});
</script>
<template>
<i :class="[prefix, type]" :style="{ color: color, fontSize: size }" />
<i :class="[prefix, type]" :style="styles" />
</template>