daattali / colourpicker

🎨 A colour picker tool for Shiny and for selecting colours in plots (in R)
https://daattali.com/shiny/colourInput/
Other
217 stars 28 forks source link

Alpha feature bug: when using shinyjs::reset() on a colour input since the alpha feature, it breaks #15

Closed daattali closed 7 years ago

daattali commented 7 years ago
library(shiny)
ui<-fluidPage(shinyjs::useShinyjs(),
  colourpicker::colourInput("col", "colour", "#abde",allowOpacity = TRUE),
  actionButton("btn", "go")
)
server<-function(input,output,session){
  observeEvent(input$btn, {
    shinyjs::reset("col")
  })
}
shinyApp(ui,server)
daattali commented 7 years ago

Fixed on shinyjs https://github.com/daattali/shinyjs/commit/595cd30955c93cc5aa4952313601950c684659d4