Sets/gets the value of the aria-label
attribute.
Sets/gets the aria-labelledby
attribute.
If not set, the aria-labelledby
will be equal to the value of labelId
attribute.
Readonly
changeAn event that is emitted after the checkbox state is changed.
Provides references to the IgxCheckboxComponent
and the checked
property as event arguments.
Returns the class of the switch component.
Sets/gets the disabled
attribute.
Default value is false
.
Enables/Disables the ripple effect.
If not set, disableRipple
will have value false
.
Sets/gets whether the checkbox should disable all css transitions.
Default value is false
.
Sets/gets whether the switch component is on focus.
Default value is false
.
Sets/gets the id
of the checkbox component.
If not set, the id
of the first checkbox component will be "igx-checkbox-0"
.
Sets/gets the checkbox indeterminate visual state.
Default value is false
;
Sets/gets whether the switch component is invalid.
Default value is false
.
Sets/gets the id of the label
element.
If not set, the id of the label
in the first checkbox component will be "igx-checkbox-0-label"
.
Sets/gets the position of the label
.
If not set, the labelPosition
will have value "after"
.
Sets/gets the name
attribute.
Returns reference to the native checkbox element.
Returns reference to the native label element.
@example
let labelElement = this.component.nativeLabel;
Returns reference to the label placeholder element.
@example
let labelPlaceholder = this.component.placeholderLabel;
Sets/gets whether the checkbox is readonly.
Default value is false
.
Sets/gets the value of the tabindex
attribute.
Sets/gets the value
attribute.
Sets/gets whether the checkbox is checked.
Default value is false
.
Sets/gets whether the switch is on or off. Default value is 'false'.
Returns reference to the nativeElement
of the igx-checkbox/igx-switch.
Sets/gets whether the checkbox is required.
If not set, required
will have value false
.
The Switch component is a binary choice selection component.
Igx Module
IgxSwitchModule
Igx Theme
igx-switch-theme, igx-tooltip-theme
Igx Keywords
switch, states, tooltip
Igx Group
Data Entry & Display
Remarks
The Ignite UI Switch lets the user toggle between on/off or true/false states.
Example