如何设计 Meteor.js loginButtons 的样式? [英] How to style Meteor.js loginButtons?
问题描述
文档指定使用模板 {{>loginButtons}}
来实现默认的登录按钮.
The docs specify to use the template {{> loginButtons}}
to implement the default login buttons.
将我自己的样式应用于此的最佳方法是什么?
What is the best way to apply my own styles to this?
- 重写一个新模板(如何实现?)
- 向标记为
!important
的 CSS 文件添加样式 - 其他?
推荐答案
事实证明可以结合使用这两种想法.在深入研究 accounts-ui 包后,发现它只包含一个 .less
文件.实际模板包含在 accounts-ui-unstyled,在将 accounts-ui
添加到 meteor
项目时会自动包含.
It turns out a combination of the two ideas can be used. After delving into the accounts-ui package, it turns out that it contains only one .less
file. The actual template is included in accounts-ui-unstyled, which is automatically included when accounts-ui
is added to a meteor
project.
因此,可以按如下方式删除 CSS:
Hence, the CSS can be removed as follows:
meteor remove accounts-ui
meteor add accounts-ui-unstyled
然后你就剩下原始 HTML,可以根据您的选择设置样式.
You are then left with the raw HTML, which can be styled as you choose.
这篇关于如何设计 Meteor.js loginButtons 的样式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!