make_ui_checkbox: Make checkboxes

make_ui_checkboxR Documentation

Make checkboxes

Description

Creates HTML code for checkbox response options.

Usage

make_ui_checkbox(
  label,
  choices,
  subprompt = "",
  labels = NULL,
  trigger_button_text = "Continue",
  javascript = "",
  hide = FALSE,
  id = "response_ui"
)

Arguments

label

(Character scalar) Label for the current page.

choices

(Character vector) Choices for the participant. If unnamed, then these values will be used both for checkbox IDs and for checkbox labels. If named, then values will be used for checkbox IDs and names will be used for checkbox labels.

subprompt

(Character scalar) Optional additional text in bold letters below the prompt.

labels

Optional vector of labels for the NOMC choices. If not NULL, will overwrite the names of choices. This vector of labels can either be a character vector or a list of Shiny tag objects, e.g. as created by shiny::HTML().

trigger_button_text

(Character scalar) Text for the trigger button.

javascript

(Character scalar) JavaScript code to be added for controlling checkbox behaviour.

hide

(Boolean scalar) Whether the checkboxes should be hidden (possibly to be shown later).

id

(Character scalar) HTML ID for the div containing the checkboxes.


pmcharrison/psychTestR documentation built on Nov. 10, 2024, 9:03 p.m.