我正在使用 Bootstrap 并专注于移动导航。悬停时,图标(三条水平线)具有灰色背景色;然而,背景颜色只在图标的一半处出现(见图)。我不介意这种背景颜色,但我想在顶部有圆 Angular 边缘的完整图标上方,因为它们在底部。我怎样才能做到这一点?任何想法/建议表示赞赏。
最佳答案
您需要更改为图标栏颜色,显示在:
<span class="icon-bar"></span>
使用 CSS 设置你想要的颜色
.navbar-default .navbar-toggle .icon-bar {
background-color: #fff;
}
您还可以设置按钮的背景颜色。
.navbar-toggle {
background-color: #666;
}
如果你想改变焦点的颜色,那么只需在 Bootstrap 中调整 :focus 标签:
.navbar-toggle:focus {
// set the new color here for focus
}
和
.navbar-toggle:focus .icon-bar {
// here for the 3 white Stripes
}
关于html - Twitter Bootstrap 响应式导航(btn-navbar、icon-bar)颜色变化,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25065974/