new ToggleButtonViewModel(command)
View model, used to display the properties of toggle buttons.
| Name | Type | Default | Description |
|---|---|---|---|
command |
Command |
The command that will be executed when switching buttons. |
|
options.toggled |
Boolean | false |
optional
Boolean value, used to indicate whether the button should be switched initially. |
options.tooltip |
String | '' |
optional
A string containing button tooltips. |
Members
-
commandCommand
-
The command that will be executed when obtaining the toggle button.
-
toggledBoolean
-
Get or set whether the button is currently switched. This attribute is observable.
- Default Value: false
tooltipString
Get or set tooltips for buttons. This attribute is observable.
- Default Value: ''