Skip to content

skyline 引擎下的icon问题 #299

Answered by sonofmagic
bostin asked this question in Q&A
Discussion options

You must be logged in to vote

我发现使用 @egoist/tailwindcss-icons mask-image内联icon数据,其实是可以在 skyline 下面生效的,但是你必须使用:

<view class="i-mdi-home bg-yellow-600 w-4 h-4"></view>

这种方式来显示那个 icon

也就是说,需要为 @egoist/tailwindcss-icons 默认的 css 里面,补充 background-color 和默认的宽和高,才能显示成功 (宽和高默认为 1em,覆盖它)
这点可以使用 @egoist/tailwindcss-icons 的 iconsPlugin 的 extraProperties 属性,来覆盖和覆盖生成 css 的默认值

你可以试试。

Replies: 4 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by bostin
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants