Checkbox
Description
Create a checkbox with a label.
Usage
bc_checkbox(
id,
label,
...,
checked = FALSE,
disabled = FALSE,
invalid = FALSE,
description = NULL,
name = id
)
Arguments
| Argument | Description |
|---|---|
id |
String. The input ID. |
label |
String or tag. The label. |
... |
Extra tag attributes for the checkbox. |
checked |
Bool. Whether the box starts checked. Defaults to FALSE. |
disabled |
Bool. Whether the box is disabled. Defaults to FALSE. |
invalid |
Bool. Whether to show the invalid state. Defaults to FALSE. |
description |
String or tag. Helper text shown under the label. |
name |
String. The input name. Defaults to id. |
Value
An htmltools tag.
Examples
bc_checkbox("terms", "Accept terms and conditions")
bc_checkbox(
"updates",
"Email me updates",
checked = TRUE,
description = "Unsubscribe at any time."
)
Unsubscribe at any time.