highcharter icon indicating copy to clipboard operation
highcharter copied to clipboard

chart height is not responsive in shiny

Open CamilaAchuri opened this issue 2 years ago • 1 comments

the display is responsive by default, however when I using highcharter::highchartOutput it does not include the height option at 100% or auto, and by default it generates a height of 400px

library(shiny)
library(highcharter)
app <- shinyApp(
  ui = fluidPage(
    highchartOutput("plot", height = "100%")
  ),
  server = function(input, output) {
    output$plot <- renderHighchart({
      highcharter::highchart() %>%
        highcharter::hc_add_series(data = cumsum(rnorm(100))) %>%
        highcharter::hc_responsive()
    })
  }
)

runApp(app)

this is strange because the shinyWidgetOutput function allows you to enter the height size in a format other than pixels, for example, for leaflet it works correctly

CamilaAchuri avatar Oct 27 '22 18:10 CamilaAchuri

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Feel free to reopen it if you find it necessary.

stale[bot] avatar Mar 17 '24 09:03 stale[bot]