Here is a very rough example. The widths need not add to 12. Any unused width will just be blank.
library(shiny)
ui <- fluidPage(
titlePanel("Mock App"),
sidebarLayout(
sidebarPanel( width = 2,
fluidRow( h1("Sidebar Title"),
actionButton("Bttn1", "Press Me")),
fluidRow( actionButton("Bttn2", "Press Me")),
fluidRow( actionButton("Bttn3", "Press Me")),
fluidRow( actionButton("Bttn4", "Press Me"))
),
mainPanel(width = 8, style = "border-style: solid; border-color: black",
h1("Main Panel Header"),
plotOutput("Plot1", height = "350px", width = "100%")
)
)
) #Close FluidPage
server <- function(input, output) {
output$Plot1 <- renderPlot({
plot(seq(0,10), seq(100, 110), col = "red")
})
}
# Run the application
shinyApp(ui = ui, server = server)
Also, you need not use the sidebarLayout if it does not fit your needs. You can use fluidRow() and divide that into horizontal pieces with column()