diff --git a/R/boxes.R b/R/boxes.R index b695e657..e3ded371 100644 --- a/R/boxes.R +++ b/R/boxes.R @@ -291,7 +291,7 @@ box <- function(..., title = NULL, footer = NULL, status = NULL, shiny::icon(collapseIcon)) } - if (!is.null(boxMenu)) { + if (!is.null(collapseTag) || !is.null(boxMenu)) { boxTools <- div(class = "box-tools pull-right", collapseTag, boxMenu) } diff --git a/tests-manual/box.R b/tests-manual/box.R index 941c7917..4b325e86 100644 --- a/tests-manual/box.R +++ b/tests-manual/box.R @@ -42,13 +42,13 @@ body <- dashboardBody( choices = c("0%" = 0, "20%" = 20, "40%" = 40, "60%" = 60, "80%" = 80, "100%" = 100) ), - #boxMenu = boxItem(a(href="https://www.bing.com", "bing it!", - # style = "color: yellow", target = "_blank"), - # downloadButton("svgdown", "download svg")), + boxMenu = boxItem(a(href="https://www.bing.com", "bing it!", + style = "color: yellow", target = "_blank"), + downloadButton("svgdown", "download svg")), collapsible = FALSE, collapsed = FALSE ), box(title = "Histogram box title", - status = "info", solidHeader = TRUE, collapsible = FALSE, + status = "info", solidHeader = TRUE, collapsible = T, boxMenu = boxMenuOutput("menuWrench"), plotOutput("plot", height = 250) )