Toggle#
Toggle #
Toggle(
data: Union[DataType, DataFrame],
*,
id_column: str = "id",
label: Union[str, WidgetField] = "",
label_column: Optional[str] = None,
widget_id: Optional[str] = None,
default_selection: Optional[str] = None
)
Enables selection from list, toggling between entries/settings.
Enables users to select from a list of entries, providing a mechanism to toggle between different selections or settings.
Constructor for Toggle widget.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
id_column |
str
|
Column name in pandas DataFrame used as entries ids. |
'id'
|
data |
Union[DataType, DataFrame]
|
data source for the widget. |
required |
label |
Union[str, WidgetField]
|
toggle widget label. |
''
|
label_column |
Optional[str]
|
Column name in pandas DataFrame used for the widget labeling. |
None
|
widget_id |
Optional[str]
|
unique widget id in a dashboard. |
None
|
default_selection |
Optional[str]
|
pre selected entities on initial state. |
None
|