Bootstrap 3 仅在移动视图上应用 CSS [英] Bootstrap 3 Apply CSS on Mobile View Only

查看:18
本文介绍了Bootstrap 3 仅在移动视图上应用 CSS的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Bootstrap 3,在移动视图中我想应用一些 CSS 来修复移动视图上的一些错误.我查看了文档并谷歌了它.我似乎找不到任何线索.

I' am using Bootstrap 3, In the mobile view I would like to apply some CSS to fix up some bugs on mobile view. I have looked to documentations and Google it. I' am can't seem to find any clue on it.

有可能吗?

推荐答案

只需在 CSS 中使用适当的媒体查询,例如

Just use the appropriate media queries in your CSS, eg

@media (max-width: 767px) {
    /* CSS goes here */
}

Bootstrap 定义了以下宽度

Bootstrap defines the following widths

  • 超小型设备(手机,小于 768 像素)
  • 小型设备(平板电脑,768 像素及以上)
  • 中型设备(台式机,992 像素及以上)
  • 大型设备(大型台式机,1200 像素及以上)

有关更多信息,请参阅 http://css-tricks.com/css-media-queries/关于媒体查询的信息.

See http://css-tricks.com/css-media-queries/ for some more information on media queries.

这篇关于Bootstrap 3 仅在移动视图上应用 CSS的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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