I'll explain the example through the following link. https://shiny.rstudio.com/gallery/tabsets.html
I want to put a different color on each tab.
ex) plot(background:red), summary(background:orange), table(background:green).
I thought of giving each tab an tag: class or id
and putting a color in the corresponding tag: class or id
. But I do not know what to do.
This is the example what I tried.
mainPanel(
tags$head(
tags$style(HTML("
.one {background-color: red;}
")),
tags$style(HTML("
.two {background-color: orange;}
")),
tags$style(HTML("
.three {background-color: green;}
")),
),
tabsetPanel(
tabPanel("plot", class = "one",
tags$div(
some code..
)
),
tabPanel("summary", class = "one",
tags$div(
some code..
)
),
tabPanel("table", class = "one",
tags$div(
some code..
)
)
)
)
But it's not worked. Can anyone help with this?