Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chrome icon color bug #310

Closed
yutingzhao1991 opened this issue Dec 20, 2023 · 6 comments · Fixed by #346
Closed

Chrome icon color bug #310

yutingzhao1991 opened this issue Dec 20, 2023 · 6 comments · Fixed by #346
Labels
bug Something isn't working development task Development tasks that can be completed within one day help wanted Extra attention is needed

Comments

@yutingzhao1991
Copy link
Collaborator

image
@yutingzhao1991 yutingzhao1991 added bug Something isn't working help wanted Extra attention is needed development task Development tasks that can be completed within one day labels Dec 20, 2023
@gin-lsl
Copy link
Collaborator

gin-lsl commented Dec 20, 2023

看起来像是 svg babel 插件的问题

@yutingzhao1991
Copy link
Collaborator Author

看起来像是 svg babel 插件的问题

最开始是好的,很奇怪,有可能是 svg 不规范,直接打开是好的,但是放到网页中就有问题了。

@gin-lsl
Copy link
Collaborator

gin-lsl commented Dec 21, 2023

我看它这个 svg 在优化的时候,这些 id 会被重写,可能是跟其他的地方重复了(奇怪浏览器竟然不是取最接近的)。

image

优化是通过 inline-react-svg babel 插件做的,然后底层用的是 svgo,2.8.0 版本。

svg/svgo#1784 这个 pr 似乎是在修复这个问题,不过那个 babel 插件用的版本比较老……

不知道能不能通过配置绕过,感觉有点麻烦。

@gin-lsl
Copy link
Collaborator

gin-lsl commented Dec 21, 2023

之前没问题是只有一个这种渐变色,直到最近,又加了一个 polygon 的渐变彩色图标……

@yutingzhao1991
Copy link
Collaborator Author

image

发现这个图标在 ConnectModal 里面的时候又正常了。

@yutingzhao1991
Copy link
Collaborator Author

之前没问题是只有一个这种渐变色,直到最近,又加了一个 polygon 的渐变彩色图标……

哦哦。明白了,所以是和 polygon 同时出现的时候会有这个问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working development task Development tasks that can be completed within one day help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants