R shiny - background of sidebar panel

后端 未结 2 1384
感动是毒
感动是毒 2020-12-09 04:29

Let\'s say, I\'ve got a simple shiny application and I would like to change sidebar panel background. I\'ve tried with css, but I\'ve managed only to change the whole

2条回答
  •  时光取名叫无心
    2020-12-09 05:00

    This has an answer somewhere, if I can find it. (I know because I found the answer when I wanted to change the background color of my sidebars). You can use the tags$style() function to get what you need. I can't remember precisely if you want to color the body or the well, (apparently I did both), but you can play around with it a little until you get your result.

    sidebarPanel(
      tags$style(".well {background-color:[your_color];}"),
      ...)
    

    Turns out you want to just change the .well

提交回复
热议问题