Git Product home page Git Product logo

Comments (3)

gadenbuie avatar gadenbuie commented on May 24, 2024

Unfortunately those docs are just very outdated. The responsive argument was marked as deprecated in 2014 (when shiny upgraded from Bootstrap 2 to Bootstrap 3) and then fully removed from fluidPage() and fixedPage() in shiny 1.7.0 (released 3 years ago).

I think the article date on that page isn't quite telling the truth, which leads to additional confusion. I'll make sure we have an internal ticket to update that article.

from shiny.

wbakerrobinson avatar wbakerrobinson commented on May 24, 2024

Given that this isn't an option anymore. Do you have any suggestions on another way to turn off the responsive bootstrap features for a shiny app?

from shiny.

cpsievert avatar cpsievert commented on May 24, 2024

This argument however doesn't work to turn off responsive bootstrap features. When the window in the example shiny app code above becomes smaller than 768px the wellPanel() is resized stacking the widgets.

FWIW, responsive = FALSE was about turning off the responsive page width (i.e., the container that adds margins to the page), not about preventing the collapse of grid layout on small devices (I don't think we've ever supported that). Today, if you wanted that same responsive = FALSE, you'd use bootstrapPage(), not fixedPage()/fluidPage().

Thankfully, it seems like a new Bootstrap stacking feature might be exactly what you're looking for. We don't have an official wrapper for it, but you could write the HTML:

library(shiny)
library(bslib)

ui <- page_fixed(
  titlePanel("Old Faithful Geyser Data"),
  div(
    class = "hstack p-3 gap-3 justify-content-center bg-light border rounded",
    sliderInput(
      "a", "slider 1",
      min = 1,
      max = 10,
      value = 3
    ),
    sliderInput(
      "b", "slider 2",
      min = 1,
      max = 10,
      value = 5
    ),
    checkboxGroupInput(
      "c", "checkbox 1",
      choices = c("a", "b", "c", "d"),
      selected = "a"
    ) 
  )
)

shinyApp(ui, function(input, output) {})

from shiny.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.