我想在我 Shiny 的应用程序中更改页面上 sideBarPanels 的背景颜色......但是......只在一个特定页面上。所以我正在考虑使用 CSS 标签,但我不确定如何去做。
我试过这个:
sidebarPanel(class="set1",
htmlOutput("vizTest")
)
然后尝试在 CSS 文件中引用该类:
#set1 form.well {
background: transparent;
border: 0px;
}
最佳答案
所以诀窍是将 sidebarPanel 包装在一个 div 中,然后为 div 设置类。然后可以使用“.”以通常的方式引用它。字首:
用户界面
div(class="set1",
sidebarPanel(
#content of panel here
))
css文件
.set1 form.well {
background: transparent;
border: 0px;
}
关于r - 如何在 Shiny App (R) 中向 SideBarPanel 添加 css 标签,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23299345/