Create a Bootstrap navbar for a page.
Arguments
- ...
Arguments passed on to
bslib::page_navbartitleA (left-aligned) title to place in the card header/footer. If provided, other nav items are automatically right aligned.
ida character string used for dynamically updating the container (see
nav_select()).selecteda character string matching the
valueof a particularnav_panel()item to selected by default.sidebarA
sidebar()component to display on everynav_panel()page.fillableWhether or not to allow
fillitems to grow/shrink to fit the browser window. IfTRUE, allnav_panel()pages arefillable. A character vector, matching thevalueofnav_panel()s to be filled, may also be provided. Note that, if asidebaris provided,fillablemakes the main content portion fillable.fillable_mobileWhether or not
fillablepages should fill the viewport's height on mobile devices (i.e., narrow windows).gapA CSS length unit defining the
gap(i.e., spacing) between elements provided to....paddingPadding to use for the body. This can be a numeric vector (which will be interpreted as pixels) or a character vector with valid CSS lengths. The length can be between one and four. If one, then that value will be used for all four sides. If two, then the first value will be used for the top and bottom, while the second value will be used for left and right. If three, then the first will be used for top, the second will be left and right, and the third will be bottom. If four, then the values will be interpreted as top, right, bottom, and left respectively.
positionDetermines whether the navbar should be displayed at the top of the page with normal scrolling behavior (
"static-top"), pinned at the top ("fixed-top"), or pinned at the bottom ("fixed-bottom"). Note that using"fixed-top"or"fixed-bottom"will cause the navbar to overlay your body content, unless you add padding, e.g.:tags$style(type="text/css", "body {padding-top: 70px;}")headerUI element(s) (htmltools::tags) to display above the nav content.
footerUI element(s) (htmltools::tags) to display below the nav content.
bga CSS color to use for the navbar's background color.
inverseEither
TRUEfor a light text color orFALSEfor a dark text color. If"auto"(the default), the best contrast tobgis chosen.underlineWhether or not to add underline styling to page links when active or focused.
collapsibleTRUEto automatically collapse the navigation elements into an expandable menu on mobile devices or narrow window widths.fluidTRUEto use fluid layout;FALSEto use fixed layout.themeA
bs_theme()object.window_titlethe browser window title. The default value,
NA, means to use any character strings that appear intitle(if none are found, the host URL of the page is displayed by default).langISO 639-1 language code for the HTML page, such as "en" or "ko". This will be used as the lang in the
<html>tag, as in<html lang="en">. The default (NULL) results in an empty string.
