1

I'm using R shiny dashboards with tab panels. When using boxes the dashboardbody background cuts off.

This is the page when loaded:

enter image description here

And here it is scrolled down:

enter image description here

How can I get the body to resize so it doesn't cut off?

Here is the UI code:

dashboardPage(skin = "green",
  dashboardHeader(title = "Test"),
  dashboardSidebar(
    sidebarMenu(id = "tab",
      menuItem("Explore", tabName = "explore", icon = icon("eye"))
    )
  ),
  dashboardBody(
    tabItems(
      tabItem_explore
    )    
  )
)

tabItem_explore <- 
  tabItem(tabName = "explore",
    h2(icon("eye"), HTML("&nbsp;"),"Explore"), br(),

    tabsetPanel(
      type = "tabs",
      id = "explore_tabset",
      tabPanel(
         'Test', br(),
         h3('Test'), br(),
         plotlyOutput('plot1'), br(),
         box(
           title = "Test",
           status = "primary",
           solidHeader = TRUE,
           plotOutput('plot2')
         ),
         box(
           title = "Test",
           status = "primary",
           solidHeader = TRUE,
           plotlyOutput('plot3')
         ),
         box(
           title = "Test",
           status = "primary",
           solidHeader = TRUE,
           plotlyOutput('plot4')
         )
       )    

     )
   )
Vlad
  • 3,058
  • 4
  • 25
  • 53

1 Answers1

0

You can mention the height and width to stop going out of boundary like below:

output$Histogram <- renderPlot({
    ggplot(data=melt(df), mapping=aes(x=value)) + 
    geom_histogram(bins=20, col= 'Blue') + 
    facet_wrap (~variable, scales = "free_x")
}, height=499, width=649)
eesiraed
  • 4,626
  • 4
  • 16
  • 34