Closed bhogan-mitre closed 2 years ago
Similar to #223, the disabled function does not get carried through to the nested button. The input itself is disabled, so nothing happens when you click it. But it's a bit deceptive to users to have a clickable button that is disabled.
disabled
library(shiny) ui <- fluidPage( shinyjs::useShinyjs(), shinyjs::disabled( fileInput("testup", "testupload") ) ) server <- function(input, output, session) {} shinyApp(ui, server)
Do you think it would work to cast the net a little wider and add span[btn] to the set of elements that are checked when enabling/disabling? https://github.com/daattali/shinyjs/blob/master/inst/srcjs/shinyjs-default-funcs.js#L238
span[btn]
It took a little bit more to fix this, but it should work now. Thanks for the report.
Great, thanks for the fix!
Similar to #223, the
disabled
function does not get carried through to the nested button. The input itself is disabled, so nothing happens when you click it. But it's a bit deceptive to users to have a clickable button that is disabled.Do you think it would work to cast the net a little wider and add
span[btn]
to the set of elements that are checked when enabling/disabling? https://github.com/daattali/shinyjs/blob/master/inst/srcjs/shinyjs-default-funcs.js#L238