How is it possible to include a control widget under the menuSubItem in the sidebar of a shiny app?
This is my trial:
library(shiny)
library(shinyWidgets)
library(shinydashboard)
ui <- dashboardPage(
### Header -----
dashboardHeader(title = "Example App"),
### Sidebar -----
dashboardSidebar(
sidebarMenu(
menuItem(
text = "A",
tabName = "analytics",
icon = icon("signal"),
startExpanded = TRUE,
menuSubItem(text = "a",
icon = NULL,
pickerInput(
inputId = "Id086",
label = "Placeholder",
choices = c("a", "b", "c", "d"),
options = list(
title = "This is a placeholder")
)
),
menuSubItem(text = "b",
icon = NULL)
)
)
),
dashboardBody(
)
)
## Server-function -----
server <- function(input, output) {
}
# Run the application
shinyApp(ui = ui, server = server)
However, the desired input does not appear within the app. I managed it to include the input widget under any of the menu items but i failed to make it appear under menuSubItems.