描述后的提示封装成组件

v1.3.0
于肖磊 2025-03-10 11:29:47 +08:00
parent e4f29ce4d7
commit 6cf1d9c7fb
1 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,19 @@
<template>
<el-tooltip effect="dark" :show-after="200" :hide-after="200" :content="props.content" :raw-content="props.rawContent" placement="top">
<icon name="miaosha-hdgz" size="12" color="#999"></icon>
</el-tooltip>
</template>
<script lang="ts" setup>
interface TooltipProps {
content: string;
rawContent?: boolean;
placement?: 'top' | 'bottom' | 'left' | 'right';
}
const props = withDefaults(defineProps<TooltipProps>(), {
rawContent: true,
placement: 'top',
});
</script>