소스 검색

修正svgicon图标不居中问题

zhontai 2 년 전
부모
커밋
13ea23c769
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/components/svgIcon/index.vue

+ 1 - 1
src/components/svgIcon/index.vue

@@ -50,7 +50,7 @@ const setIconSvgStyle = computed(() => {
 })
 // 设置图片样式
 const setIconImgOutStyle = computed(() => {
-  return `width: ${props.size}px;height: ${props.size}px;display: inline-block;overflow: hidden;`
+  return `width: ${props.size}px;height: ${props.size}px;line-height: ${props.size}px;display: inline-block;overflow: hidden;`
 })
 // 设置图片样式
 // https://gitee.com/lyt-top/vue-next-admin/issues/I59ND0