Description Usage Arguments See Also
Function to generate a drop-down menu with the bootstrap-select jQuery plugin in an R Markdown document
1 2 3 4 5 6 | bsselect(vector, selected = NULL, type = c("text", "img", "iframe"),
frame_height = "500", frame_width = "100%", align_right = FALSE,
dropup_auto = TRUE, header = FALSE, live_search = FALSE,
box_width = FALSE, live_search_style = "contains", show_tick = FALSE,
size = "auto", style = NULL, width = NULL, height = NULL,
elementId = NULL, ...)
|
vector |
A named vector of values to send to the bootstrap-select dropdown menu. |
selected |
The selected option; if NULL defaults to the first element of |
type |
One of |
frame_height |
The height of the image or iframe. Defaults to 500px. |
frame_width |
The width of the image or iframe. |
align_right |
Whether to align the menu to the right instead of the left. Defaults to FALSE. |
dropup_auto |
Creates a drop-up menu automatically if there is not enough space to drop down. Defaults to TRUE. |
header |
Adds a header to the top of the menu. |
live_search |
When TRUE, adds a search box to the drop-down menu. Defaults to FALSE. |
box_width |
One of "auto", "fit", a css-width in pixels, or FALSE. |
live_search_style |
One of "contains" (the default) or "startsWith". |
show_tick |
Whether to show a check mark next to the selected option. Defaults to FALSE. |
size |
The number of items to show in the window. Defaults to "auto"; if FALSE, shows every option. |
style |
Add the value to the button's style. Options include "btn-primary", "btn-info", "btn-success", "btn-warning", and "btn-danger". |
width |
The width of the htmlwidget. |
height |
The height of the htmlwidget. |
elementId |
The element ID. |
https://silviomoreto.github.io/bootstrap-select/
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.