Skip to content

Is there a way in which the menu can automatically collapse back once a country is selected?  #5

@Shelmith-Kariuki

Description

@Shelmith-Kariuki

Hi @pvictor ,

Thank you so much for this package.

Is there a way in which the menu can automatically collapse back once a country is selected?

`
library(shiny)
library(shinytreeview)

data("cities")

ui <- fluidPage(
tags$h3("treeviewInput cities example"),
treeviewInput(
inputId = "tree",
label = "Choose a city:",
choices = make_tree(
cities, c("continent", "country", "city")
),
multiple = FALSE,
prevent_unselect = TRUE,
width = "100%"
),
verbatimTextOutput(outputId = "result")
)

server <- function(input, output, session) {
output$result <- renderPrint({
input$tree
})
}

if (interactive())
shinyApp(ui, server)
`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions