Page with a Navbar
Description
Create a page with a navbar.
Usage
bc_page_navbar(
...,
title = NULL,
nav = NULL,
end = NULL,
href = NULL,
aria_label = "Main navigation"
)
bc_nav_item(label, href = NULL, ..., current = FALSE, disabled = FALSE)
Arguments
| Argument | Description |
|---|---|
... |
For bc_page_navbar(), page content. For bc_nav_item(), extra tag attributes. |
title |
String or tag. The app name, shown first in the navbar. |
nav |
Tag or list. Links for the navbar, usually from bc_nav_item(). |
end |
Tag or NULL. Content aligned to the end of the navbar, such as bc_theme_switcher() or a bc_dropdown_menu(). |
href |
String or NULL. A link URL. For bc_page_navbar(), it makes the app name a link. For bc_nav_item(), NULL makes a button. |
aria_label |
String. Accessible name for the navbar. Defaults to "Main navigation". |
label |
String or tag. The item's text. |
current |
Bool. Whether the item is the current page. Defaults to FALSE. |
disabled |
Bool. Whether the item is disabled. Defaults to FALSE. |
Value
See Also
Examples
bc_page_navbar(
htmltools::h2("Overview"),
title = "Acme",
href = "/",
nav = list(
bc_nav_item("Home", href = "/", current = TRUE),
bc_nav_item("Reports", href = "/reports")
),
end = bc_theme_switcher()
)
Overview
bc_nav_item("Reports", href = "/reports", current = TRUE)
Reports