如何在 bootstrap 3 中使用 bootstrap-theme.css? [英] How to use bootstrap-theme.css with bootstrap 3?

查看:50
本文介绍了如何在 bootstrap 3 中使用 bootstrap-theme.css?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

http://getbootstrap.com 下载完整的 bootstrap 3 包后,我注意到有一个单独的主题的 css 文件.如何利用它?请解释一下?

After downloading a complete pack of bootstrap 3 from http://getbootstrap.com, I noticed that there is a separate css file for theme. How to make use of it? Please explain?

我在现有的引导程序项目中包含了 bootstrap-theme.css,但输出没有区别.

I included bootstrap-theme.css in my existing bootstrap project, but there is no difference in output.

推荐答案

下载 Bootstrap 3.x 后,您将获得 bootstrap.cssbootstrap-theme.css>(更不用说这些文件的缩小版本了).

Upon downloading Bootstrap 3.x, you'll get bootstrap.css and bootstrap-theme.css (not to mention the minified versions of these files that are also present).

bootstrap.css 完全样式化并且可以使用,如果您愿意的话.它可能有点简单,但它已经准备好了,它就在那里.

bootstrap.css is completely styled and ready to use, if such is your desire. It is perhaps a bit plain but it is ready and it is there.

如果你不想,你不需要使用 bootstrap-theme.css,一切都会好起来的.

You do not need to use bootstrap-theme.css if you don't want to and things will be just fine.

bootstrap-theme.css

bootstrap-theme.css 正是文件名称试图暗示的内容:它是引导程序的主题,被创造性地认为是引导程序主题".该文件的名称使事情有点混乱,因为基础 bootstrap.css 已经应用了样式,而我认为这些样式是默认样式.但是,鉴于 Bootstrap 文档示例部分中关于此 bootstrap-theme.css 文件的内容,该结论显然是不正确的:

bootstrap-theme.css

bootstrap-theme.css is just what the name of the file is trying to suggest: it is a theme for bootstrap that is creatively considered 'THE bootstrap theme'. The name of the file confuses things just a bit since the base bootstrap.css already has styling applied and I, for one, would consider those styles to be the default. But that conclusion is apparently incorrect in light of things said in the Bootstrap documentation's examples section in regard to this bootstrap-theme.css file:

加载可选的 Bootstrap 主题以获得增强的视觉体验."

"Load the optional Bootstrap theme for a visually enhanced experience."

上面的引用可以在这里找到http://getbootstrap.com/getting-started/#examples 在链接到此示例页面的缩略图上http://getbootstrap.com/examples/theme/.这个想法是 bootstrap-theme.cssTHE 引导主题并且它是可选的.

The above quote is found here http://getbootstrap.com/getting-started/#examples on a thumbnail that links to this example page http://getbootstrap.com/examples/theme/. The idea is that bootstrap-theme.css is THE bootstrap theme AND it's optional.

关于 BootSwatch.com 的主题:这些主题不像 bootstrap-theme.css 那样实现.BootSwatch 主题是原始 bootstrap.css 的修改版本.所以,你绝对不应该同时使用 BootSwatch 和 bootstrap-theme.css 文件中的主题.

About the themes at BootSwatch.com: These themes are not implemented like bootstrap-theme.css. The BootSwatch themes are modified versions of the original bootstrap.css. So, you should definitely NOT use a theme from BootSwatch AND the bootstrap-theme.css file at the same time.

关于您自己的自定义主题:您可以在创建自己的主题时选择修改 bootstrap-theme.css.这样做可以更轻松地更改样式,而不会意外破坏任何内置的 Bootstrap 优点.

About Your Own Custom Theme: You might choose to modify bootstrap-theme.css when creating your own theme. Doing so may make it easier to make styling changes without accidentally breaking any of that built-in Bootstrap goodness.

这篇关于如何在 bootstrap 3 中使用 bootstrap-theme.css?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆