Input.toggle
Displays an interactable toggle button within a Buttonize page.
Usage
Preview
app.buttonize.io
Runtime State
The value in the runtime state is the boolean value of the toggle input.
As demonstrated by the Usage example above, you can access variables from the Runtime State via the “{{bool}}” syntax from elsewhere in your Buttonize app.
Props
id
Required
string
The name of the variable containing the selected option. This variable can then be referenced elsewhere in your Buttonize app.
label
Optional
string
The text displayed by the checkbox.
initialValue
Optional
boolean
The initial state of the checkbox. Default is false
.
disabled
Optional
boolean
Whether or not the checkbox is disable. Default is false
.
spacingTop
Optional
’sm’ | ‘md’ | ‘lg’ | ‘xl’
The amount of space to give above the component.
spacingBottom
Optional
’sm’ | ‘md’ | ‘lg’ | ‘xl’
The amount of space to give below the component.
width
Optional
1 | 2 | 3 | 4
The width of the component.