在R Shiny中更改navbarPage菜单栏的背景颜色
在R Shiny中,我想更改导航栏菜单的背景颜色.我想将菜单栏上所有位置的颜色(包括悬停在按钮上或按钮处于非活动状态时的按钮的颜色)更改为一种颜色(黑色),但字体除外.但是,我不希望更改任何其他默认颜色,例如页面主要部分的背景颜色.我尝试通过如下创建CSS文件来实现此目的:
In R Shiny, I would like to change the background colour of the navbar menu. I would like to change the colour everywhere on the menu bar (including the colour of the buttons when hovering over them, or when they're inactive, etc.), except for the font, to one colour (black). However, I do not wish to change any other default colours, such as the background colour of the main part of the page. I've attempted to do so by creating a CSS file as follows:
body,
#selector,
.container,
.navbar-background { background: #000000; }
我也尝试了许多其他组合和参数,但似乎没有任何效果.用于控制导航栏菜单栏背景颜色的CSS文件中的参数是什么?
I've also tried lots of other combinations and parameters, but nothing seems to work. What is the parameter in the CSS file that controls the background colour of the navbar menu bar?
请注意以下答案:如何在其中更改navBarPage标头背景Zebble吗?没为我工作.
Note that the answer in: How to change navBarPage header background in Zebble? hasn't worked for me.
尝试
.navbar-default {
background-color: #b1b1b3 !important;
}
.navbar-default:hover {
background-color: #aaaaaa !important;
color: yellow;
}