navbar_page {fomantic.plus} | R Documentation |
Fomantic UI page with top level navigation bar
Description
This creates a Fomantic page for use in a Shiny app. It is in the same layout as navbarPage
,
where a top level navigation bar exists.
Usage
navbar_page(
...,
title = "",
id = NULL,
selected = NULL,
position = c("", "top fixed", "bottom fixed"),
head = NULL,
header = NULL,
footer = NULL,
collapsible = FALSE,
window_title = title,
class = "stackable",
theme = NULL,
enable_hash_state = TRUE,
suppress_bootstrap = TRUE
)
Arguments
... |
Other arguments to be added as attributes of the main div tag wrapper (e.g. style, class etc.) |
title |
A title to display in the navbar. |
id |
ID of the navbar menu. Given random ID if none specified. |
selected |
Which tab should be selected first? If none selected, will automatically have the first tab open. |
position |
Determines the location and behaviour of the navbar. Padding will be included when pinned to prevent overlap.
|
head |
Optional list of tags to be added to |
header |
Optional list of tags to be added to the top of all |
footer |
Optional list of tags to be added to the bottom of all |
collapsible |
|
window_title |
A title to display in the browser's title bar. By default it will be the same as the navbar title. |
class |
Additional classes to be given to the navbar menu. Defaults to |
theme |
Theme name or path. Full list of supported themes you will find in
|
enable_hash_state |
boolean flag that enables a different hash in the URL for each tab, and creates historical events |
suppress_bootstrap |
boolean flag that suppresses bootstrap when turned on |
Details
Inside, it uses two crucial options:
(1) shiny.minified
with a logical value, tells whether it should attach min or full
semantic css or js (TRUE by default).
(2) shiny.custom.semantic
if this option has not NULL character semanticPage
takes dependencies from custom css and js files specified in this path
(NULL by default). Depending on shiny.minified
value the folder should contain
either "min" or standard version. The folder should contain: semantic.css
and
semantic.js
files, or semantic.min.css
and semantic.min.js
in shiny.minified = TRUE
mode.
The following classes can be applied to the navbar:
stackable
- When the width of the webpage becomes too thin, for example on mobile, the navbar will become a stackinverted
- Will create an inverted coloured navbar
Value
A shiny.tag.list
containing the UI for a shiny application.
Examples
navbar_page(
title = "App Title",
tab_panel("Plot"),
tab_panel("Summary"),
tab_panel("Table")
)
navbar_page(
title = "App Title",
tab_panel("Plot"),
tab_panel("Icon", icon = "r project"),
navbar_menu(
"More",
tab_panel("Summary"),
"----",
"Section header",
tab_panel("Table")
)
)