Explorar o código

更新svgicon

zhontai %!s(int64=2) %!d(string=hai) anos
pai
achega
2b656e8650
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/components/svgIcon/index.vue

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

@@ -57,7 +57,7 @@ const setIconImgOutStyle = computed(() => {
 const setIconSvgInsStyle = computed(() => {
   const filterStyle: string[] = []
   const compatibles: string[] = ['-webkit', '-ms', '-o', '-moz']
-  const color = props.color ? props.color : 'currentColor'
+  const color = props.color === '' || props.color ? props.color : 'currentColor'
   compatibles.forEach((j) => filterStyle.push(`${j}-filter: drop-shadow(${color} ${props.size}px 0);`))
   return `width: ${props.size}px;height: ${props.size}px;` + (color ? `position: relative;left: -${props.size}px;${filterStyle.join('')}` : '')
 })