From 1a5ed27067eea66711b0e80a93fc02721de50ecd Mon Sep 17 00:00:00 2001 From: 疯狂的狮子Li <15040126243@163.com> Date: 星期日, 16 四月 2023 15:39:34 +0800 Subject: [PATCH] fix 修复 prod 配置文件监控中心路径不正确问题 --- src/components/SvgIcon/index.vue | 34 ++++++++++++++-------------------- 1 files changed, 14 insertions(+), 20 deletions(-) diff --git a/src/components/SvgIcon/index.vue b/src/components/SvgIcon/index.vue index 8c101f6..f3562d7 100644 --- a/src/components/SvgIcon/index.vue +++ b/src/components/SvgIcon/index.vue @@ -4,33 +4,27 @@ </svg> </template> -<script> -export default defineComponent({ - props: { +<script setup lang="ts"> +const props = defineProps({ iconClass: { - type: String, - required: true + type: String, + required: true }, className: { - type: String, - default: '' + type: String, + default: '' }, color: { - type: String, - default: '' + type: String, + default: '' }, - }, - setup(props) { - return { - iconName: computed(() => `#icon-${props.iconClass}`), - svgClass: computed(() => { - if (props.className) { - return `svg-icon ${props.className}` - } - return 'svg-icon' - }) +}) +const iconName = computed(() => `#icon-${props.iconClass}`); +const svgClass = computed(() => { + if (props.className) { + return `svg-icon ${props.className}` } - } + return 'svg-icon' }) </script> -- Gitblit v1.9.3