Input Group
Description
A group shell for a native control with inline or block addons.
Usage
bc_input_group(..., orientation = "default", aria_label = NULL, class = NULL)
bc_input_group_addon(..., align = "start", aria_hidden = FALSE)
Arguments
| Argument | Description |
|---|---|
... |
The native control and addon children. |
orientation |
String. default for inline controls, vertical for header and footer addon rows. |
aria_label |
String. Accessible name, added only when the group itself is named. |
class |
String. Extra classes for the shell. |
align |
String. Addon placement, written to data-align. One of start, end, inline-start, inline-end, block-start, block-end. |
aria_hidden |
Bool. Whether to mark the addon aria-hidden="true". |
Value
A <div> tag.
Details
header and footer rows need orientation = "vertical".
Examples
bc_input_group(
bc_input(type = "search", placeholder = "Search...", aria_label = "Search"),
bc_input_group_addon(bc_kbd("⌘K"), align = "end")
)
⌘K
bc_input_group(
htmltools::tags$textarea(placeholder = "Enter your message"),
htmltools::tags$footer(
`data-align` = "end",
htmltools::span("120 characters left")
),
orientation = "vertical"
)