layui/.svn/pristine/60/60beacf7a82c03ba4e5aa64ede0a39988f8c570a.svn-base
2022-12-09 16:41:41 +08:00

30 lines
550 B
Plaintext

<script lang="ts">
export default {
name: "LaySkeletonItem",
};
</script>
<script setup lang="ts">
import { withDefaults } from "vue";
import { LayIcon } from "@layui/icons-vue";
export interface SkeletonProps {
type?: string;
}
const props = withDefaults(defineProps<SkeletonProps>(), {
type: "p",
});
</script>
<template>
<div
:class="['lay-skeleton-item', `lay-skeleton-type--${type}`]"
v-bind="$attrs"
>
<div v-if="type === 'image'">
<lay-icon type="layui-icon-picture"></lay-icon>
</div>
</div>
</template>