Skip to contents

Creates a shiny.fluent toggle

Usage

make_toggle(
  i18n = character(),
  ns = character(),
  id = NULL,
  label = character(),
  value = FALSE,
  inline = FALSE,
  bold = TRUE
)

Arguments

i18n

Translator object from shiny.i18n library

ns

Shiny namespace

id

ID used for the input (character)

label

Label used for the input (character)

value

Value of the toggle : TRUE or FALSE (logical)

inline

Should the toggle displayed inline (logical)

bold

Should the text of the title be bold (logical)

Value

HTML / Shiny UI code

Examples

if (FALSE) {
make_toggle(i18n = i18n, ns = ns, label = "My toggle", id = "my_toggle", value = TRUE, inline = FALSE, bold = TRUE)
}