| tabler-inputs {tabler} | R Documentation |
Select Input
Description
A dropdown that lets the user pick one item from a list.
Usage
select_input(input_id, label, choices, selected = NULL, searchable = TRUE, ...)
select_multiple_input(input_id, label, choices, selected = NULL, ...)
slider_input(
input_id,
label,
min,
max,
value,
step = 1,
thumb_size = NULL,
fill = FALSE,
color = NULL,
...
)
update_select_input(session, input_id, label = NULL, choices = NULL, selected = NULL, ...)
update_slider_input(
session,
input_id,
label = NULL,
value = NULL,
min = NULL,
max = NULL,
step = NULL
)
text_input(input_id, label, value = "", placeholder = NULL, mask = NULL, ...)
numeric_input(input_id, label, value, min = NULL, max = NULL, step = 1, ...)
date_input(
input_id,
label,
value = Sys.Date(),
min = NULL,
max = NULL,
icon = c("none", "left", "right"),
inline = FALSE,
...
)
checkbox_input(input_id, label, value = FALSE, description = NULL, inline = FALSE, ...)
action_button(input_id, label, class = "btn-primary", icon = NULL, ...)
checkbox_group_input(input_id, label, choices, selected = NULL)
radio_buttons(input_id, label, choices, selected = NULL, inline = FALSE)
Arguments
input_id |
The input identifier used in server.
|
label |
Display label shown above the control. |
choices |
Named or unnamed character vector of choices. A top-level
element that is itself a vector of length > 1 is rendered as an
<optgroup> (its name becomes the group label), matching Shiny's
grouped-choices convention.
|
selected |
Initially-selected value (defaults to the first choice). |
searchable |
If TRUE (the default), overlay the dropdown with
a text box that filters choices by substring match anywhere in the
label as the user types (e.g. typing "Korea" narrows the list to
"South Korea", "North Korea", ...), instead of relying on the browser's
native jump-to-prefix <select> behavior. Set to FALSE to
render a plain native dropdown.
|
... |
Additional HTML attributes passed to the <select> element.
|
min |
Minimum value. |
max |
Maximum value. |
value |
Initial value. A length-2 vector renders a dual-thumb range slider. |
step |
Step size (default 1).
|
thumb_size |
Optional numeric multiplier of the default handle size
(1rem), e.g. 1 for the normal size, 2 for double
size, 2.5 for 250%. Defaults to NULL (Tabler's built-in
size).
|
fill |
If TRUE, paint the track from the minimum up to the
current value (single slider) or between the two handles (range
slider), instead of leaving the whole track a flat color.
|
color |
Optional accent color for the handle(s) and, when
fill = TRUE, the filled track. Either one of Tabler's named
theme colors ("blue", "azure", "indigo",
"purple", "pink", "red", "orange",
"yellow", "lime", "green", "teal",
"cyan") or any other valid CSS color. Defaults to NULL,
which uses the app's current primary/theme color (see page()).
|
session |
The session object. |
placeholder |
Placeholder text (defaults to mask, if given).
|
mask |
Optional input mask made of "0" digit placeholders
and literal separator characters, e.g. "00/00/0000" for a date
or "(00) 0000-0000" for a phone number. As the user types
digits, the literal characters are inserted automatically.
|
icon |
Where to place a calendar icon next to the field:
"none" (default), "left" or "right". Ignored when
inline = TRUE.
|
inline |
If TRUE, render an always-visible month calendar
(with previous/next-month navigation) instead of a text field with a
popup picker.
|
description |
Optional secondary text shown below the label. |
class |
Additional CSS classes (default "btn-primary").
|
Value
An HTML tag.