I\'m learning shiny apps and have some basic questions about tweaking the layout, particularly style and font. I\'d be grateful for pointers or explicit answers, thanks!
This is a really old post, but for posterity: you can just put css in your mainPanel() call. If you want a fixed-position plot in the mainPanel in a sidebar layout:
sidebarLayout(
sidebarPanel(),
mainPanel(style="position:fixed;margin-left:32vw;",
plotOutput("plot")
)
)
Another way to insert styling in Shiny is through its tag
command. The result will be the same as inserting plain HTML:
tags$style(type="text/css", ".span8 .well { background-color: #00FFFF; }")
the result will be the same as inserting plain HTML code (in this example the result would be the same as the last code snippet by Scott)
You can include arbitrary html, for example, within the call to sidebarpanel
, you can do
HTML('<style type="text/css">
.row-fluid .span4{width: 26%;}
</style>')
this is just something copied from one of my Shiny apps
You could use inspector tools in the browser to figure out what css elements need to be changed.
If you use a wellPanel inside the mainPanel this modifies that wellPanel to be blue
HTML('<style type="text/css">
.span8 .well { background-color: #00FFFF; }
</style>'),