Sioux UISwitch
Overview
The UISwitch
class lets you create On/Off buttons, similar to the iOS one. demo
Inheriths from:
- sioux-ui
javascript:
var UISwitch = ;var uiswitch = document;// document.querySelector('.container') is the element in which the switch will be appendeduiswitch;
Properties
state
- Boolean
- the state of the switch
Methods
setState(state)
Sets the switch to the passed in state
(Boolean).
Events
'change'
Fires when the switch changed state (when the CSS transition ends);