简体   繁体   中英

Changing the language of "to" in Shiny's dateRangeInput

I'm very new to shiny or any dashboard related development for that matter. My question is kind of specific and only tackles how the data is displayed and does not talk about internal logic of the app.

I applied language = "ru" option inside dateRangeInput and it changed how the text within date selector is rendred but it did not change the "to" bettween the two datefields. I understand that it might sound like I'm nitpicking but these little details matter for what I'm trying to do. Screenshow to ilustrate the problem.

Thanks in advance!

在此处输入图片说明

ui <- fluidPage(
  titlePanel("Калькулятор остатков"),
  sidebarLayout(
    sidebarPanel(
      dateRangeInput("dates","Временной диапазон",start = "2020-07-01", 
                                                  end = "2020-09-01", language = "ru"),
    ),
    mainPanel()
  )
)

server <- function(input, output, session) {
}

shinyApp(ui, server)

The function dataRangeInput has an seperator - argument, the default is to . You may change this to your desired word.

ui <- fluidPage(
  titlePanel("Калькулятор остатков"),
  sidebarLayout(
    sidebarPanel(
      dateRangeInput("dates",
                     "Временной диапазон",
                     start = "2020-07-01", 
                     end = "2020-09-01", 
                     language = "ru",
                     separator = " до "),
    ),
    mainPanel()
  )
)

server <- function(input, output, session) {
}

shinyApp(ui, server)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM