I am able to colour all checkboxes purple with the code below. How can I define different fill colors for each choice (A, B, C, D, E)? It would be great if someone could help me!
ui <- fluidPage(
fluidRow(
prettyCheckboxGroup(inputId ="var", label= "Select Letter",
choices = c("A", "B", "C", "D", "E"),
selected = c("A", "B", "C", "D", "E"),
inline = FALSE, width = NULL)),
tags$style(".pretty.p-default input:checked~.state label:after {background-color: #A901DB !important;}"),
)
server <- function(input, output, ...) {
}
shinyApp(ui, server)
Aucun commentaire:
Enregistrer un commentaire