Create checkbox/switch input based on the selected type
Source:R/utils-shiny.R
create_checkbox_tag.RdUsed internally by toggle_input_386 and checkbox_input_386
Usage
create_checkbox_tag(
inputId,
label,
value = FALSE,
width = NULL,
type = c("switch", "checkbox")
)Arguments
- inputId
The
inputslot that will be used to access the value.- label
Display label for the control, or
NULLfor no label.- value
Initial value (
TRUEorFALSE).- width
The width of the input, e.g.
'400px', or'100%'; seevalidateCssUnit().- type
Input type. This is to be able to distinguish between switch and checkbox, which have slightly different design.