mirror of
https://github.com/m-xlsea/ruoyi-plus-soybean.git
synced 2025-09-24 07:49:47 +08:00
refactor(projects): 添加exportDefaults替换defineProps
This commit is contained in:
@ -1,22 +1,23 @@
|
||||
<template>
|
||||
<div>
|
||||
<svg-fill-logo v-if="fill" :color="color" />
|
||||
<svg-logo v-else :color="color" />
|
||||
<div :style="{ color }">
|
||||
<svg-fill-logo v-if="fill" />
|
||||
<svg-logo v-else />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { SvgLogo, SvgFillLogo } from './components';
|
||||
|
||||
defineProps({
|
||||
fill: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
color: {
|
||||
type: String,
|
||||
default: '#409EFF'
|
||||
}
|
||||
interface Props {
|
||||
/** logo是否填充 */
|
||||
fill?: boolean;
|
||||
/** logo的主题颜色 */
|
||||
color?: string;
|
||||
}
|
||||
|
||||
withDefaults(defineProps<Props>(), {
|
||||
fill: false,
|
||||
color: '#409EFF'
|
||||
});
|
||||
</script>
|
||||
<style scoped></style>
|
||||
|
Reference in New Issue
Block a user