@@@@@@
This commit is contained in:
40
library/components/VabAlert/index.vue
Normal file
40
library/components/VabAlert/index.vue
Normal file
@@ -0,0 +1,40 @@
|
||||
<template>
|
||||
<el-alert
|
||||
:center="center"
|
||||
:closable="closable"
|
||||
:close-text="closeText"
|
||||
:description="description"
|
||||
:effect="effect"
|
||||
:show-icon="showIcon"
|
||||
:title="title"
|
||||
:type="type"
|
||||
v-bind="$attrs"
|
||||
>
|
||||
<template v-if="title || $slots.title" #title>
|
||||
<slot name="title">
|
||||
{{ title }}
|
||||
</slot>
|
||||
</template>
|
||||
<template v-if="$slots.default || description" #default>
|
||||
<slot name="default">
|
||||
{{ description }}
|
||||
</slot>
|
||||
</template>
|
||||
</el-alert>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { ElAlert } from 'element-plus'
|
||||
|
||||
defineOptions({
|
||||
name: 'VabAlert',
|
||||
})
|
||||
|
||||
defineProps({
|
||||
...ElAlert.props,
|
||||
closable: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
})
|
||||
</script>
|
||||
Reference in New Issue
Block a user