| navInputs | R Documentation |
Full-width inputs for sidebars and tabs. Each is a thin wrapper around a
'shiny', 'bslib', 'shinyWidgets' or 'colourpicker' input, uses the same
argument names, and takes an optional tooltipText that adds an info icon
to the label (see addTooltip()).
navButton(inputId, label, tooltipText = NA)
navSelect(
inputId,
label,
choices = NULL,
selected = choices[1],
multiple = FALSE,
create = FALSE,
tooltipText = NA
)
navUpload(inputId, label, multiple = FALSE, tooltipText = NA)
navCheckbox(inputId, label, value = FALSE, tooltipText = NA)
navDownload(inputId, label, tooltipText = NA)
navText(inputId, label, value = "", tooltipText = NA)
navNumeric(inputId, label, value = 1, min = NA, max = NA, tooltipText = NA)
navColor(inputId, label, value = "white", tooltipText = NA)
navDate(inputId, label, range = FALSE, tooltipText = NA)
inputId |
The input's ID. Read it in the server as |
label |
Label shown above or beside the input. |
tooltipText |
Optional text for an info tooltip on the label. |
choices |
Choices to offer. Can be left |
selected |
Choices selected at start. Defaults to the first choice. |
multiple |
|
create |
|
value |
Starting value: text for |
min, max |
Smallest and largest allowed values. |
range |
|
| Function | Builds | Read in the server as |
navButton() | bslib::input_task_button() | input$id (click count) |
navSelect() | shiny::selectizeInput() | input$id (chosen values) |
navUpload() | shiny::fileInput() | input$id$datapath, input$id$name |
navDownload() | shiny::downloadButton() | pair with output$id <- downloadHandler(...) |
navCheckbox() | bslib::input_switch() | input$id (TRUE/FALSE) |
navText() | shiny::textInput() | input$id |
navNumeric() | shiny::numericInput() | input$id |
navColor() | colourpicker::colourInput() | input$id (hex color) |
navDate() | shinyWidgets::airDatepickerInput() | input$id (one or two dates) |
A 'shiny' tag (or tag list) to place in the UI.
navButton("runData", "Run analysis", tooltipText = "Upload data first")
navSelect("groups", "Pick groups", choices = c("Control", "Treated"),
multiple = TRUE)
navUpload("dataUpload", "Upload a CSV")
navDownload("resultsDownload", "Download results")
navCheckbox("logScale", "Use a log scale")
navText("plotTitle", "Plot title")
navNumeric("alpha", "Significance cutoff", value = 0.05, min = 0, max = 1)
navColor("pointColor", "Point color", value = "#D55E00")
navDate("dates", "Date range", range = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.