在移动设备上查看我的twitter bootstrap网站时,每边都有20px的排水沟.这会阻止任何触及桌面边缘的内容在移动设备上执行此操作.在移动设备上查看时,Twitter bootstrap主页本身没有这些排水沟.http://twitter.github.com/bootstrap/
其他网站称放置一个正文{padding-left:0; padding-right:0}会有所帮助,但这会产生另一个弄乱导航栏的问题.
有线索吗?
尝试在Bootstrap CSS 之后的某处添加此CSS:
@media (max-width: 767px) {
body {
padding-right: 0;
padding-left: 0;
}
.navbar-fixed-top,
.navbar-fixed-bottom,
.navbar-static-top {
margin-right: 0;
margin-left: 0;
}
}
Run Code Online (Sandbox Code Playgroud)