Open asadow opened 1 year ago
To me this behaviour makes sense. You can only move the slider which is covering the other one. What is your expected behaviour?
library(shiny)
ui <- fluidPage(
sliderInput(
inputId = "year",
label = "Choose years",
step = 1,
sep = "",
min = 2014,
max = 2022,
value = c(2014, 2022)
)
)
server <- function(input, output, session) {}
shinyApp(ui, server)
It does not look like a slider is covering the other one, hence I would expect you can pull either way.
I personally think that the current behaviour feels correct and intuitive, but I checked what else is out there.
From a quick search it seems like the shiny behaviour is also the standard behaviour for other sliders. Here's the first three double-sided sliders I found using google, and all of them work the same way; if you drag one end over the other, then only this end will be moveable. And there's no special visual indication that they overlap.
https://jqueryui.com/slider/#range
I disagree for 2 reasons. Once a slider covers the other one, 1) there's no indication of which slider is covering which, 2) nor that it is a range input, as opposed to a single value slider.
Hopefully the title makes sense. I recommend to just try it.
sliderInput( inputId = "year", label = "Choose years", step = 1, sep = "", min = 2014, max = 2022, value = c(2014, 2022) )