没有侧边栏面板的可折叠盒子/几个可折叠或手风琴作为侧边栏

问题描述

我想创建一个 Shiny 应用,其中包含多个 collapsible 框作为一侧的菜单。为此,到目前为止,我使用了 bsCollapsePanel 函数并将其放入 sidebarPanel。不幸的是,我从盒子到 sidebarPanel 有额外的边距。盒子看起来很衬托。但我只想使用可折叠框作为侧边栏。

到目前为止,我已经使用了以下解决方案:

library(shinythemes)
library(shinyBS)

fluidPage(
  theme = shinytheme("cosmo"),titlePanel(# app title/description
    "ShinyApp"),sidebarLayout(
    mainPanel(plotOutput("plot1")),sidebarPanel(
      bsCollapsePanel(
        "Color Selection",actionButton("f1blue","Blue"),actionButton("f1red","Red"),actionButton("f2blue",actionButton("f2red",style = "success"
      ),)
   
  )
)

这是图形输出:

enter image description here

这就是它的样子。我想避免这种“盒子中的盒子”效应。侧边栏面板中只有可折叠项,没有边框和边距:

enter image description here

是否有解决方案和/或另一个包更适合创建可折叠/手风琴?

我很感激任何建议!

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)