option_list: Option list

View source: R/widget-list.R

option_listR Documentation

Option list

Description

A scrollable list of choices. Up/Down/Page Up/Page Down/Home/End move the highlight (sending "option_list.highlighted"); Enter or a click selects ("option_list.selected"). event$data has index, value and label.

Usage

option_list(choices, id = NULL, classes = NULL, style = NULL)

Arguments

choices

A character vector. Names, if present, are shown instead of the values.

id

Optional identifier.

classes

Optional classes.

style

A style().

Value

An OptionList widget with field value.

Examples

option_list(c(Comma = "csv", JSON = "json", Parquet = "parquet"))

termr documentation built on Oct. 21, 2026, 5:13 p.m.