Allows users to make a binary choice for a certain condition.

Igx Module
IgxCheckboxModule
Igx Theme
igx-checkbox-theme
Igx Keywords
checkbox, label
Igx Group
Data entry and display

Remarks

[object Object]

Example

<igx-checkbox [checked]="true">
  simple checkbox
</igx-checkbox>

IgxCheckboxComponent

new IgxCheckboxComponent(): IgxCheckboxComponent

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:237

Returns IgxCheckboxComponent

Inherited from: CheckboxBaseDirective

Sets/gets the value of the aria-label attribute.

ariaLabel: string = null

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:235

Example

<igx-checkbox aria-label="Checkbox1"></igx-checkbox>
let ariaLabel = this.checkbox.ariaLabel;

Inherited from: CheckboxBaseDirective

Sets/gets the aria-labelledby attribute. If not set, the aria-labelledby will be equal to the value of labelId attribute.

ariaLabelledBy: string

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:221

Example

<igx-checkbox aria-labelledby="Checkbox1"></igx-checkbox>
let ariaLabelledBy = this.checkbox.ariaLabelledBy;

Inherited from: CheckboxBaseDirective

An event that is emitted after the checkbox state is changed. Provides references to the IgxCheckboxComponent and the checked property as event arguments.

change: EventEmitter<IChangeCheckboxEventArgs>

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:36

Returns the class of the checkbox component.

cssClass: string = 'igx-checkbox'

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:59

Example

let class = this.checkbox.cssClass;

Sets/gets whether the checkbox is disabled. Default value is false.

disabled: boolean = false

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:179

Example

<igx-checkbox disabled></igx-checkbox>
let isDisabled = this.checkbox.disabled;

Inherited from: CheckboxBaseDirective

Enables/Disables the ripple effect. If not set, disableRipple will have value false.

disableRipple: boolean = false

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:206

Example

<igx-checkbox [disableRipple]="true"></igx-checkbox>
let isRippleDisabled = this.checkbox.desableRipple;

Sets/gets whether the checkbox should disable all css transitions. Default value is false.

disableTransitions: boolean = false

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:226

Example

<igx-checkbox [disableTransitions]="true"></igx-checkbox>
let disableTransitions = this.checkbox.disableTransitions;

Sets/gets whether the checkbox component is on focus. Default value is false.

focused: boolean = false

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:126

Example

this.checkbox.focused =  true;
let isFocused = this.checkbox.focused;

Inherited from: CheckboxBaseDirective

Sets/gets the id of the checkbox component. If not set, the id of the first checkbox component will be "igx-checkbox-0".

id: string

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:123

Example

<igx-checkbox id="my-first-checkbox"></igx-checkbox>
let checkboxId =  this.checkbox.id;

Sets/gets the checkbox indeterminate visual state. Default value is false;

indeterminate: boolean = false

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:142

Example

<igx-checkbox [indeterminate]="true"></igx-checkbox>
let isIndeterminate = this.checkbox.indeterminate;

Sets/gets whether the checkbox is invalid. Default value is false.

invalid: boolean = false

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:195

Example

<igx-checkbox invalid></igx-checkbox>
let isInvalid = this.checkbox.invalid;

Inherited from: CheckboxBaseDirective

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".

labelId: string

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:137

Example

<igx-checkbox labelId="Label1"></igx-checkbox>
let labelId =  this.component.labelId;

Inherited from: CheckboxBaseDirective

Sets/gets the position of the label. If not set, the labelPosition will have value "after".

labelPosition: string = LabelPosition.AFTER

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:191

Example

<igx-checkbox labelPosition="before"></igx-checkbox>
let labelPosition =  this.checkbox.labelPosition;

Inherited from: CheckboxBaseDirective

Sets/gets the name attribute.

name: string

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:163

Example

<igx-checkbox name="Checkbox1"></igx-checkbox>
let name =  this.checkbox.name;

Inherited from: CheckboxBaseDirective

Returns reference to the native checkbox element.

nativeInput: ElementRef

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:54

Example

let checkboxElement =  this.component.checkboxElement;

Inherited from: CheckboxBaseDirective

Returns reference to the native label element.

@example
let labelElement =  this.component.nativeLabel;
nativeLabel: ElementRef

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:65

Inherited from: CheckboxBaseDirective

ngControl: NgControl

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:29

Inherited from: CheckboxBaseDirective

Returns reference to the label placeholder element.

@example
let labelPlaceholder =  this.component.placeholderLabel;
placeholderLabel: ElementRef

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:107

Sets/gets whether the checkbox is readonly. Default value is false.

readonly: boolean = false

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:210

Example

<igx-checkbox [readonly]="true"></igx-checkbox>
let readonly = this.checkbox.readonly;

Inherited from: CheckboxBaseDirective

Sets/gets the value of the tabindex attribute.

tabindex: number = null

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:176

Example

<igx-checkbox [tabindex]="1"></igx-checkbox>
let tabIndex =  this.checkbox.tabindex;

Inherited from: CheckboxBaseDirective

Sets/gets the value attribute.

value: any

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:150

Example

<igx-checkbox [value]="'CheckboxValue'"></igx-checkbox>
let value =  this.checkbox.value;
checked: boolean

Defined in projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:158, projects/igniteui-angular/checkbox/src/checkbox/checkbox.component.ts:161

Inherited from: CheckboxBaseDirective

required: boolean

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:267, projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:270

Inherited from: CheckboxBaseDirective

Returns reference to the nativeElement of the igx-checkbox/igx-switch.

get nativeElement(): any

Defined in projects/igniteui-angular/directives/src/directives/checkbox/checkbox-base.directive.ts:94

Example

let nativeElement = this.component.nativeElement;

Returns any